summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Heaven <nyhm@gentoo.org>2008-12-01 20:36:43 +0000
committerTristan Heaven <nyhm@gentoo.org>2008-12-01 20:36:43 +0000
commitbd30bafa4ab395253687ce85da3087f290c73549 (patch)
tree6d71be9b3900984571d115eb2a9d5efd9f772e1b
parentRun eautoreconf for bug 248567, and use automake 1.9 because the package is u... (diff)
downloadgentoo-2-bd30bafa4ab395253687ce85da3087f290c73549.tar.gz
gentoo-2-bd30bafa4ab395253687ce85da3087f290c73549.tar.bz2
gentoo-2-bd30bafa4ab395253687ce85da3087f290c73549.zip
patch from Davide Pesavento to fix word splitting issues, bug #241666
-rw-r--r--eclass/games.eclass16
1 files changed, 8 insertions, 8 deletions
diff --git a/eclass/games.eclass b/eclass/games.eclass
index d232b29df224..7584e7883fea 100644
--- a/eclass/games.eclass
+++ b/eclass/games.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/games.eclass,v 1.128 2008/09/28 23:40:23 nyhm Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/games.eclass,v 1.129 2008/12/01 20:36:43 nyhm Exp $
# devlist: {vapier,wolf31o2,mr_bones_}@gentoo.org -> games@gentoo.org
#
@@ -152,7 +152,7 @@ games_src_compile() {
games_pkg_preinst() {
local f
- for f in $(find "${D}/${GAMES_STATEDIR}" -type f -printf '%P ' 2>/dev/null) ; do
+ while read f ; do
if [[ -e ${ROOT}/${GAMES_STATEDIR}/${f} ]] ; then
cp -p \
"${ROOT}/${GAMES_STATEDIR}/${f}" \
@@ -161,7 +161,7 @@ games_pkg_preinst() {
# make the date match the rest of the install
touch "${D}/${GAMES_STATEDIR}/${f}"
fi
- done
+ done < <(find "${D}/${GAMES_STATEDIR}" -type f -printf '%P\n' 2>/dev/null)
}
# pkg_postinst function ... create env.d entry and warn about games group
@@ -197,11 +197,11 @@ games_ut_unpack() {
|| die "uncompressing file ${ut_unpack}"
fi
if [[ -d ${ut_unpack} ]] ; then
- for f in $(find "${ut_unpack}" -name '*.uz2' -printf '%f ') ; do
- uz2unpack "${ut_unpack}/${f}" "${ut_unpack}/${f/.uz2}" &>/dev/null \
+ while read f ; do
+ uz2unpack "${ut_unpack}/${f}" "${ut_unpack}/${f%.uz2}" &>/dev/null \
|| die "uncompressing file ${f}"
rm -f "${ut_unpack}/${f}" || die "deleting compressed file ${f}"
- done
+ done < <(find "${ut_unpack}" -maxdepth 1 -name '*.uz2' -printf '%f\n' 2>/dev/null)
fi
}
@@ -224,11 +224,11 @@ games_umod_unpack() {
games_link_mods() {
if [[ -e ${GAMES_DATADIR}/${GAME} ]] ; then
cd "${GAMES_DATADIR}/${GAME}"
- for mod in $(find . -type d -printf '%P ') ; do
+ while read mod ; do
if [[ ! -e ${Ddir}/${mod} ]] ; then
elog "Creating symlink for ${mod}"
dosym "${GAMES_DATADIR}"/${GAME}/${mod} "${dir}"/${mod} || die
fi
- done
+ done < <(find . -type d -printf '%P\n' 2>/dev/null)
fi
}