[Makefile] Added LD flags to the makefile.mk, removed unneeded directory in EXTERNAL_INCLUDE

This commit is contained in:
Maschell
2018-03-13 10:15:48 +01:00
parent 6ca382bf6e
commit 544a4da57c
20 changed files with 115 additions and 63 deletions

View File

@@ -82,8 +82,8 @@ endif
ASFLAGS +=
LDFLAG_COMMON +=
LDFLAGS_MOD +=
LDFLAGS_ELF +=
LDFLAGS_MOD += $(LD_FLAGS_MOD)
LDFLAGS_ELF += $(LD_FLAGS_ELF)
#---------------------------------------------------------------------------------
Q := @
@@ -181,7 +181,7 @@ all : $(OUTPUT)
# Rule to make the module file.
$(OUTPUT) : output.elf
@echo "checking for missing symbols ..."
@$(LD_MOD) ../$(BUILD)/output.elf $(LDFLAG_COMMON) $(ALL_LIBS) $(LIBPATHS_FULL) -o check_linking.elf
@$(LD_MOD) ../$(BUILD)/output.elf $(LDFLAG_COMMON) $(LD_FLAGS_MOD) $(ALL_LIBS) $(LIBPATHS_FULL) -o check_linking.elf
@echo "linking ..." $@
@$(LD_MOD) ../$(BUILD)/output.elf $(LDFLAGS_MOD) $(ALL_LIBS) $(LIBPATHS_FULL) -o $@

View File

@@ -14,12 +14,18 @@ DATA :=
INCLUDES := src
#---------------------------------------------------------------------------------
# options for code generation
# options for code generation and linking
#---------------------------------------------------------------------------------
# Extra C compiler flags
CFLAGS :=
# Extra C++ compiler flags
CXXFLAGS :=
# Extra linking flags for all linking steps
LD_FLAGS :=
# extra linking flags for linking the temporarily elf file (using ld)
LD_FLAGS_ELF :=
# extra linking flags for linking the final mod file (using gcc/g++)
LD_FLAGS_MOD :=
#---------------------------------------------------------------------------------
# list of directories containing libraries, this must be the top level containing
@@ -43,5 +49,4 @@ EXTERNAL_LIBPATHS :=
# Will be added to the final include paths
# -IC:/library1/include
#---------------------------------------------------------------------------------
EXTERNAL_INCLUDE := -I$(PORTLIBS)/include/libutils \
-I$(WUPSDIR)/include
EXTERNAL_INCLUDE := -I$(PORTLIBS)/include/libutils