From: Thibault Godouet Date: Thu, 2 Nov 2000 19:11:01 +0000 (+0000) Subject: added option --with-cflags X-Git-Tag: ver2_9_4~524 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7cc0b03683ba8f7d21ce83207f6ba97fa3b4a873;p=thirdparty%2Ffcron.git added option --with-cflags added code to recompile fcron if we switch from debug mode to non debug mode or the contrary --- diff --git a/configure.in b/configure.in index c65b2ea..428c1df 100644 --- a/configure.in +++ b/configure.in @@ -286,20 +286,44 @@ AC_SUBST(PROC) fi AC_ARG_WITH(debug, -[ --with-debug=CFLAGS Use default debug flags or CFLAGS if given to compile fcron.], +[ --with-debug=CFLAGS Use default debug flags or CFLAGS if given to compile fcron in debug mode.], [ case "$withval" in no) - CFLAGS="-O2 -Wall" + cflags="-O2 -Wall" + debug="0" ;; yes) - CFLAGS="-DDEBUG -g -DFOREGROUND -DMALLOC_CHECK_=2 -Wpointer-arith -Wstrict-prototypes" + cflags="-DDEBUG -g -DFOREGROUND -DMALLOC_CHECK_=2 -Wpointer-arith -Wstrict-prototypes" + debug="1" ;; *) - CFLAGS="$withval" + cflags="$withval" + debug="1" ;; esac ], - CFLAGS="-O2 -Wall" + cflags="-O2 -Wall" + debug="0" ) +DEBUG=$debug +AC_SUBST(DEBUG) + + +AC_ARG_WITH(cflags, +[ --with-cflags=CFLAGS Use CFLAGS flags to compile fcron.], +[ case "$withval" in + no) + AC_MSG_ERROR(Need an explicit value for --with-cflags.) + ;; + yes) + AC_MSG_ERROR(Need an explicit value for --with-cflags.) + ;; + *) + cflags="$withval" + ;; + esac ], +) +CFLAGS=$cflags +AC_DEFINE_UNQUOTED(CFLAGS, "$cflags") AC_MSG_CHECKING(location of man directory)