summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorglighta <glighta@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-12-29 06:44:29 +0000
committerglighta <glighta@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-12-29 06:44:29 +0000
commit6bd3d89c6e4cda9aba52ec2c6774a2e90f9d47f4 (patch)
tree13b0bb079d201b8e22c7e826d4dd0f05213e008e /configure.in
parent07ae3aa642ce374f72db3b1954e2df33594d51ac (diff)
downloadhercules-6bd3d89c6e4cda9aba52ec2c6774a2e90f9d47f4.tar.gz
hercules-6bd3d89c6e4cda9aba52ec2c6774a2e90f9d47f4.tar.bz2
hercules-6bd3d89c6e4cda9aba52ec2c6774a2e90f9d47f4.tar.xz
hercules-6bd3d89c6e4cda9aba52ec2c6774a2e90f9d47f4.zip
-Update configure template to autoconf 2.68
-Upd configure to disable warning only when enable-debug option ain't selected. (thus if you wanna see more warnings compile with enable-debug) -Add -Wconversion in configure. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@17061 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in31
1 files changed, 16 insertions, 15 deletions
diff --git a/configure.in b/configure.in
index 5444be663..055b04e37 100644
--- a/configure.in
+++ b/configure.in
@@ -331,7 +331,7 @@ AC_PATH_PROG(AR, ar)
AC_LANG([C])
-CFLAGS="$CFLAGS -pipe -ffast-math -Wall -Wno-sign-compare"
+CFLAGS="$CFLAGS -pipe -ffast-math -Wall"
CPPFLAGS="$CPPFLAGS -I../common"
@@ -420,12 +420,13 @@ OLD_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -Wno-unused-parameter"
AC_COMPILE_IFELSE(
[int foo;],
- [AC_MSG_RESULT([yes])],
+ [AC_MSG_RESULT([no])],
[
- AC_MSG_RESULT([no])
- CFLAGS="$OLD_CFLAGS"
+ AC_MSG_RESULT([yes])
+ PROD_WARN="$PROD_WARN -Wno-unused-parameter"
]
)
+CFLAGS="$OLD_CFLAGS"
#
@@ -477,19 +478,18 @@ AC_COMPILE_IFELSE(
[int foo;],
[
AC_MSG_RESULT([yes])
- CFLAGS="$OLD_CFLAGS -Wno-pointer-sign"
+ PROD_WARN="$PROD_WARN -Wno-pointer-sign"
],
[
AC_MSG_RESULT([no])
- CFLAGS="$OLD_CFLAGS"
]
)
],
[
- AC_MSG_RESULT([no])
- CFLAGS="$OLD_CFLAGS"
+ AC_MSG_RESULT([no])
]
)
+CFLAGS="$OLD_CFLAGS"
AC_MSG_CHECKING([whether $CC supports -Wno-switch])
@@ -497,13 +497,14 @@ OLD_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -Wno-switch"
AC_COMPILE_IFELSE(
[int foo;],
- [AC_MSG_RESULT([yes])],
+ [ AC_MSG_RESULT([yes])
+ PROD_WARN="$PROD_WARN -Wno-switch"
+ ],
[
AC_MSG_RESULT([no])
- CFLAGS="$OLD_CFLAGS"
]
)
-
+CFLAGS="$OLD_CFLAGS"
AC_MSG_CHECKING([whether $CC supports -fPIC])
OLD_CFLAGS="$CFLAGS"
@@ -604,10 +605,10 @@ fi
case $enable_debug in
"no")
# default value
- CFLAGS="$CFLAGS -Wno-unused -Wno-parentheses"
+ CFLAGS="$CFLAGS -Wno-unused -Wno-parentheses $PROD_WARN"
;;
"yes")
- CFLAGS="$CFLAGS -g -DDEBUG"
+ CFLAGS="$CFLAGS -g -DDEBUG -Wconversion"
;;
"gdb")
CFLAGS="$CFLAGS -ggdb -DDEBUG"
@@ -854,7 +855,7 @@ else
AC_MSG_RESULT([no])
fi
-
-
+AC_MSG_NOTICE([PROD_WARN= $PROD_WARN])
+AC_MSG_NOTICE([Configure finish, CFLAG= $CFLAGS])
###############################################################################
AC_OUTPUT