shithub: aubio

Download patch

ref: 17db1cde81719f3e7b3c85179d40105df19c209b
parent: 8a1f9a4f0ab95572bf1eb8f8b7b6de0ba23d077a
author: Paul Brossier <piem@altern.org>
date: Fri Sep 29 10:15:56 EDT 2006

use AUBIO_CFLAGS, not CFLAGS
use AUBIO_CFLAGS, not CFLAGS


--- a/configure.ac
+++ b/configure.ac
@@ -29,6 +29,8 @@
 fi
 AC_PROG_INSTALL
 
+AUBIO_CFLAGS=
+
 dnl Enable debugging (no)
 AC_ARG_ENABLE(debug,
   [  --enable-debug[[=value]]  compile with debug [[default=no]]],
@@ -37,7 +39,7 @@
 if test "$with_debug" = "yes"
 then
   AC_DEFINE(DEBUG,1,[Define to enable debug])
-  CFLAGS="$CFLAGS -g"
+  AUBIO_CFLAGS="$(AUBIO_CFLAGS) -g"
 fi
 
 dnl Enable full warnings (yes)
@@ -53,12 +55,13 @@
   CFLAGS="$CFLAGS -Wextra"
   AC_COMPILE_IFELSE([void foo (void) {}],
           ac_cv_cc_wextra=yes, ac_cv_cc_wextra=no)
+  CFLAGS="$old_CFLAGS"
   ])
   if test "$ac_cv_cc_wextra" = "yes"
   then
-    CFLAGS="$old_CFLAGS -Wall -Wextra"
+    AUBIO_CFLAGS="$AUBIO_CFLAGS -Wall -Wextra"
   else 
-    CFLAGS="$old_CFLAGS -Wall"
+    AUBIO_CFLAGS="$AUBIO_CFLAGS -Wall"
   fi
 fi
 
@@ -65,7 +68,7 @@
 AC_ARG_ENABLE(failonerror,
   [  --enable-fwarn[[=value]]  fail on compilation warnings [[default=yes]]],
   with_warnme="no",
-  CFLAGS="$CFLAGS -Werror -Wmissing-prototypes -Wmissing-declarations -Wno-unused-parameter")
+  AUBIO_CFLAGS="$AUBIO_CFLAGS -Werror -Wmissing-prototypes -Wmissing-declarations -Wno-unused-parameter")
 
 dnl Check for libtool
 AC_LIBTOOL_DLOPEN
@@ -84,7 +87,7 @@
   dnl on macosx, cosf went to -lmx
   LDFLAGS="$LDFLAGS -lmx"
   dnl as long double doesn't sit well with -Wall -Werror
-  CFLAGS="$CFLAGS -Wno-long-double"
+  AUBIO_CFLAGS="$AUBIO_CFLAGS -Wno-long-double"
   AC_ISC_POSIX
   ;;
 *)
--- a/examples/Makefile.am
+++ b/examples/Makefile.am
@@ -3,9 +3,8 @@
 endif
 
 # global flags
-AM_CFLAGS = -DAUBIO_PREFIX=\"$(prefix)\" -I$(top_srcdir)/src -I$(top_srcdir)/ext @LASH_CFLAGS@ @FFTWLIB_CFLAGS@
+AM_CFLAGS = -DAUBIO_PREFIX=\"$(prefix)\" -I$(top_srcdir)/src -I$(top_srcdir)/ext @AUBIO_CFLAGS@ @LASH_CFLAGS@ @FFTWLIB_CFLAGS@
 AM_LDFLAGS = -L$(top_builddir)/src -L$(top_builddir)/ext -laubioext -laubio @LASH_LIBS@
-#AM_SOURCES = utils.c
 
 # add your programs to this list
 bin_PROGRAMS = \
--- a/ext/Makefile.am
+++ b/ext/Makefile.am
@@ -42,6 +42,6 @@
 	midi/midi_driver.h \
 	midi/midi_driver.c
 
-AM_CFLAGS = -I$(top_srcdir)/src @SNDLIB_CFLAGS@ @JACK_CFLAGS@ @FFTWLIB_CFLAGS@ @SAMPLERATE_CFLAGS@ @ALSA_CFLAGS@
+AM_CFLAGS = -I$(top_srcdir)/src @AUBIO_CFLAGS@ @SNDLIB_CFLAGS@ @JACK_CFLAGS@ @FFTWLIB_CFLAGS@ @SAMPLERATE_CFLAGS@ @ALSA_CFLAGS@
 libaubioext_la_LIBADD = @SNDLIB_LIBS@ @JACK_LIBS@ @FFTWLIB_LIBS@ @SAMPLERATE_LIBS@ @ALSA_LIBS@ @LTLIBOBJS@
 libaubioext_la_LDFLAGS = -version-info @SHARED_VERSION_INFO@
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -70,6 +70,6 @@
 	filter.c \
 	filter.h
 
-AM_CFLAGS = @FFTWLIB_CFLAGS@ @SAMPLERATE_CFLAGS@
+AM_CFLAGS = @AUBIO_CFLAGS@ @FFTWLIB_CFLAGS@ @SAMPLERATE_CFLAGS@
 libaubio_la_LIBADD = @FFTWLIB_LIBS@ @SAMPLERATE_LIBS@ @LTLIBOBJS@
 libaubio_la_LDFLAGS = -version-info @SHARED_VERSION_INFO@