Switch to the standard 'verbose' build option. Use a better way of passing options to the linker that is closer to friendly with 'make export'.

This commit is contained in:
px4dev 2012-10-15 21:08:26 -07:00
parent f9a8818d1e
commit 3292ea24a1
2 changed files with 5 additions and 12 deletions

1
.gitignore vendored
View File

@ -38,3 +38,4 @@ Firmware.sublime-workspace
nsh_romfsimg.h
cscope.out
.configX-e
nuttx-export.zip

View File

@ -116,7 +116,6 @@ ARCHOPTIMIZATION = $(MAXOPTIMIZATION) \
ifeq ("${CONFIG_DEBUG_SYMBOLS}","y")
ARCHOPTIMIZATION += -g
ARCHSCRIPT += -g
endif
ARCHCFLAGS = -std=gnu99
@ -149,7 +148,7 @@ ARCHDEFINES =
ARCHPICFLAGS = -fpic -msingle-pic-base -mpic-register=r10
# this seems to be the only way to add linker flags
ARCHSCRIPT += --warn-common \
EXTRA_LIBS += --warn-common \
--gc-sections
CFLAGS = $(ARCHCFLAGS) $(ARCHCWARNINGS) $(ARCHOPTIMIZATION) $(ARCHCPUFLAGS) $(ARCHINCLUDES) $(INSTRUMENTATIONDEFINES) $(ARCHDEFINES) $(EXTRADEFINES) -pipe -fno-common
@ -167,13 +166,6 @@ OBJEXT = .o
LIBEXT = .a
EXEEXT =
# If VERBOSE is set, don't hide the compiler invocations.
ifeq ($(VERBOSE),YES)
_v =
else
_v = @
endif
define PREPROCESS
@echo "CPP: $1->$2"
@$(CPP) $(CPPFLAGS) $(abspath $1) -o $2
@ -181,17 +173,17 @@ endef
define COMPILE
@echo "CC: $1"
$(_v)$(CC) -c $(CFLAGS) $(abspath $1) -o $2
$(Q)$(CC) -c $(CFLAGS) $(abspath $1) -o $2
endef
define COMPILEXX
@echo "CXX: $1"
$(_v)$(CXX) -c $(CXXFLAGS) $(abspath $1) -o $2
$(Q)$(CXX) -c $(CXXFLAGS) $(abspath $1) -o $2
endef
define ASSEMBLE
@echo "AS: $1"
$(_v)$(CC) -c $(AFLAGS) $(abspath $1) -o $2
$(Q)$(CC) -c $(AFLAGS) $(abspath $1) -o $2
endef
# produce partially-linked $1 from files in $2