aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar David Leverton <levertond@googlemail.com> 2008-08-21 19:22:15 +0100
committerAvatar David Leverton <levertond@googlemail.com> 2008-08-23 16:16:26 +0100
commit073be1cd9c89ac1de7845c0cdcd370b86cbbe3d8 (patch)
treeaee433f67a2e60306d2bb10476b0be8189483d6c
parent7c34d224c099b6e95fdd448e477f9a935fa3e5fb (diff)
downloadpaludis-073be1cd9c89ac1de7845c0cdcd370b86cbbe3d8.tar.gz
paludis-073be1cd9c89ac1de7845c0cdcd370b86cbbe3d8.tar.xz
D -> IMAGE for exheres.
-rwxr-xr-xpaludis/repositories/e/e_repository_TEST_setup.sh20
-rw-r--r--paludis/repositories/e/eapi.cc1
-rw-r--r--paludis/repositories/e/eapi.hh2
-rw-r--r--paludis/repositories/e/eapis/0.conf1
-rw-r--r--paludis/repositories/e/eapis/exheres-0.conf1
-rw-r--r--paludis/repositories/e/eapis/paludis-1.conf1
-rw-r--r--paludis/repositories/e/eapis/pbin-1+exheres-0.conf2
-rw-r--r--paludis/repositories/e/ebuild.cc2
-rw-r--r--paludis/repositories/e/ebuild/exheres-0/build_functions.bash14
-rw-r--r--paludis/repositories/e/ebuild/exheres-0/builtin_init.bash9
-rw-r--r--paludis/repositories/e/ebuild/exheres-0/src_install.bash2
-rw-r--r--paludis/repositories/e/ebuild/install_functions.bash18
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dobin12
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dodir6
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dodoc6
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/doexe12
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dohard6
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dohtml6
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/doinfo10
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/doins12
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dolib6
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/doman10
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/domo10
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dosbin12
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dosed8
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/dosym12
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/fowners2
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/fperms2
-rwxr-xr-xpaludis/repositories/e/vdb_repository_TEST_setup.sh4
29 files changed, 107 insertions, 102 deletions
diff --git a/paludis/repositories/e/e_repository_TEST_setup.sh b/paludis/repositories/e/e_repository_TEST_setup.sh
index 5ca46f6..1ceb2d1 100755
--- a/paludis/repositories/e/e_repository_TEST_setup.sh
+++ b/paludis/repositories/e/e_repository_TEST_setup.sh
@@ -1578,7 +1578,7 @@ PLATFORMS="test"
src_install() {
dodir /usr/share
- touch "${D}"/usr/share/monkey
+ touch "${IMAGE}"/usr/share/monkey
keepdir /usr/share/monkey
}
END
@@ -1595,7 +1595,7 @@ PLATFORMS="test"
src_install() {
dodir /usr/share
- touch "${D}"/usr/share/monkey
+ touch "${IMAGE}"/usr/share/monkey
nonfatal keepdir /usr/share/monkey
}
END
@@ -1612,7 +1612,7 @@ PLATFORMS="test"
src_install() {
dodir /usr/share
- touch "${D}"/usr/share/monkey
+ touch "${IMAGE}"/usr/share/monkey
nonfatal keepdir /usr/share/monkey || die
}
END
@@ -2043,13 +2043,13 @@ src_install() {
doman foo.* dir/foo.* || die
doman -i18n=en_GB baz.* || die
keepdir /meh || die
- cd "\${D}"/meh || die
+ cd "\${IMAGE}"/meh || die
doman .keep* || die
- rm "\${D}"/usr/share/man/{man1/foo.1,man2/foo.2,man3/foo.3x,man4/foo.4.gz,man5/foo.5f.bz2} || die
- rm "\${D}"/usr/share/man/{man6/foo.6.Z,en/man7/foo.7,en_GB/man8/foo.8,man9/foo.e.9,mann/foo.enn.n} || die
- rm "\${D}"/usr/share/man/{man1/foo.EN.1,man2/foo.en-GB.2,man3/foo.en_gb.3,man4/foo.en_G.4} || die
- rm "\${D}"/usr/share/man/{man5/foo.en_GBB.5,mann/foo.nonkey,en_GB/man6/baz.6,en_US/man7/baz.7} || die
- rmdir "\${D}"/usr/share/man/{man1,man2,man3,man4,man5,man6,man9,mann,en/man7,en_GB/man6,en_GB/man8,en_US/man7,en,en_GB,en_US,} || die
+ rm "\${IMAGE}"/usr/share/man/{man1/foo.1,man2/foo.2,man3/foo.3x,man4/foo.4.gz,man5/foo.5f.bz2} || die
+ rm "\${IMAGE}"/usr/share/man/{man6/foo.6.Z,en/man7/foo.7,en_GB/man8/foo.8,man9/foo.e.9,mann/foo.enn.n} || die
+ rm "\${IMAGE}"/usr/share/man/{man1/foo.EN.1,man2/foo.en-GB.2,man3/foo.en_gb.3,man4/foo.en_G.4} || die
+ rm "\${IMAGE}"/usr/share/man/{man5/foo.en_GBB.5,mann/foo.nonkey,en_GB/man6/baz.6,en_US/man7/baz.7} || die
+ rmdir "\${IMAGE}"/usr/share/man/{man1,man2,man3,man4,man5,man6,man9,mann,en/man7,en_GB/man6,en_GB/man8,en_US/man7,en,en_GB,en_US,} || die
}
END
mkdir -p "packages/cat/doman-failure"
@@ -2250,7 +2250,7 @@ cat <<END > cat/pkg/pkg-1.ebuild || exit 1
SLOT="0"
PLATFORMS="test"
src_install() {
- ln -s "\${D}/foo" "\${D}/bar" || die
+ ln -s "\${IMAGE}/foo" "\${IMAGE}/bar" || die
}
END
cd ..
diff --git a/paludis/repositories/e/eapi.cc b/paludis/repositories/e/eapi.cc
index b77af58..a65108e 100644
--- a/paludis/repositories/e/eapi.cc
+++ b/paludis/repositories/e/eapi.cc
@@ -75,6 +75,7 @@ namespace
value_for<n::env_aa>(check_get(k, "env_aa")),
value_for<n::env_accept_keywords>(check_get(k, "env_accept_keywords")),
value_for<n::env_arch>(check_get(k, "env_arch")),
+ value_for<n::env_d>(check_get(k, "env_d")),
value_for<n::env_distdir>(check_get(k, "env_distdir")),
value_for<n::env_kv>(check_get(k, "env_kv")),
value_for<n::env_portdir>(check_get(k, "env_portdir")),
diff --git a/paludis/repositories/e/eapi.hh b/paludis/repositories/e/eapi.hh
index e26d444..d338b8b 100644
--- a/paludis/repositories/e/eapi.hh
+++ b/paludis/repositories/e/eapi.hh
@@ -73,6 +73,7 @@ namespace paludis
struct env_aa;
struct env_accept_keywords;
struct env_arch;
+ struct env_d;
struct env_distdir;
struct env_kv;
struct env_portdir;
@@ -226,6 +227,7 @@ namespace paludis
NamedValue<n::env_aa, std::string> env_aa;
NamedValue<n::env_accept_keywords, std::string> env_accept_keywords;
NamedValue<n::env_arch, std::string> env_arch;
+ NamedValue<n::env_d, std::string> env_d;
NamedValue<n::env_distdir, std::string> env_distdir;
NamedValue<n::env_kv, std::string> env_kv;
NamedValue<n::env_portdir, std::string> env_portdir;
diff --git a/paludis/repositories/e/eapis/0.conf b/paludis/repositories/e/eapis/0.conf
index 0440cc4..492596c 100644
--- a/paludis/repositories/e/eapis/0.conf
+++ b/paludis/repositories/e/eapis/0.conf
@@ -207,6 +207,7 @@ env_kv = KV
env_accept_keywords = ACCEPT_KEYWORDS
env_portdir = PORTDIR
env_distdir = DISTDIR
+env_d = D
dependency_labels =
diff --git a/paludis/repositories/e/eapis/exheres-0.conf b/paludis/repositories/e/eapis/exheres-0.conf
index f64ddb0..559432b 100644
--- a/paludis/repositories/e/eapis/exheres-0.conf
+++ b/paludis/repositories/e/eapis/exheres-0.conf
@@ -226,6 +226,7 @@ env_kv =
env_accept_keywords = ACCEPT_PLATFORMS
env_portdir = REPODIR
env_distdir = FETCHEDDIR
+env_d = IMAGE
uri_labels = \
default = URIListedThenMirrorsLabel ; \
diff --git a/paludis/repositories/e/eapis/paludis-1.conf b/paludis/repositories/e/eapis/paludis-1.conf
index 28a6099..ac18f58 100644
--- a/paludis/repositories/e/eapis/paludis-1.conf
+++ b/paludis/repositories/e/eapis/paludis-1.conf
@@ -213,6 +213,7 @@ env_kv =
env_accept_keywords = ACCEPT_KEYWORDS
env_portdir = PORTDIR
env_distdir = DISTDIR
+env_d = D
uri_labels = \
default = URIListedThenMirrorsLabel ; \
diff --git a/paludis/repositories/e/eapis/pbin-1+exheres-0.conf b/paludis/repositories/e/eapis/pbin-1+exheres-0.conf
index 8c5587d..910615f 100644
--- a/paludis/repositories/e/eapis/pbin-1+exheres-0.conf
+++ b/paludis/repositories/e/eapis/pbin-1+exheres-0.conf
@@ -8,7 +8,7 @@ ebuild_module_suffixes = pbin-1 ${ebuild_module_suffixes}
merge_rewrite_symlinks = true
ignore_pivot_env_variables = \
- A WORK D WORKBASE IMAGE
+ A WORK WORKBASE IMAGE
ignore_pivot_env_functions = \
src_unpack src_compile src_test src_install
diff --git a/paludis/repositories/e/ebuild.cc b/paludis/repositories/e/ebuild.cc
index 233a9aa..4b64e09 100644
--- a/paludis/repositories/e/ebuild.cc
+++ b/paludis/repositories/e/ebuild.cc
@@ -190,6 +190,8 @@ EbuildCommand::operator() ()
params.package_id()->eapi()->supported()->tools_options()->failure_is_fatal() ? "yes" : "")
.with_setenv("PALUDIS_UNPACK_FROM_VAR",
params.package_id()->eapi()->supported()->ebuild_environment_variables()->env_distdir())
+ .with_setenv("PALUDIS_IMAGE_DIR_VAR",
+ params.package_id()->eapi()->supported()->ebuild_environment_variables()->env_d())
.with_setenv("PALUDIS_PIPE_COMMANDS_SUPPORTED", "yes")
)
.with_setenv("SLOT", "")
diff --git a/paludis/repositories/e/ebuild/exheres-0/build_functions.bash b/paludis/repositories/e/ebuild/exheres-0/build_functions.bash
index 7d25e52..f422257 100644
--- a/paludis/repositories/e/ebuild/exheres-0/build_functions.bash
+++ b/paludis/repositories/e/ebuild/exheres-0/build_functions.bash
@@ -169,13 +169,13 @@ einstall()
if [[ -f Makefile ]] || [[ -f makefile ]] || [[ -f GNUmakefile ]] ; then
local makecmd=""
type -p gmake &>/dev/null && makecmd="gmake" || makecmd="make"
- local cmd="${EINSTALL_WRAPPER} ${makecmd} prefix=${D}/usr"
- cmd="${cmd} mandir=${D}/usr/share/man"
- cmd="${cmd} infodir=${D}/usr/share/info"
- cmd="${cmd} datadir=${D}/usr/share"
- cmd="${cmd} sysconfdir=${D}/etc"
- cmd="${cmd} localstatedir=${D}/var/lib"
- cmd="${cmd} libdir=${D}/usr/$(ebuild_get_libdir)"
+ local cmd="${EINSTALL_WRAPPER} ${makecmd} prefix=${IMAGE}/usr"
+ cmd="${cmd} mandir=${IMAGE}/usr/share/man"
+ cmd="${cmd} infodir=${IMAGE}/usr/share/info"
+ cmd="${cmd} datadir=${IMAGE}/usr/share"
+ cmd="${cmd} sysconfdir=${IMAGE}/etc"
+ cmd="${cmd} localstatedir=${IMAGE}/var/lib"
+ cmd="${cmd} libdir=${IMAGE}/usr/$(ebuild_get_libdir)"
cmd="${cmd} ${EXTRA_EINSTALL} ${@} install"
echo "${cmd}" 1>&2
${cmd} || paludis_die_unless_nonfatal "einstall failed" || return 247
diff --git a/paludis/repositories/e/ebuild/exheres-0/builtin_init.bash b/paludis/repositories/e/ebuild/exheres-0/builtin_init.bash
index 0e0a66d..745b37b 100644
--- a/paludis/repositories/e/ebuild/exheres-0/builtin_init.bash
+++ b/paludis/repositories/e/ebuild/exheres-0/builtin_init.bash
@@ -69,12 +69,9 @@ builtin_init()
export HOME="${T}"
export TMPDIR="${T}"
- export D="${PALUDIS_TMPDIR}/${CATEGORY}-${PF}/image/"
- export D="${D//+(\/)//}"
- mkdir -p "${D}" || die "Couldn't create \$D (\"${D}\")"
- declare -r D="${D}"
-
- export IMAGE="${D}"
+ export IMAGE="${PALUDIS_TMPDIR}/${CATEGORY}-${PF}/image/"
+ export IMAGE="${IMAGE//+(\/)//}"
+ mkdir -p "${IMAGE}" || die "Couldn't create \$IMAGE (\"${IMAGE}\")"
declare -r IMAGE="${IMAGE}"
export WORK="${WORKBASE}/${P}"
diff --git a/paludis/repositories/e/ebuild/exheres-0/src_install.bash b/paludis/repositories/e/ebuild/exheres-0/src_install.bash
index daf1e20..b90fda9 100644
--- a/paludis/repositories/e/ebuild/exheres-0/src_install.bash
+++ b/paludis/repositories/e/ebuild/exheres-0/src_install.bash
@@ -26,7 +26,7 @@ default_src_install()
if [[ -f Makefile ]] || [[ -f makefile ]] || [[ -f GNUmakefile ]] ; then
if make -j1 -n "${DEFAULT_SRC_INSTALL_PARAMS[@]}" install ; then
echo "Found a makefile, using the install target"
- emake -j1 DESTDIR="${D}" "${DEFAULT_SRC_INSTALL_PARAMS[@]}" install
+ emake -j1 DESTDIR="${IMAGE}" "${DEFAULT_SRC_INSTALL_PARAMS[@]}" install
else
die "default emake install located a makefile but no install target"
fi
diff --git a/paludis/repositories/e/ebuild/install_functions.bash b/paludis/repositories/e/ebuild/install_functions.bash
index 3e343fb..0f64974 100644
--- a/paludis/repositories/e/ebuild/install_functions.bash
+++ b/paludis/repositories/e/ebuild/install_functions.bash
@@ -36,18 +36,18 @@ keepdir()
if [[ ${#} -lt 1 ]]; then
paludis_die_unless_nonfatal "at least one argument needed"
fi
- if [[ ${@} != ${@#${D}} ]]; then
- paludis_die_unless_nonfatal "You should not use \${D} with helpers."
+ if [[ ${@} != ${@#${!PALUDIS_IMAGE_DIR_VAR}} ]]; then
+ paludis_die_unless_nonfatal "You should not use \${${PALUDIS_IMAGE_DIR_VAR}} with helpers."
fi
dodir "$@"
if [[ "${1}" == "-R" ]] || [[ "${1}" == "-r" ]] ; then
shift
- find "$@" -type d -printf "${D}/%p/.keep_${CATEGORY}_${PN}-${SLOT}\0" | xargs -0 touch
+ find "$@" -type d -printf "${!PALUDIS_IMAGE_DIR_VAR}/%p/.keep_${CATEGORY}_${PN}-${SLOT}\0" | xargs -0 touch
paludis_assert_unless_nonfatal "Failed to create .keep_${CATEGORY}_${PN}-${SLOT} files" || return 247
else
local f
for f in "$@" ; do
- touch "${D}/${f}/.keep_${CATEGORY}_${PN}-${SLOT}" || paludis_die_unless_nonfatal "Couldn't touch .keep_${CATEGORY}_${PN}-${SLOT} in ${f}" || return 247
+ touch "${!PALUDIS_IMAGE_DIR_VAR}/${f}/.keep_${CATEGORY}_${PN}-${SLOT}" || paludis_die_unless_nonfatal "Couldn't touch .keep_${CATEGORY}_${PN}-${SLOT} in ${f}" || return 247
done
fi
}
@@ -58,7 +58,7 @@ into()
export DESTTREE=
else
export DESTTREE="${1}"
- [[ -d "${D}${DESTTREE}" ]] || install -d "${D}${DESTTREE}"
+ [[ -d "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}" ]] || install -d "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}"
fi
}
@@ -68,7 +68,7 @@ insinto()
export INSDESTTREE=
else
export INSDESTTREE="${1}"
- [[ -d "${D}${INSDESTTREE}" ]] || install -d "${D}${INSDESTTREE}"
+ [[ -d "${!PALUDIS_IMAGE_DIR_VAR}${INSDESTTREE}" ]] || install -d "${!PALUDIS_IMAGE_DIR_VAR}${INSDESTTREE}"
fi
}
@@ -78,7 +78,7 @@ exeinto()
export EXEDESTTREE=
else
export EXEDESTTREE="${1}"
- [[ -d "${D}${EXEDESTTREE}" ]] || install -d "${D}${EXEDESTTREE}"
+ [[ -d "${!PALUDIS_IMAGE_DIR_VAR}${EXEDESTTREE}" ]] || install -d "${!PALUDIS_IMAGE_DIR_VAR}${EXEDESTTREE}"
fi
}
@@ -88,8 +88,8 @@ docinto()
export DOCDESTTREE=
else
export DOCDESTTREE="${1}"
- [[ -d "${D}usr/share/doc/${PF}/${DOCDESTTREE}" ]] || \
- install -d "${D}usr/share/doc/${PF}/${DOCDESTTREE}"
+ [[ -d "${!PALUDIS_IMAGE_DIR_VAR}usr/share/doc/${PF}/${DOCDESTTREE}" ]] || \
+ install -d "${!PALUDIS_IMAGE_DIR_VAR}usr/share/doc/${PF}/${DOCDESTTREE}"
fi
}
diff --git a/paludis/repositories/e/ebuild/utils/dobin b/paludis/repositories/e/ebuild/utils/dobin
index d7520a0..718da0f 100755
--- a/paludis/repositories/e/ebuild/utils/dobin
+++ b/paludis/repositories/e/ebuild/utils/dobin
@@ -23,24 +23,24 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting" >&2
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting" >&2
fi
if [[ ${#} -lt 1 ]]; then
paludis_die_or_error "at least one argument needed" >&2
fi
-if [[ ! -d "${D}${DESTTREE}/bin" ]]; then
- install -d "${D}${DESTTREE}/bin" || paludis_die_or_error "${D}${DESTTREE}/bin is not a dir"
+if [[ ! -d "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/bin" ]]; then
+ install -d "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/bin" || paludis_die_or_error "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/bin is not a dir"
fi
ret=0
for x in "$@" ; do
if [[ -n ${PALUDIS_NO_CHOWN} ]]; then
- install -m0755 "${x}" "${D}${DESTTREE}/bin" || ret=2
+ install -m0755 "${x}" "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/bin" || ret=2
else
- install -m0755 -o root -g 0 "${x}" "${D}${DESTTREE}/bin" || ret=2
+ install -m0755 -o root -g 0 "${x}" "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/bin" || ret=2
fi
done
diff --git a/paludis/repositories/e/ebuild/utils/dodir b/paludis/repositories/e/ebuild/utils/dodir
index ef2e0f9..0a7d7bc 100755
--- a/paludis/repositories/e/ebuild/utils/dodir
+++ b/paludis/repositories/e/ebuild/utils/dodir
@@ -23,13 +23,13 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
ret=0
for x in "$@"; do
- install -d ${DIROPTIONS} "${D}${x}" || ret=2
+ install -d ${DIROPTIONS} "${!PALUDIS_IMAGE_DIR_VAR}${x}" || ret=2
done
[[ 0 != "${ret}" ]] && paludis_die_or_error "dodir returned error ${ret}"
diff --git a/paludis/repositories/e/ebuild/utils/dodoc b/paludis/repositories/e/ebuild/utils/dodoc
index 438a5ac..e6a0466 100755
--- a/paludis/repositories/e/ebuild/utils/dodoc
+++ b/paludis/repositories/e/ebuild/utils/dodoc
@@ -24,15 +24,15 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ $# -lt 1 ]]; then
paludis_die_or_error "at least one argument needed"
fi
-dir="${D}usr/share/doc/${PF}/${DOCDESTTREE}"
+dir="${!PALUDIS_IMAGE_DIR_VAR}usr/share/doc/${PF}/${DOCDESTTREE}"
if [[ ! -d "${dir}" ]]; then
install -d "${dir}" || paludis_die_or_error "could not create ${dir}"
fi
diff --git a/paludis/repositories/e/ebuild/utils/doexe b/paludis/repositories/e/ebuild/utils/doexe
index 92723cf..757a2d5 100755
--- a/paludis/repositories/e/ebuild/utils/doexe
+++ b/paludis/repositories/e/ebuild/utils/doexe
@@ -23,8 +23,8 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ ! -d ${T} ]]; then
@@ -35,9 +35,9 @@ if [[ ${#} -lt 1 ]]; then
paludis_die_or_error "at least one argument needed"
fi
-if [[ ! -d "${D}${EXEDESTTREE}" ]]; then
- if ! install -d "${D}${EXEDESTTREE}" ; then
- paludis_die_or_error "could not create ${D}${EXEDESTTREE}"
+if [[ ! -d "${!PALUDIS_IMAGE_DIR_VAR}${EXEDESTTREE}" ]]; then
+ if ! install -d "${!PALUDIS_IMAGE_DIR_VAR}${EXEDESTTREE}" ; then
+ paludis_die_or_error "could not create ${!PALUDIS_IMAGE_DIR_VAR}${EXEDESTTREE}"
fi
fi
@@ -53,7 +53,7 @@ for x in "$@"; do
else
mysrc="${x}"
fi
- install ${EXEOPTIONS} "${mysrc}" "${D}${EXEDESTTREE}" || ret=2
+ install ${EXEOPTIONS} "${mysrc}" "${!PALUDIS_IMAGE_DIR_VAR}${EXEDESTTREE}" || ret=2
done
[[ 0 != "${ret}" ]] && paludis_die_or_error "doexe returned error ${ret}"
diff --git a/paludis/repositories/e/ebuild/utils/dohard b/paludis/repositories/e/ebuild/utils/dohard
index 27b7dc0..178c3fe 100755
--- a/paludis/repositories/e/ebuild/utils/dohard
+++ b/paludis/repositories/e/ebuild/utils/dohard
@@ -21,8 +21,8 @@
# this program; if not, write to the Free Software Foundation, Inc., 59 Temple
# Place, Suite 330, Boston, MA 02111-1307 USA
-if [[ ! -d ${D} ]]; then
- echo "${0}: \${D} not valid; aborting" >&2
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ echo "${0}: \${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting" >&2
exit 247
fi
@@ -31,4 +31,4 @@ if [[ ${#} -ne 2 ]]; then
exit 1
fi
-ln -f "${D}${1}" "${D}${2}"
+ln -f "${!PALUDIS_IMAGE_DIR_VAR}${1}" "${!PALUDIS_IMAGE_DIR_VAR}${2}"
diff --git a/paludis/repositories/e/ebuild/utils/dohtml b/paludis/repositories/e/ebuild/utils/dohtml
index 5e439ce..6733e6e 100755
--- a/paludis/repositories/e/ebuild/utils/dohtml
+++ b/paludis/repositories/e/ebuild/utils/dohtml
@@ -23,8 +23,8 @@
source ${PALUDIS_EBUILD_DIR}/0/list_functions.bash
-if [[ ! -d ${D} ]]; then
- echo "${0}: \${D} not valid; aborting" >&2
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ echo "${0}: \${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting" >&2
exit 247
fi
@@ -93,7 +93,7 @@ install_file() {
[[ -z ${DOCDESTTREE} ]] && DOCDESTTREE="html"
- dir="${D}usr/share/doc/${PF}/${DOCDESTTREE}/${doc_prefix}/${prefix}"
+ dir="${!PALUDIS_IMAGE_DIR_VAR}usr/share/doc/${PF}/${DOCDESTTREE}/${doc_prefix}/${prefix}"
if [[ -f ${path} ]]; then
ext="$(basename ${path})"
diff --git a/paludis/repositories/e/ebuild/utils/doinfo b/paludis/repositories/e/ebuild/utils/doinfo
index 261a20c..7577625 100755
--- a/paludis/repositories/e/ebuild/utils/doinfo
+++ b/paludis/repositories/e/ebuild/utils/doinfo
@@ -23,23 +23,23 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ ${#} -lt 1 ]]; then
paludis_die_or_error "at least one argument needed"
fi
-if [[ ! -d "${D}usr/share/info" ]]; then
- install -d "${D}usr/share/info" || paludis_die_or_error "could not create ${D}usr/share/info"
+if [[ ! -d "${!PALUDIS_IMAGE_DIR_VAR}usr/share/info" ]]; then
+ install -d "${!PALUDIS_IMAGE_DIR_VAR}usr/share/info" || paludis_die_or_error "could not create ${!PALUDIS_IMAGE_DIR_VAR}usr/share/info"
fi
ret=0
for x in "$@"; do
if [[ -e "${x}" ]]; then
- install -m0644 "${x}" "${D}usr/share/info" || ret=2
+ install -m0644 "${x}" "${!PALUDIS_IMAGE_DIR_VAR}usr/share/info" || ret=2
else
echo "${0}: ${x} does not exist"
ret=2
diff --git a/paludis/repositories/e/ebuild/utils/doins b/paludis/repositories/e/ebuild/utils/doins
index df2318b..677ec53 100755
--- a/paludis/repositories/e/ebuild/utils/doins
+++ b/paludis/repositories/e/ebuild/utils/doins
@@ -24,8 +24,8 @@
export PATH="${PALUDIS_EBUILD_DIR:+${PALUDIS_EBUILD_DIR}/utils:}${PATH}"
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ ! -d ${T} ]]; then
@@ -47,15 +47,15 @@ if [[ -z "${INSDEPTH}" ]]; then
declare -i INSDEPTH=0
fi
-if [[ ${INSDESTTREE} == ${D}* ]]; then
+if [[ ${INSDESTTREE} == ${!PALUDIS_IMAGE_DIR_VAR}* ]]; then
echo "-------------------------------------------------------" >&2
- echo "You should not use \${D} with helpers." >&2
+ echo "You should not use \${${PALUDIS_IMAGE_DIR_VAR}} with helpers." >&2
echo " --> ${INSDESTTREE}" >&2
echo "-------------------------------------------------------" >&2
paludis_die_or_error
fi
-if [[ ! -d "${D}${INSDESTTREE}" ]]; then
+if [[ ! -d "${!PALUDIS_IMAGE_DIR_VAR}${INSDESTTREE}" ]]; then
dodir "${INSDESTTREE}"
fi
@@ -81,7 +81,7 @@ for x in "$@"; do
mysrc="${x}"
fi
- install ${INSOPTIONS} "${mysrc}" "${D}${INSDESTTREE}" || ret=2
+ install ${INSOPTIONS} "${mysrc}" "${!PALUDIS_IMAGE_DIR_VAR}${INSDESTTREE}" || ret=2
done
[[ 0 != "${ret}" ]] && paludis_die_or_error "doins returned error ${ret}"
diff --git a/paludis/repositories/e/ebuild/utils/dolib b/paludis/repositories/e/ebuild/utils/dolib
index 89b56ca..eac7f5c 100755
--- a/paludis/repositories/e/ebuild/utils/dolib
+++ b/paludis/repositories/e/ebuild/utils/dolib
@@ -23,8 +23,8 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ ! -d ${PALUDIS_EBUILD_MODULES_DIR} ]]; then
@@ -33,7 +33,7 @@ fi
source "${PALUDIS_EBUILD_MODULES_DIR}/multilib_functions.bash"
-libdir="${D}${DESTTREE}/$(ebuild_get_libdir)"
+libdir="${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/$(ebuild_get_libdir)"
if [[ ${#} -lt 1 ]]; then
paludis_die_or_error "at least one argument needed"
diff --git a/paludis/repositories/e/ebuild/utils/doman b/paludis/repositories/e/ebuild/utils/doman
index a61d635..76f6bf6 100755
--- a/paludis/repositories/e/ebuild/utils/doman
+++ b/paludis/repositories/e/ebuild/utils/doman
@@ -24,8 +24,8 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
source "${PALUDIS_EBUILD_DIR}"/0/list_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ ${#} -lt 1 ]]; then
@@ -65,11 +65,11 @@ for x in "$@"; do
if [[ ${mandir} =~ ${match} ]]; then
if [[ -s ${x} ]]; then
- if [[ ! -d "${D}${BASE}/man/${mandir}" ]]; then
- install -d "${D}${BASE}/man/${mandir}"
+ if [[ ! -d "${!PALUDIS_IMAGE_DIR_VAR}${BASE}/man/${mandir}" ]]; then
+ install -d "${!PALUDIS_IMAGE_DIR_VAR}${BASE}/man/${mandir}"
fi
- install -m0644 "${x}" "${D}${BASE}/man/${mandir}/${name}" || ret=2
+ install -m0644 "${x}" "${!PALUDIS_IMAGE_DIR_VAR}${BASE}/man/${mandir}/${name}" || ret=2
elif [[ ! -e ${x} ]]; then
echo "${0}: ${x} does not exist" >&2
ret=2
diff --git a/paludis/repositories/e/ebuild/utils/domo b/paludis/repositories/e/ebuild/utils/domo
index d6ead2c..d8ca540 100755
--- a/paludis/repositories/e/ebuild/utils/domo
+++ b/paludis/repositories/e/ebuild/utils/domo
@@ -23,16 +23,16 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ ${#} -lt 1 ]]; then
paludis_die_or_error "at least one argument needed"
fi
-if [[ ! -d "${D}${DESTTREE}/share/locale" ]]; then
- install -d "${D}${DESTTREE}/share/locale" || paludis_die_or_error "could not create ${D}${DESTTREE}/share/locale"
+if [[ ! -d "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/share/locale" ]]; then
+ install -d "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/share/locale" || paludis_die_or_error "could not create ${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/share/locale"
fi
ret=0
@@ -40,7 +40,7 @@ ret=0
for x in "$@"; do
if [[ -e ${x} ]]; then
mytiny="$(basename "${x}")"
- mydir="${D}${DESTTREE}/share/locale/${mytiny%.*}/LC_MESSAGES"
+ mydir="${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/share/locale/${mytiny%.*}/LC_MESSAGES"
if [[ ! -d ${mydir} ]]; then
install -d "${mydir}"
fi
diff --git a/paludis/repositories/e/ebuild/utils/dosbin b/paludis/repositories/e/ebuild/utils/dosbin
index 92df659..3cbfe89 100755
--- a/paludis/repositories/e/ebuild/utils/dosbin
+++ b/paludis/repositories/e/ebuild/utils/dosbin
@@ -23,24 +23,24 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ ${#} -lt 1 ]]; then
paludis_die_or_error "at least one argument needed"
fi
-if [[ ! -d "${D}${DESTTREE}/sbin" ]]; then
- install -d "${D}${DESTTREE}/sbin" || paludis_die_or_error "could not create ${D}${DESTTREE}/sbin"
+if [[ ! -d "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/sbin" ]]; then
+ install -d "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/sbin" || paludis_die_or_error "could not create ${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/sbin"
fi
ret=0
for x in "$@"; do
if [[ -n ${PALUDIS_NO_CHOWN} ]]; then
- install -m0755 "${x}" "${D}${DESTTREE}/sbin" || ret=2
+ install -m0755 "${x}" "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/sbin" || ret=2
else
- install -m0755 -o root -g 0 "${x}" "${D}${DESTTREE}/sbin" || ret=2
+ install -m0755 -o root -g 0 "${x}" "${!PALUDIS_IMAGE_DIR_VAR}${DESTTREE}/sbin" || ret=2
fi
done
diff --git a/paludis/repositories/e/ebuild/utils/dosed b/paludis/repositories/e/ebuild/utils/dosed
index 70e877e..dffa16f 100755
--- a/paludis/repositories/e/ebuild/utils/dosed
+++ b/paludis/repositories/e/ebuild/utils/dosed
@@ -21,8 +21,8 @@
# this program; if not, write to the Free Software Foundation, Inc., 59 Temple
# Place, Suite 330, Boston, MA 02111-1307 USA
-if [[ ! -d ${D} ]]; then
- echo "${0}: \${D} not valid; aborting" >&2
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ echo "${0}: \${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting" >&2
exit 247
fi
@@ -31,12 +31,12 @@ if [[ ${#} -lt 1 ]]; then
exit 1
fi
-mysed="s:${D}::g"
+mysed="s:${!PALUDIS_IMAGE_DIR_VAR}::g"
ret=0
for x in "$@"; do
- y="${D}${x}"
+ y="${!PALUDIS_IMAGE_DIR_VAR}${x}"
if [[ -e ${y} ]]; then
if [[ -f "${y}" ]]; then
sed -i -e "${mysed}" "${y}" || ret=2
diff --git a/paludis/repositories/e/ebuild/utils/dosym b/paludis/repositories/e/ebuild/utils/dosym
index edff1b6..18f088e 100755
--- a/paludis/repositories/e/ebuild/utils/dosym
+++ b/paludis/repositories/e/ebuild/utils/dosym
@@ -26,21 +26,21 @@ source ${PALUDIS_EBUILD_DIR}/die_functions.bash
source ${PALUDIS_EBUILD_DIR}/pipe_functions.bash
source ${PALUDIS_EBUILD_DIR}/output_functions.bash
-if [[ ! -d ${D} ]]; then
- paludis_die_or_error "\${D} not valid; aborting"
+if [[ ! -d ${!PALUDIS_IMAGE_DIR_VAR} ]]; then
+ paludis_die_or_error "\${${PALUDIS_IMAGE_DIR_VAR}} not valid; aborting"
fi
if [[ ${#} -ne 2 ]]; then
paludis_die_or_error "exactly two arguments needed."
fi
-if [[ ! -d $(dirname "${D}$2") ]]; then
+if [[ ! -d $(dirname "${!PALUDIS_IMAGE_DIR_VAR}$2") ]]; then
if [[ -n "${PALUDIS_DOSYM_NO_MKDIR}" ]] ; then
- die "error: target directory $(dirname "${D}$2" ) does not exist"
+ die "error: target directory $(dirname "${!PALUDIS_IMAGE_DIR_VAR}$2" ) does not exist"
else
- ebuild_notice "qa" "$0: target directory $(dirname "${D}$2") does not exist; creating. Please fix the ebuild to create it explicitly."
+ ebuild_notice "qa" "$0: target directory $(dirname "${!PALUDIS_IMAGE_DIR_VAR}$2") does not exist; creating. Please fix the ebuild to create it explicitly."
dodir $(dirname $2)
fi
fi
-ln -snf "${1}" "${D}${2}" || paludis_die_or_error "creation of symlink ${D}${2} failed"
+ln -snf "${1}" "${!PALUDIS_IMAGE_DIR_VAR}${2}" || paludis_die_or_error "creation of symlink ${!PALUDIS_IMAGE_DIR_VAR}${2} failed"
diff --git a/paludis/repositories/e/ebuild/utils/fowners b/paludis/repositories/e/ebuild/utils/fowners
index 716ff52..d58cbd6 100755
--- a/paludis/repositories/e/ebuild/utils/fowners
+++ b/paludis/repositories/e/ebuild/utils/fowners
@@ -23,4 +23,4 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-chown "${@/#\//${D}/}" || paludis_die_or_error "chown returned error $?"
+chown "${@/#\//${!PALUDIS_IMAGE_DIR_VAR}/}" || paludis_die_or_error "chown returned error $?"
diff --git a/paludis/repositories/e/ebuild/utils/fperms b/paludis/repositories/e/ebuild/utils/fperms
index ed065e6..fdab732 100755
--- a/paludis/repositories/e/ebuild/utils/fperms
+++ b/paludis/repositories/e/ebuild/utils/fperms
@@ -23,4 +23,4 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-chmod "${@/#\//${D}/}" || paludis_die_or_error "chmod returned error $?"
+chmod "${@/#\//${!PALUDIS_IMAGE_DIR_VAR}/}" || paludis_die_or_error "chmod returned error $?"
diff --git a/paludis/repositories/e/vdb_repository_TEST_setup.sh b/paludis/repositories/e/vdb_repository_TEST_setup.sh
index a457c8d..b41276a 100755
--- a/paludis/repositories/e/vdb_repository_TEST_setup.sh
+++ b/paludis/repositories/e/vdb_repository_TEST_setup.sh
@@ -151,7 +151,7 @@ PLATFORMS="test"
DEPENDENCIES=""
src_install() {
- echo MONKEY > ${D}/monkey
+ echo MONKEY > ${IMAGE}/monkey
}
pkg_info() {
@@ -175,7 +175,7 @@ PLATFORMS="test"
DEPENDENCIES=""
src_install() {
- echo MONKEY > ${D}/monkey
+ echo MONKEY > ${IMAGE}/monkey
}
pkg_info() {