summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/gcc2/cpp/usr.bin.cpp.sh
diff options
context:
space:
mode:
authormycroft <mycroft@NetBSD.org>1994-12-13 11:06:25 +0000
committermycroft <mycroft@NetBSD.org>1994-12-13 11:06:25 +0000
commit9c93cdd301e42a5f7cfa5ae2d69d4a8a0315e4a7 (patch)
treed6eb899e48b48c4d47cbb9e9281a8a675595982a /gnu/usr.bin/gcc2/cpp/usr.bin.cpp.sh
parent2981ef65959f0fc1075354d3a913f67f0de2ac7b (diff)
Handle GCC's include-related options which take an argument, (almost) as
suggested by Giles Lean.
Diffstat (limited to 'gnu/usr.bin/gcc2/cpp/usr.bin.cpp.sh')
-rw-r--r--gnu/usr.bin/gcc2/cpp/usr.bin.cpp.sh9
1 files changed, 8 insertions, 1 deletions
diff --git a/gnu/usr.bin/gcc2/cpp/usr.bin.cpp.sh b/gnu/usr.bin/gcc2/cpp/usr.bin.cpp.sh
index 720b202124c..12f8aaf39ce 100644
--- a/gnu/usr.bin/gcc2/cpp/usr.bin.cpp.sh
+++ b/gnu/usr.bin/gcc2/cpp/usr.bin.cpp.sh
@@ -49,8 +49,11 @@ OPTS=""
INCS="-nostdinc"
FOUNDFILES=no
-for A
+while [ $# -gt 0 ]
do
+ A="$1"
+ shift
+
case $A in
-nostdinc)
NSI=yes
@@ -63,6 +66,10 @@ do
-U__GNUC__)
ALST=`echo $ALST | sed -e 's/-D__GNUC__//'`
;;
+ -imacros|-include|-idirafter|-iprefix|-iwithprefix)
+ INCS="$INCS '$A' '$1'"
+ shift
+ ;;
-*)
OPTS="$OPTS '$A'"
;;