set debug options when using the icc compiler
This commit is contained in:
Родитель
82c31256e1
Коммит
6bd2de0c42
18
acinclude.m4
18
acinclude.m4
|
@ -505,7 +505,17 @@ AC_DEFUN([CURL_CC_DEBUG_OPTS],
|
||||||
|
|
||||||
if test "$ICC" = "yes"; then
|
if test "$ICC" = "yes"; then
|
||||||
dnl this is icc, not gcc.
|
dnl this is icc, not gcc.
|
||||||
WARN = ""
|
|
||||||
|
dnl Warning 279 warns on static conditions in while expressions,
|
||||||
|
dnl ignore that.
|
||||||
|
|
||||||
|
WARN="-wd279"
|
||||||
|
|
||||||
|
if test "$gccnum" -gt "600"; then
|
||||||
|
dnl icc 6.0 and older doesn't have the -Wall flag, although it does
|
||||||
|
dnl have -wd<n>
|
||||||
|
WARN="-Wall $WARN"
|
||||||
|
fi
|
||||||
else dnl $ICC = yes
|
else dnl $ICC = yes
|
||||||
dnl
|
dnl
|
||||||
WARN="-W -Wall -Wwrite-strings -pedantic -Wno-long-long -Wundef -Wpointer-arith -Wnested-externs -Winline -Wmissing-declarations -Wmissing-prototypes -Wsign-compare"
|
WARN="-W -Wall -Wwrite-strings -pedantic -Wno-long-long -Wundef -Wpointer-arith -Wnested-externs -Winline -Wmissing-declarations -Wmissing-prototypes -Wsign-compare"
|
||||||
|
@ -529,20 +539,20 @@ AC_DEFUN([CURL_CC_DEBUG_OPTS],
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
NEWFLAGS=""
|
|
||||||
for flag in $CPPFLAGS; do
|
for flag in $CPPFLAGS; do
|
||||||
case "$flag" in
|
case "$flag" in
|
||||||
-I*)
|
-I*)
|
||||||
dnl include path
|
dnl include path
|
||||||
add=`echo $flag | sed 's/^-I/-isystem /g'`
|
add=`echo $flag | sed 's/^-I/-isystem /g'`
|
||||||
NEWFLAGS="$NEWFLAGS $add"
|
WARN="$WARN $add"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
CFLAGS="$CFLAGS $WARN $NEWFLAGS"
|
|
||||||
fi dnl $ICC = no
|
fi dnl $ICC = no
|
||||||
|
|
||||||
|
CFLAGS="$CFLAGS $WARN"
|
||||||
|
|
||||||
fi dnl $GCC = yes
|
fi dnl $GCC = yes
|
||||||
|
|
||||||
dnl strip off optimizer flags
|
dnl strip off optimizer flags
|
||||||
|
|
Загрузка…
Ссылка в новой задаче