aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRob Herring <robh@kernel.org>2016-02-11 17:28:13 -0500
committerRob Herring <robh@kernel.org>2016-02-23 11:23:55 -0500
commit6b22b3d1614af1a775f2ef006009f15077592c9c (patch)
tree583439d092ac128c2c04da3ffe66c828355a616b
parent82f68756e94c70767a5b4747dc084a1a81e61a00 (diff)
kbuild: Allow using host dtc instead of kernel's copy
Development of dtc happens in its own upstream repository, but testing dtc changes against the kernel tree is useful. Change dtc to a variable that users can override. Signed-off-by: Rob Herring <robh@kernel.org> Cc: Michal Marek <mmarek@suse.com> Cc: linux-kbuild@vger.kernel.org
-rw-r--r--scripts/Makefile.lib3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index 2edbcadb3d7f..ad50d5859ac4 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -269,6 +269,7 @@ cmd_gzip = (cat $(filter-out FORCE,$^) | gzip -n -f -9 > $@) || \
269 269
270# DTC 270# DTC
271# --------------------------------------------------------------------------- 271# ---------------------------------------------------------------------------
272DTC ?= $(objtree)/scripts/dtc/dtc
272 273
273# Generate an assembly file to wrap the output of the device tree compiler 274# Generate an assembly file to wrap the output of the device tree compiler
274quiet_cmd_dt_S_dtb= DTB $@ 275quiet_cmd_dt_S_dtb= DTB $@
@@ -291,7 +292,7 @@ $(obj)/%.dtb.S: $(obj)/%.dtb
291quiet_cmd_dtc = DTC $@ 292quiet_cmd_dtc = DTC $@
292cmd_dtc = mkdir -p $(dir ${dtc-tmp}) ; \ 293cmd_dtc = mkdir -p $(dir ${dtc-tmp}) ; \
293 $(CPP) $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $< ; \ 294 $(CPP) $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $< ; \
294 $(objtree)/scripts/dtc/dtc -O dtb -o $@ -b 0 \ 295 $(DTC) -O dtb -o $@ -b 0 \
295 -i $(dir $<) $(DTC_FLAGS) \ 296 -i $(dir $<) $(DTC_FLAGS) \
296 -d $(depfile).dtc.tmp $(dtc-tmp) ; \ 297 -d $(depfile).dtc.tmp $(dtc-tmp) ; \
297 cat $(depfile).pre.tmp $(depfile).dtc.tmp > $(depfile) 298 cat $(depfile).pre.tmp $(depfile).dtc.tmp > $(depfile)