- moved default compile and link flags to defaults.mk

git-svn-id: http://moon:8086/svn/software/trunk/make@1056 b431acfa-c32f-4a4a-93f1-934dc6c82436
This commit is contained in:
2022-06-22 09:16:44 +00:00
parent 547f44ceef
commit c127d0faa7
3 changed files with 18 additions and 10 deletions
+2 -8
View File
@@ -1,13 +1,7 @@
DEPFLAGS := -MMD
CXXFLAGS_debug ?= -g -O0
CXXFLAGS_release ?= -O2
CXXFLAGS += ${CXXFLAGS_${CONFIG}}
CFLAGS_debug ?= -g -O0
CFLAGS_release ?=- O2
CFLAGS += ${CFLAGS_${CONFIG}}
CXXFLAGS += ${CXXFLAGS_${CONFIG}}
DEFINES += ${DEFINES_${CONFIG}}
CXX_OBJS := $(addprefix ${BUILD_DIR}/, $(subst .cpp,.o,$(CXX_SRCS)))
@@ -25,7 +19,7 @@ ${CXX_OBJS}: $(BUILD_DIR)/%.o : %.cpp $(CXX_SRCS) | $(BUILD_DIR)
${GCC_OBJS}: $(BUILD_DIR)/%.o : %.c $(GCC_SRCS) | $(BUILD_DIR)
@mkdir -p $(dir $@)
@echo Compiling $@
@echo Compiling $<
$(CC) ${DEPFLAGS} ${CFLAGS} ${DEFINES} ${INCLUDES} -o $@ -c $<
$(BUILD_DIR):