From 11217a510d1a7399a4a293e7394030a697993826 Mon Sep 17 00:00:00 2001 From: "Reece H. Dunn" Date: Sun, 12 May 2013 10:02:44 +0100 Subject: [PATCH] autotools: allow CXXFLAGS to be overrided from the environment. This is based on the patch for the Debian bug #707925 by Jason White . --- src/Makefile.am | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Makefile.am b/src/Makefile.am index cf919be6..5d725e11 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -64,17 +64,17 @@ endif endif endif -CXXFLAGS = -O2 -Wall -c -CPPFLAGS = -pedantic -fno-exceptions -D PATH_ESPEAK_DATA=\"$(DATADIR)\" +CXXFLAGS ?= -O2 -Wall +CPPFLAGS = -pedantic -fno-exceptions -D PATH_ESPEAK_DATA=\"$(DATADIR)\" .cpp.o: - $(CXX) $(CXXFLAGS) $(USE_AUDIO) -I. $(CPPFLAGS) $< + $(CXX) -c $(CXXFLAGS) $(USE_AUDIO) -I. $(CPPFLAGS) $< e_%.o: %.cpp - $(CXX) $(CXXFLAGS) $(espeakedit_CXXFLAGS) $(USE_AUDIO) $(CPPFLAGS) -I. $< -o e_$*.o + $(CXX) -c $(CXXFLAGS) $(espeakedit_CXXFLAGS) $(USE_AUDIO) $(CPPFLAGS) -I. $< -o e_$*.o x_%.o: %.cpp - $(CXX) $(CXXFLAGS) $(USE_AUDIO) -fpic -fvisibility=hidden \ + $(CXX) -c $(CXXFLAGS) $(USE_AUDIO) -fpic -fvisibility=hidden \ -I. -D LIBRARY $(CPPFLAGS) $< -o x_$*.o all: $(SPEAK) $(LIBESPEAK) $(STATIC_LIBESPEAK) $(ESPEAK) $(ESPEAKEDIT)