Commit 868bc660 authored by Pekka Pessi's avatar Pekka Pessi

sac-general.m4, sofia.am, some Makefile.am's: include configure-generated C...

sac-general.m4, sofia.am, some Makefile.am's: include configure-generated C flags in SOFIA_CFLAGS/AM_CFLAGS

darcs-hash:20061121193359-65a35-274b067e315306f126d49892a688ed1113e848c3.gz
parent 148ff090
......@@ -12,8 +12,7 @@
S_BASE = $(top_srcdir)/libsofia-sip-ua
B_BASE = $(top_builddir)/libsofia-sip-ua
INCLUDES = -I$(S_BASE)/su -I$(B_BASE)/su \
$(GLIB_CFLAGS)
INCLUDES = -I$(S_BASE)/su -I$(B_BASE)/su $(GLIB_CFLAGS)
# ----------------------------------------------------------------------
# Build targets
......@@ -46,11 +45,6 @@ LDADD = libsu-glib.la \
../../libsofia-sip-ua/libsofia-sip-ua.la \
$(GLIB_LIBS)
if NDEBUG
AM_CFLAGS = -DNDEBUG
endif
# ----------------------------------------------------------------------
# Install and distribution rules
......
# common Makefile targets for libsofia-sip-ua modules
# ---------------------------------------------------
AM_CFLAGS = $(SOFIA_CFLAGS)
built-sources: $(BUILT_SOURCES)
DISTCLEANFILES = $(BUILT_SOURCES)
......
......@@ -98,10 +98,6 @@ COVERAGE_INPUT = $(libsu_la_SOURCES) $(include_sofia_HEADERS)
LDADD = libsu.la
if NDEBUG
AM_CFLAGS = -DNDEBUG
endif
# ----------------------------------------------------------------------
# Install and distribution rules
......
......@@ -131,8 +131,9 @@ AC_CACHE_CHECK([for maximum warnings compiler flag],
esac
;;
esac])
CFLAGS="$CFLAGS $ac_cv_cwflag"
AC_SUBST([CWFLAG], [$ac_cv_cwflag])
SOFIA_CFLAGS="$SOFIA_CFLAGS $ac_cv_cwflag"
AC_SUBST([SOFIA_CFLAGS])
#
# GCoverage
......@@ -144,7 +145,7 @@ AC_ARG_ENABLE(coverage,
if test X$enable_coverage != Xno ; then
case "${CC-cc}" in
*gcc*)
CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
SOFIA_CFLAGS="$SOFIA_CFLAGS -fprofile-arcs -ftest-coverage"
;;
*) AC_MSG_ERROR([--enable-coverage requires gcc])
esac
......@@ -399,10 +400,12 @@ dnl ======================================================================
dnl SAC_ENABLE_NDEBUG
dnl ======================================================================
AC_DEFUN([SAC_ENABLE_NDEBUG],[
AC_REQUIRE([AX_TOOL_CC])
AC_ARG_ENABLE(ndebug,
[ --enable-ndebug compile with NDEBUG (disabled)],
, enable_ndebug=no)
AM_CONDITIONAL(NDEBUG, test x$enable_ndebug = yes)
SOFIA_CFLAGS="$SOFIA_CFLAGS -DNDEBUG"
])
dnl ======================================================================
......
......@@ -34,6 +34,8 @@ INCLUDES = -I$(sofiasrc)/features -I$(sofiabld)/features \
-I$(sofiasrc)/su -I$(sofiabld)/su
AM_CFLAGS = $(SOFIA_CFLAGS)
# ----------------------------------------------------------------------
# Build targets
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment