Skip to content

Commit

Permalink
makefiles/modules.inc.mk: group CFLAGS handling
Browse files Browse the repository at this point in the history
Put all lines related to CFLAGS handling together.
  • Loading branch information
cladmi authored and geromueller committed Jun 19, 2019
1 parent 45b00c5 commit fb8d3a3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions makefiles/modules.inc.mk
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
_ALLMODULES = $(sort $(USEMODULE) $(USEPKG))

# Define MODULE_MODULE_NAME preprocessor macros for all modules.
ED = $(addprefix MODULE_,$(_ALLMODULES))
EXTDEFINES = $(addprefix -D,$(shell echo '$(ED)' | tr 'a-z-' 'A-Z_'))
CFLAGS += $(EXTDEFINES)

# filter "pseudomodules" from "real modules", but not "no_pseudomodules"
NO_PSEUDOMODULES := $(filter $(NO_PSEUDOMODULES), $(_ALLMODULES))
REALMODULES = $(filter-out $(PSEUDOMODULES), $(_ALLMODULES)) $(NO_PSEUDOMODULES)
BASELIBS += $(REALMODULES:%=$(BINDIR)/%.a)

CFLAGS += $(EXTDEFINES)

0 comments on commit fb8d3a3

Please sign in to comment.