summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2009-03-11 06:35:43 +0000
committerZac Medico <zmedico@gentoo.org>2009-03-11 06:35:43 +0000
commit95d0489750b6d7c38ed612ae3ccafa880220a7ff (patch)
treeecceec6ac5739a0a63c922c4cf2a5be0688ebc67 /bin
parentMake KeyValuePairFileLoader store the values as a strings instead of a lists. (diff)
downloadportage-multirepo-95d0489750b6d7c38ed612ae3ccafa880220a7ff.tar.gz
portage-multirepo-95d0489750b6d7c38ed612ae3ccafa880220a7ff.tar.bz2
portage-multirepo-95d0489750b6d7c38ed612ae3ccafa880220a7ff.zip
Fix vdb entry writting code in dyn_install() to avoid generating empty entries
in some cases. Thanks to Ned Ludd <solar@g.o> for reporting. (trunk r12745) svn path=/main/branches/2.1.6/; revision=12994
Diffstat (limited to 'bin')
-rwxr-xr-xbin/ebuild.sh7
1 files changed, 4 insertions, 3 deletions
diff --git a/bin/ebuild.sh b/bin/ebuild.sh
index d4bceae4..dac55a21 100755
--- a/bin/ebuild.sh
+++ b/bin/ebuild.sh
@@ -1003,14 +1003,15 @@ dyn_install() {
cd "${PORTAGE_BUILDDIR}"/build-info
set -f
- local f
+ local f x
+ IFS=$' \t\n\r'
for f in ASFLAGS CATEGORY CBUILD CC CFLAGS CHOST CTARGET CXX \
CXXFLAGS DEPEND EXTRA_ECONF EXTRA_EINSTALL EXTRA_MAKE \
FEATURES INHERITED IUSE LDFLAGS LIBCFLAGS LIBCXXFLAGS \
LICENSE PDEPEND PF PKGUSE PROPERTIES PROVIDE RDEPEND RESTRICT SLOT \
KEYWORDS HOMEPAGE SRC_URI DESCRIPTION; do
- [ -n "${!f}" ] && echo $(echo "${!f}" | \
- tr '\n,\r,\t' ' , , ' | sed s/' \+'/' '/g) > ${f}
+ x=$(echo -n ${!f})
+ [[ -n $x ]] && echo "$x" > $f
done
echo "${USE}" > USE
echo "${EAPI:-0}" > EAPI