make: Modify only BUILD_*FLAGS in jw-build/make/*.mk

Assign only to BUILD_XXXFLAGS in jw-build/make/*.mk, and leave PROJECT_XXXFLAGS
and LOCAL_XXXFLAGS alone.

Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2019-04-10 06:43:40 +00:00
commit 49f269bdfe
12 changed files with 74 additions and 73 deletions

View file

@ -6,25 +6,25 @@ CALLGRIND_OUT ?= callgrind.out
OPROF_OUT_DIR ?= oprofile-data
ifeq ($(USE_GPROF),true)
PROJECT_CXXFLAGS += -pg
PROJECT_CFLAGS += -pg
PROJECT_LDFLAGS += -pg
BUILD_CXXFLAGS += -pg
BUILD_CFLAGS += -pg
BUILD_LDFLAGS += -pg
clean: clean.gprof
endif
ifeq ($(COMPILER_SUITE),gcc)
ifeq ($(USE_GCOV),true)
PROJECT_CXXFLAGS += -fprofile-arcs -ftest-coverage
PROJECT_CFLAGS += -fprofile-arcs -ftest-coverage
PROJECT_LDFLAGS += -fprofile-arcs -ftest-coverage
BUILD_CXXFLAGS += -fprofile-arcs -ftest-coverage
BUILD_CFLAGS += -fprofile-arcs -ftest-coverage
BUILD_LDFLAGS += -fprofile-arcs -ftest-coverage
clean: clean.gcov
endif
endif
ifeq ($(COMPILER_SUITE),clang)
ifeq ($(USE_XRAY),true)
PROJECT_CXXFLAGS += -fxray-instrument -fxray-instruction-threshold=1
PROJECT_CFLAGS += -fxray-instrument -fxray-instruction-threshold=1
#PROJECT_LDFLAGS += -fxray-instrument
BUILD_CXXFLAGS += -fxray-instrument -fxray-instruction-threshold=1
BUILD_CFLAGS += -fxray-instrument -fxray-instruction-threshold=1
#BUILD_LDFLAGS += -fxray-instrument
endif
endif