summaryrefslogtreecommitdiffstats
path: root/make/compilers
diff options
context:
space:
mode:
Diffstat (limited to 'make/compilers')
-rw-r--r--make/compilers/gcc-target-default.cfg6
1 files changed, 5 insertions, 1 deletions
diff --git a/make/compilers/gcc-target-default.cfg b/make/compilers/gcc-target-default.cfg
index 62757713d9..0be680898c 100644
--- a/make/compilers/gcc-target-default.cfg
+++ b/make/compilers/gcc-target-default.cfg
@@ -96,14 +96,18 @@ endif
# profile flag; use gprof(1)
CFLAGS_PROFILE_V=-pg
+ifndef AUTOMAKE
# default is to optimize
CFLAGS_OPTIMIZE=$(CFLAGS_OPTIMIZE_V)
+endif
# dynamic libraries
#CFLAGS_DYNAMIC_V=-fpic
#ASFLAGS_DYNAMIC_V=
+ifndef AUTOMAKE
CFLAGS += $(CFLAGS_OPTIMIZE) $(CFLAGS_DEBUG) $(CFLAGS_PROFILE)
+endif
# List of library paths without -L
LD_PATHS= $(PROJECT_RELEASE)/lib
@@ -210,7 +214,7 @@ ifneq ($(words $(C_FILES) $(CC_FILES) $(S_FILES)), 0)
# Replace foo.o with $(ARCH)/foo.o
# Replace $(ARCH) value with string $(ARCH)
# so that it will for debug and profile cases
- $(COMPILE.c) -M $^ | \
+ $(COMPILE.c) $(AM_CPPFLAGS) $(AM_CFLAGS) -M $^ | \
$(SED) -e 's?^\(.*\)\.o[ ]*:?$$(ARCH)/\1.o:?' \
-e 's?$(ARCH)/?$$(ARCH)/?' >$(DEPEND).tmp
$(MV) $(DEPEND).tmp $(DEPEND)