summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-03-25 06:40:50 +1300
committerSimon Glass <sjg@chromium.org>2021-03-26 17:03:08 +1300
commit13d71152f1e1323e0a5caf3a78b7a457fff58257 (patch)
treef397e00f28733343b0311c0556141ec94a9f998b /scripts
parent6519da47411e90322c59e3fa4b41ff398ff0a688 (diff)
downloadu-boot-13d71152f1e1323e0a5caf3a78b7a457fff58257.tar.gz
u-boot-13d71152f1e1323e0a5caf3a78b7a457fff58257.tar.xz
u-boot-13d71152f1e1323e0a5caf3a78b7a457fff58257.zip
Makefile: Depend only on required of-platdata files
When OF_PLATDATA_INST is enabled, we need dt-uclass.c and dt-device.c for the build to work. When OF_PLATDATA_INST is not enabled, we only need dt-plat.c Update the Makefile rules to indicate this. At present all files are generated and compiled regardless of which are actually needed. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/Makefile.spl7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/Makefile.spl b/scripts/Makefile.spl
index 4f5876dad9..5f37a82931 100644
--- a/scripts/Makefile.spl
+++ b/scripts/Makefile.spl
@@ -120,8 +120,11 @@ endif
u-boot-spl-init := $(head-y)
u-boot-spl-main := $(libs-y)
ifdef CONFIG_$(SPL_TPL_)OF_PLATDATA
-u-boot-spl-platdata := $(obj)/dts/dt-plat.o $(obj)/dts/dt-uclass.o \
- $(obj)/dts/dt-device.o
+ifdef CONFIG_$(SPL_TPL_)OF_PLATDATA_INST
+u-boot-spl-platdata := $(obj)/dts/dt-uclass.o $(obj)/dts/dt-device.o
+else
+u-boot-spl-platdata := $(obj)/dts/dt-plat.o
+endif
u-boot-spl-platdata_c := $(patsubst %.o,%.c,$(u-boot-spl-platdata))
endif