aboutsummaryrefslogtreecommitdiff
path: root/sys/conf/dtb.build.mk
diff options
context:
space:
mode:
authorAlan Somers <asomers@FreeBSD.org>2019-05-13 18:25:55 +0000
committerAlan Somers <asomers@FreeBSD.org>2019-05-13 18:25:55 +0000
commit7648bc9fee8dec6cb3c4941e0165a930fbe8dcb0 (patch)
treeca719c54da5b3133ae25fe32bba5b0dac584e56e /sys/conf/dtb.build.mk
parent8350cbd8d64924fc1673eb4735ac7220bf5dfd37 (diff)
parentaf1f58df9938e12acbe5fab69890c59684415902 (diff)
Notes
Diffstat (limited to 'sys/conf/dtb.build.mk')
-rw-r--r--sys/conf/dtb.build.mk13
1 files changed, 11 insertions, 2 deletions
diff --git a/sys/conf/dtb.build.mk b/sys/conf/dtb.build.mk
index 9cffe3283906..140440336cad 100644
--- a/sys/conf/dtb.build.mk
+++ b/sys/conf/dtb.build.mk
@@ -24,7 +24,16 @@ SYSDIR= ${_dir:tA}
.error "can't find kernel source tree"
.endif
-DTB=${DTS:T:R:S/$/.dtb/}
+.for _dts in ${DTS}
+# DTB for aarch64 needs to preserve the immediate parent of the .dts, because
+# these DTS are vendored and should be installed into their vendored directory.
+.if ${MACHINE_ARCH} == "aarch64"
+DTB+= ${_dts:R:S/$/.dtb/}
+.else
+DTB+= ${_dts:T:R:S/$/.dtb/}
+.endif
+.endfor
+
DTBO=${DTSO:T:R:S/$/.dtbo/}
.SUFFIXES: .dtb .dts .dtbo .dtso
@@ -43,7 +52,7 @@ DTBO=${DTSO:T:R:S/$/.dtbo/}
# Add dependencies on the source file so that out-of-tree things can be included
# without any .PATH additions.
-.for _dts in ${DTS}
+.for _dts in ${DTS} ${FDT_DTS_FILE}
${_dts:R:T}.dtb: ${_dts}
.endfor