1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-28 01:58:17 +03:00

configure: Introduce "debug" variable set to yes by --enable-debug.

Michael
(This used to be commit b33db84c222af21cc3dd8233d6ff96e6f32ea3cd)
This commit is contained in:
Michael Adam 2008-02-19 16:34:43 +01:00
parent 86e758e246
commit 90ea8ae9b1

View File

@ -410,10 +410,11 @@ AC_SUBST(NSCD_LIBS)
## check for --enable-debug first before checking CFLAGS before
## so that we don't mix -O and -g
debug=no
AC_ARG_ENABLE(debug,
[AS_HELP_STRING([--enable-debug], [Turn on compiler debugging information (default=no)])],
[if eval "test x$enable_debug = xyes"; then
CFLAGS="${CFLAGS} -g"
debug=yes
fi])
# compile with optimization and without debugging by default, but
@ -424,6 +425,11 @@ AC_ARG_ENABLE(debug,
if test "x$CFLAGS" = x; then
CFLAGS="-O"
fi
if test "x$debug" = "xyes" ; then
CFLAGS="${CFLAGS} -g"
else
CFLAGS="-O"
fi
CFLAGS="${CFLAGS} -D_SAMBA_BUILD_=3"