summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorakrus <akrus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-07-31 07:03:12 +0000
committerakrus <akrus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-07-31 07:03:12 +0000
commit349da469d7355798a916749d055ab2c131bffe76 (patch)
treebf10212a558a689c92f9f5d104d8d7fd42d03814 /configure.in
parentf2d7a74d9df57d9e3b9165799ea2759b23223469 (diff)
downloadhercules-349da469d7355798a916749d055ab2c131bffe76.tar.gz
hercules-349da469d7355798a916749d055ab2c131bffe76.tar.bz2
hercules-349da469d7355798a916749d055ab2c131bffe76.tar.xz
hercules-349da469d7355798a916749d055ab2c131bffe76.zip
* Improved: added --enable-debug=gdb option in configure script to use gdb optimized debug mode [akrus]
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13024 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in22
1 files changed, 16 insertions, 6 deletions
diff --git a/configure.in b/configure.in
index 5ebbe1561..aab1f58fb 100644
--- a/configure.in
+++ b/configure.in
@@ -78,13 +78,15 @@ AC_ARG_ENABLE(
[debug],
AC_HELP_STRING(
[--enable-debug],
- [Compiles extra debug code. (disabled by default)]
+ [Compiles extra debug code. (disabled by default)],
+ [(available options: yes, no, gdb)]
),
[
enable_debug="$enableval"
case $enableval in
- no);;
- yes);;
+ "no");;
+ "yes");;
+ "gdb");;
*) AC_MSG_ERROR([[invalid argument --enable-debug=$enableval... stopping]]);;
esac
],
@@ -347,9 +349,17 @@ fi
#
# Debug
#
-if test "$enable_debug" = "yes" ; then
- CFLAGS="$CFLAGS -g -DDEBUG"
-fi
+case $enable_debug in
+ "no")
+ # default value
+ ;;
+ "yes")
+ CFLAGS="$CFLAGS -g -DDEBUG"
+ ;;
+ "gdb")
+ CFLAGS="$CFLAGS -ggdb -DDEBUG"
+ ;;
+esac
#