summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2019-03-29 14:14:46 +1100
committerDavid Gibson <david@gibson.dropbear.id.au>2019-03-29 15:43:24 +1100
commit6ef8fcd05b740cbedf11d980e0a9ec0c87969448 (patch)
tree7b1d86b6b9f959d7f083ec95e9ab9977e374d244
parent26ee65a16c38d7bed4fd6e25962f887115540ced (diff)
downloaddevice-tree-compiler-6ef8fcd05b740cbedf11d980e0a9ec0c87969448.tar.gz
Rebuild libfdt shared object if versioning linker script changes
The usable content of the shared library varies depending on the symbol versions given in the version.lds linker script, however it's not currently in the make dependencies. Correct that, and move the libfdt rules together for consistency while we're at it. Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
-rw-r--r--Makefile10
1 files changed, 5 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index 275ac5b..07d618b 100644
--- a/Makefile
+++ b/Makefile
@@ -194,7 +194,11 @@ include $(LIBFDT_dir)/Makefile.libfdt
libfdt: $(LIBFDT_archive) $(LIBFDT_lib)
$(LIBFDT_archive): $(addprefix $(LIBFDT_dir)/,$(LIBFDT_OBJS))
-$(LIBFDT_lib): $(addprefix $(LIBFDT_dir)/,$(LIBFDT_OBJS))
+
+$(LIBFDT_lib): $(addprefix $(LIBFDT_dir)/,$(LIBFDT_OBJS)) $(LIBFDT_version)
+ @$(VECHO) LD $@
+ $(CC) $(LDFLAGS) $(SHAREDLIB_LDFLAGS)$(LIBFDT_soname) -o $(LIBFDT_lib) \
+ $(addprefix $(LIBFDT_dir)/,$(LIBFDT_OBJS))
ifneq ($(DEPTARGETS),)
-include $(LIBFDT_OBJS:%.o=$(LIBFDT_dir)/%.d)
@@ -356,10 +360,6 @@ clean: libfdt_clean pylibfdt_clean tests_clean
@$(VECHO) AR $@
$(AR) $(ARFLAGS) $@ $^
-$(LIBFDT_lib):
- @$(VECHO) LD $@
- $(CC) $(LDFLAGS) $(SHAREDLIB_LDFLAGS)$(LIBFDT_soname) -o $(LIBFDT_lib) $^
-
%.lex.c: %.l
@$(VECHO) LEX $@
$(LEX) -o$@ $<