mirror of
https://github.com/nginx/nginx.git
synced 2025-06-07 17:52:38 +08:00
Configure: revised GCC version processing.
Now GCC 6 and onwards will use -Wno-unused-parameter.
This commit is contained in:
parent
ba212375a7
commit
5d9419704f
13
auto/cc/gcc
13
auto/cc/gcc
@ -151,9 +151,13 @@ CFLAGS="$CFLAGS -Wall -Wpointer-arith"
|
|||||||
#CFLAGS="$CFLAGS -Winline"
|
#CFLAGS="$CFLAGS -Winline"
|
||||||
#CFLAGS="$CFLAGS -Wmissing-prototypes"
|
#CFLAGS="$CFLAGS -Wmissing-prototypes"
|
||||||
|
|
||||||
|
|
||||||
case "$NGX_GCC_VER" in
|
case "$NGX_GCC_VER" in
|
||||||
[3-5].*)
|
2.*)
|
||||||
|
# we have a lot of the unused function arguments
|
||||||
|
CFLAGS="$CFLAGS -Wno-unused"
|
||||||
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
# we have a lot of the unused function arguments
|
# we have a lot of the unused function arguments
|
||||||
CFLAGS="$CFLAGS -Wno-unused-parameter"
|
CFLAGS="$CFLAGS -Wno-unused-parameter"
|
||||||
# 4.2.1 shows the warning in wrong places
|
# 4.2.1 shows the warning in wrong places
|
||||||
@ -164,11 +168,6 @@ case "$NGX_GCC_VER" in
|
|||||||
CFLAGS="$CFLAGS -Wno-deprecated-declarations"
|
CFLAGS="$CFLAGS -Wno-deprecated-declarations"
|
||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
|
|
||||||
*)
|
|
||||||
# we have a lot of the unused function arguments
|
|
||||||
CFLAGS="$CFLAGS -Wno-unused"
|
|
||||||
;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user