diff options
author | Caleb Tennis <caleb@gentoo.org> | 2003-08-07 03:47:26 +0000 |
---|---|---|
committer | Caleb Tennis <caleb@gentoo.org> | 2003-08-07 03:47:26 +0000 |
commit | 37a7fb65231b59649396d2ee0e0552af8ff35543 (patch) | |
tree | b925c637dc4f564540c745e0abdff0a31e153163 /eclass | |
parent | fix license/repoman (diff) | |
download | historical-37a7fb65231b59649396d2ee0e0552af8ff35543.tar.gz historical-37a7fb65231b59649396d2ee0e0552af8ff35543.tar.bz2 historical-37a7fb65231b59649396d2ee0e0552af8ff35543.zip |
Add a function that replaces head -1 with head -n 1, and more...
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/kde-functions.eclass | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/eclass/kde-functions.eclass b/eclass/kde-functions.eclass index f028f9a9bcf4..0dd62b51a45c 100644 --- a/eclass/kde-functions.eclass +++ b/eclass/kde-functions.eclass @@ -1,6 +1,6 @@ # Copyright 1999-2003 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/kde-functions.eclass,v 1.60 2003/07/29 10:39:02 pauldv Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/kde-functions.eclass,v 1.61 2003/08/07 03:47:26 caleb Exp $ # # Author Dan Armak <danarmak@gentoo.org> # @@ -363,6 +363,18 @@ kde_sandbox_patch() { } +#replace any instances of head -1 with head -n 1 in build files: +kde_fix_head_instances() { + while [ -n "$1" ]; do + if [ -f "$1" ]; then + echo Performing head fix on $1 + cp ${1} ${1}.orig + sed -e 's:head -1:head -n 1:g' -e 's:head -2:head -n 2:g' ${1}.orig > ${1} + rm ${1}.orig + fi + shift + done +} # remove an optimization flag from a specific subdirectory's makefiles. # currently kdebase and koffice use it to compile certain subdirs without |