summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorBart Verwilst <verwilst@gentoo.org>2002-06-16 21:45:10 +0000
committerBart Verwilst <verwilst@gentoo.org>2002-06-16 21:45:10 +0000
commit325f5f9fcdf11776d7f84ab05f88c664dd30ad1e (patch)
tree4e10b6e20f7305397c9cb2ed7e2859bf941b9b8a /eclass
parentAdded gkrellshoot and gkrellmweather (diff)
downloadhistorical-325f5f9fcdf11776d7f84ab05f88c664dd30ad1e.tar.gz
historical-325f5f9fcdf11776d7f84ab05f88c664dd30ad1e.tar.bz2
historical-325f5f9fcdf11776d7f84ab05f88c664dd30ad1e.zip
added new change-flag class
Diffstat (limited to 'eclass')
-rw-r--r--eclass/flag-o-matic.eclass21
1 files changed, 13 insertions, 8 deletions
diff --git a/eclass/flag-o-matic.eclass b/eclass/flag-o-matic.eclass
index cd47ec7e2b45..48d027f14814 100644
--- a/eclass/flag-o-matic.eclass
+++ b/eclass/flag-o-matic.eclass
@@ -5,8 +5,17 @@
ECLASS=flag-o-matic
#
-#Remove particular flags from C[XX]FLAGS
+#### filter-flags <flag> ####
+# Remove particular flags from C[XX]FLAGS
#
+#### append-flags <flag> ####
+# Add extra flags to your current C[XX]FLAGS
+#
+#### change-flags <orig.flag> <new.flag> ###
+# Replace a flag by another one
+#
+
+
filter-flags () {
for x in $1; do
@@ -16,9 +25,6 @@ filter-flags () {
}
-#
-#Add flags to the current C[XX]FLAGS
-#
append-flags () {
@@ -27,10 +33,9 @@ append-flags () {
}
-max-optim () {
+change-flags () {
- for x in $CFLAGS; do
- echo $x
- done
+ CFLAGS="${CFLAGS/${1}/${2}"
+ CXXFLAGS="${CXXFLAGS/${1}/${2}"
}