summaryrefslogtreecommitdiff
path: root/eclass/kde4-base.eclass
diff options
context:
space:
mode:
authorMaciej Mrozowski (reavertm) <reavertm@poczta.fm>2009-02-06 19:53:03 +0100
committerMaciej Mrozowski (reavertm) <reavertm@poczta.fm>2009-02-06 19:53:03 +0100
commitb1470f2f348584038b7f14ea5a559a20547fe8da (patch)
tree48df45fbb559c5c86188161431d9070cec7e15a8 /eclass/kde4-base.eclass
parent68c6eb024ace1a02a57f5200f8a972c9a6e0cf60 (diff)
downloadkde-b1470f2f348584038b7f14ea5a559a20547fe8da.tar.gz
kde-b1470f2f348584038b7f14ea5a559a20547fe8da.tar.bz2
kde-b1470f2f348584038b7f14ea5a559a20547fe8da.zip
Fix nasty eclass issue (with SRC_URI containing multiple entries, like patches in disfiles)
Diffstat (limited to 'eclass/kde4-base.eclass')
-rw-r--r--eclass/kde4-base.eclass9
1 files changed, 8 insertions, 1 deletions
diff --git a/eclass/kde4-base.eclass b/eclass/kde4-base.eclass
index 96dea73279f..99aafc6eba7 100644
--- a/eclass/kde4-base.eclass
+++ b/eclass/kde4-base.eclass
@@ -418,6 +418,13 @@ esac
debug-print "${LINENO} ${ECLASS} ${FUNCNAME}: SRC_URI is ${SRC_URI}"
+# @ECLASS-VARIABLE: TARBALL
+# @DESCRIPTION:
+# Stores package tarball name - detected from SRC_URI. We need this variable
+# to unpack source in reliable way (patches in distfiles listed in SRC_URI would
+# cause problem otherwise.
+TARBALL="${SRC_URI##*/}"
+
# @ECLASS-VARIABLE: PREFIX
# @DESCRIPTION:
# Set the installation PREFIX. All kde-base ebuilds go into the KDE4 installation directory.
@@ -486,7 +493,7 @@ kde4-base_src_unpack() {
unpack "${A}" || die "Unpack ${A} failed"
# Detect real toplevel dir - issue with unstable snapshots
if [[ ${KDEBASE} = kde-base ]]; then
- local topleveldir=`basename ${SRC_URI%.tar.*}`
+ local topleveldir="${TARBALL%.tar.*}"
if [[ "${topleveldir}" != "${P}" ]]; then
mv "${topleveldir}" "${P}" || die "Died while moving \"${topleveldir}\" to \"${P}\""
fi