diff options
| author | Kai Germaschewski <kai@tp1.ruhr-uni-bochum.de> | 2002-04-12 01:30:38 -0500 |
|---|---|---|
| committer | Kai Germaschewski <kai@tp1.ruhr-uni-bochum.de> | 2002-04-12 01:30:38 -0500 |
| commit | 03102fad1a7baaa802930c33bb096aa16759aa55 (patch) | |
| tree | 93ebf5a9f276051a96124e13a472d2629c52fa02 /Rules.make | |
| parent | 274678d115a526311dda889a5e2a247820b4c416 (diff) | |
Handle $(export-objs) ambiguity
We use the makefile variable $(foo-objs) to list the objects
a composed module foo.o is supposed to be composed of.
We use the special varible $(export-objs) to list the object files which
export symbols.
This oviously clashes in the case of foo == export. There's basically
two ways to handle it: (1) rename one of these options, like
foo-objs to foo-parts or something, or (2) simply disallow a composite
object called export.o, so you never need $(export-objs) to list its
parts.
As (1) would affect basically all Makefiles in the tree and (2) doesn't
seem much of a limitation, I went for (2).
Diffstat (limited to 'Rules.make')
| -rw-r--r-- | Rules.make | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Rules.make b/Rules.make index 05858896c186..763dbfe29a4c 100644 --- a/Rules.make +++ b/Rules.make @@ -126,8 +126,10 @@ endif # for make >= 3.78 the following is cleaner: # multi-used := $(foreach m,$(obj-y) $(obj-m), $(if $($(basename $(m))-objs), $(m))) -multi-used-y := $(sort $(foreach m,$(obj-y),$(patsubst %,$(m),$($(basename $(m))-objs)))) -multi-used-m := $(sort $(foreach m,$(obj-m),$(patsubst %,$(m),$($(basename $(m))-objs)))) +__obj-y = $(filter-out export.o,$(obj-y)) +__obj-m = $(filter-out export.o,$(obj-m)) +multi-used-y := $(sort $(foreach m,$(__obj-y),$(patsubst %,$(m),$($(basename $(m))-objs)))) +multi-used-m := $(sort $(foreach m,$(__obj-m),$(patsubst %,$(m),$($(basename $(m))-objs)))) ld-multi-used-y := $(filter-out $(list-multi),$(multi-used-y)) ld-multi-used-m := $(filter-out $(list-multi),$(multi-used-m)) ld-multi-objs-y := $(foreach m, $(ld-multi-used-y), $($(basename $(m))-objs)) |
