diff --git a/Changes b/Changes index c5547e5ef..ee05fe068 100644 --- a/Changes +++ b/Changes @@ -12,6 +12,8 @@ The contributors that suggested a given feature are shown in []. Thanks! **** Fix not in array context on non-power-of-two slices, msg2946. [Yu Sheng Lin] +**** Fix system compile flags injection. [Gianfranco Costamagna] + * Verilator 4.016 2016-06-16 diff --git a/configure.ac b/configure.ac index 33b2f0638..6fa0f9841 100644 --- a/configure.ac +++ b/configure.ac @@ -91,10 +91,10 @@ AC_SUBST(CFG_WITH_PREC11) AC_MSG_RESULT($CFG_WITH_PREC11) # Compiler flags -CFLAGS=-I${includedir} -CPPFLAGS=-I${includedir} -CXXFLAGS=-I${includedir} -LDFLAGS=-L${libdir} +CFLAGS+=" -I${includedir}" +CPPFLAGS+=" -I${includedir}" +CXXFLAGS+=" -I${includedir}" +LDFLAGS+=" -L${libdir}" # Checks for programs. AC_PROG_CC diff --git a/docs/CONTRIBUTORS b/docs/CONTRIBUTORS index 3cd7de0aa..832b61548 100644 --- a/docs/CONTRIBUTORS +++ b/docs/CONTRIBUTORS @@ -4,8 +4,9 @@ under the Developer Certificate of Origin Please see the Verilator manual for additional contributors. -Jeremy Bennett Alex Chadwick +Gianfranco Costamagna +Jeremy Bennett John Coiner Kanad Kanhere Richard Myers diff --git a/src/Makefile_obj.in b/src/Makefile_obj.in index 142f20a62..d7019eb86 100644 --- a/src/Makefile_obj.in +++ b/src/Makefile_obj.in @@ -60,6 +60,8 @@ pkgdatadir = @pkgdatadir@ CFG_WITH_CCWARN = @CFG_WITH_CCWARN@ CFG_WITH_DEFENV = @CFG_WITH_DEFENV@ CPPFLAGS += @CPPFLAGS@ +CFLAGS += @CFLAGS@ +CXXFLAGS += @CXXFLAGS@ LDFLAGS += @LDFLAGS@ EXEEXT = @EXEEXT@ CFG_CXXFLAGS_SRC = @CFG_CXXFLAGS_SRC@ @@ -135,7 +137,7 @@ VLCOVGEN = $(srcdir)/vlcovgen all: make_info $(TGT) make_info: - @echo " Compile flags: " $(CXX) ${CPPFLAGS} + @echo " Compile flags: " $(CXX) ${CFLAGS} ${CXXFLAGS} ${CPPFLAGS} clean mostlyclean distclean maintainer-clean:: -rm -f *.o *.d perlxsi.c *_gen_* @@ -280,21 +282,21 @@ V3Number_test: V3Number_test.o $(PERL) $(ASTGEN) -I$(srcdir) $*.cpp %.o: %.cpp - $(OBJCACHE) ${CXX} ${CPPFLAGSWALL} -c $< + $(OBJCACHE) ${CXX} ${CXXFLAGS} ${CPPFLAGSWALL} -c $< %.o: %.c - $(OBJCACHE) ${CC} ${CPPFLAGSWALL} -c $< + $(OBJCACHE) ${CC} ${CFLAGS} ${CPPFLAGSWALL} -c $< V3ParseLex.o: V3ParseLex.cpp V3Lexer.yy.cpp V3ParseBison.c - $(OBJCACHE) ${CXX} ${CPPFLAGSPARSER} -c $< + $(OBJCACHE) ${CXX} ${CXXFLAGS} ${CPPFLAGSPARSER} -c $< V3ParseGrammar.o: V3ParseGrammar.cpp V3ParseBison.c - $(OBJCACHE) ${CXX} ${CPPFLAGSPARSER} -c $< + $(OBJCACHE) ${CXX} ${CXXFLAGS} ${CPPFLAGSPARSER} -c $< V3ParseImp.o: V3ParseImp.cpp V3ParseBison.c - $(OBJCACHE) ${CXX} ${CPPFLAGSPARSER} -c $< + $(OBJCACHE) ${CXX} ${CXXFLAGS} ${CPPFLAGSPARSER} -c $< V3PreProc.o: V3PreProc.cpp V3PreLex.yy.cpp - $(OBJCACHE) ${CXX} ${CPPFLAGSPARSER} -c $< + $(OBJCACHE) ${CXX} ${CXXFLAGS} ${CPPFLAGSPARSER} -c $< #### Generated files