wrappers/cross-cc: drop -isystem /usr/include, too
This commit is contained in:
parent
1d4364852d
commit
740858ad91
|
@ -8,11 +8,11 @@ ARGS=("$@")
|
||||||
i=0
|
i=0
|
||||||
while [ $i -lt ${#ARGS[@]} ]; do
|
while [ $i -lt ${#ARGS[@]} ]; do
|
||||||
arg="${ARGS[$i]}"
|
arg="${ARGS[$i]}"
|
||||||
if [ "$incpath" ]; then
|
if [ -n "$incpath" ]; then
|
||||||
if [ "$arg" = "/usr/include" ]; then
|
if [ "$arg" = "/usr/include" ]; then
|
||||||
echo "[cc-wrapper] ignoring -I $arg"
|
echo "[cc-wrapper] ignoring ${incpath} $arg"
|
||||||
else
|
else
|
||||||
MYARGS+=("-I${arg}")
|
MYARGS+=("${incpath}${arg}")
|
||||||
fi
|
fi
|
||||||
unset incpath
|
unset incpath
|
||||||
elif [ "$libpath" ]; then
|
elif [ "$libpath" ]; then
|
||||||
|
@ -23,13 +23,13 @@ while [ $i -lt ${#ARGS[@]} ]; do
|
||||||
MYARGS+=("-L${arg}")
|
MYARGS+=("-L${arg}")
|
||||||
fi
|
fi
|
||||||
unset libpath
|
unset libpath
|
||||||
elif [ "$arg" = "-I" ]; then
|
elif [ "$arg" = "-I" -o "$arg" = "-isystem" ]; then
|
||||||
incpath=1
|
incpath="$arg"
|
||||||
elif [ "$arg" = "-L" ]; then
|
elif [ "$arg" = "-L" ]; then
|
||||||
libpath=1
|
libpath=1
|
||||||
elif [ "$arg" = "-I/usr/include" -o "$arg" = "-L/usr/lib" \
|
elif [ "$arg" = "-I/usr/include" -o "$arg" = "-isystem/usr/include" \
|
||||||
-o "$arg" = "-L/usr/lib32" -o "$arg" = "-L/usr/lib64" \
|
-o "$arg" = "-L/usr/lib32" -o "$arg" = "-L/usr/lib64" \
|
||||||
-o "$arg" = "-L/lib" ]; then
|
-o "$arg" = "-L/usr/lib" -o "$arg" = "-L/lib" ]; then
|
||||||
echo "[cc-wrapper] ignoring $arg"
|
echo "[cc-wrapper] ignoring $arg"
|
||||||
else
|
else
|
||||||
MYARGS+=("${arg}")
|
MYARGS+=("${arg}")
|
||||||
|
|
Loading…
Reference in New Issue