From 851f1a112155b4c1404536e904b0d93dd685f4a9 Mon Sep 17 00:00:00 2001 From: Kyle Evans Date: Mon, 12 Nov 2018 22:18:11 +0000 Subject: [PATCH] Fix test-dts{,o} targets There were two main problems here: 1.) sys/dts/Makefile.inc is not included from various */overlays directories by default, only ../Makefile.inc 2.) When shelling out for DTS/DTSO, cwd != .CURDIR, so enumeration always failed These changes allow make test-dts and make test-dtso to function in their respective directories. Reviewed by: manu MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D17961 --- sys/dts/Makefile.inc | 2 +- sys/dts/arm/Makefile | 2 +- sys/dts/arm/Makefile.inc | 3 +++ sys/dts/arm/overlays/Makefile | 2 +- sys/dts/arm64/Makefile | 2 +- sys/dts/arm64/Makefile.inc | 3 +++ sys/dts/arm64/overlays/Makefile | 2 +- sys/dts/mips/Makefile | 2 +- sys/dts/powerpc/Makefile | 2 +- 9 files changed, 13 insertions(+), 7 deletions(-) create mode 100644 sys/dts/arm/Makefile.inc create mode 100644 sys/dts/arm64/Makefile.inc diff --git a/sys/dts/Makefile.inc b/sys/dts/Makefile.inc index 2161751dc237..bb6fef4bbd20 100644 --- a/sys/dts/Makefile.inc +++ b/sys/dts/Makefile.inc @@ -5,9 +5,9 @@ SYSDIR?=${SRCTOP}/sys test-dts: .for dts in ${DTS} @env MACHINE=`basename ${.CURDIR}` ${SYSDIR}/tools/fdt/make_dtb.sh ${SYSDIR} ${dts} /tmp +.endfor test-dtso: .for dtso in ${DTSO} @env MACHINE=`basename ${.CURDIR}` ${SYSDIR}/tools/fdt/make_dtbo.sh ${SYSDIR} ${dtso} /tmp - .endfor diff --git a/sys/dts/arm/Makefile b/sys/dts/arm/Makefile index 03d156d94770..855f8847d514 100644 --- a/sys/dts/arm/Makefile +++ b/sys/dts/arm/Makefile @@ -1,6 +1,6 @@ # $FreeBSD$ -DTS!=ls *.dts +DTS!=ls ${.CURDIR}/*.dts all: test-dts diff --git a/sys/dts/arm/Makefile.inc b/sys/dts/arm/Makefile.inc new file mode 100644 index 000000000000..265f86d1ed55 --- /dev/null +++ b/sys/dts/arm/Makefile.inc @@ -0,0 +1,3 @@ +# $FreeBSD$ + +.include "../Makefile.inc" diff --git a/sys/dts/arm/overlays/Makefile b/sys/dts/arm/overlays/Makefile index aff6f3d459bc..cfc655929ef3 100644 --- a/sys/dts/arm/overlays/Makefile +++ b/sys/dts/arm/overlays/Makefile @@ -1,6 +1,6 @@ # $FreeBSD$ -DTSO!=ls *.dtso +DTSO!=ls ${.CURDIR}/*.dtso all: test-dtso diff --git a/sys/dts/arm64/Makefile b/sys/dts/arm64/Makefile index 03d156d94770..855f8847d514 100644 --- a/sys/dts/arm64/Makefile +++ b/sys/dts/arm64/Makefile @@ -1,6 +1,6 @@ # $FreeBSD$ -DTS!=ls *.dts +DTS!=ls ${.CURDIR}/*.dts all: test-dts diff --git a/sys/dts/arm64/Makefile.inc b/sys/dts/arm64/Makefile.inc new file mode 100644 index 000000000000..265f86d1ed55 --- /dev/null +++ b/sys/dts/arm64/Makefile.inc @@ -0,0 +1,3 @@ +# $FreeBSD$ + +.include "../Makefile.inc" diff --git a/sys/dts/arm64/overlays/Makefile b/sys/dts/arm64/overlays/Makefile index aff6f3d459bc..cfc655929ef3 100644 --- a/sys/dts/arm64/overlays/Makefile +++ b/sys/dts/arm64/overlays/Makefile @@ -1,6 +1,6 @@ # $FreeBSD$ -DTSO!=ls *.dtso +DTSO!=ls ${.CURDIR}/*.dtso all: test-dtso diff --git a/sys/dts/mips/Makefile b/sys/dts/mips/Makefile index 03d156d94770..855f8847d514 100644 --- a/sys/dts/mips/Makefile +++ b/sys/dts/mips/Makefile @@ -1,6 +1,6 @@ # $FreeBSD$ -DTS!=ls *.dts +DTS!=ls ${.CURDIR}/*.dts all: test-dts diff --git a/sys/dts/powerpc/Makefile b/sys/dts/powerpc/Makefile index 03d156d94770..855f8847d514 100644 --- a/sys/dts/powerpc/Makefile +++ b/sys/dts/powerpc/Makefile @@ -1,6 +1,6 @@ # $FreeBSD$ -DTS!=ls *.dts +DTS!=ls ${.CURDIR}/*.dts all: test-dts