From owner-svn-src-all@freebsd.org Fri Dec 14 23:53:29 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 82B5D1324DD7; Fri, 14 Dec 2018 23:53:29 +0000 (UTC) (envelope-from arichardson@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 290F1713BC; Fri, 14 Dec 2018 23:53:29 +0000 (UTC) (envelope-from arichardson@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 19CA6700F; Fri, 14 Dec 2018 23:53:29 +0000 (UTC) (envelope-from arichardson@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id wBENrShw091968; Fri, 14 Dec 2018 23:53:28 GMT (envelope-from arichardson@FreeBSD.org) Received: (from arichardson@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id wBENrSTr091966; Fri, 14 Dec 2018 23:53:28 GMT (envelope-from arichardson@FreeBSD.org) Message-Id: <201812142353.wBENrSTr091966@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: arichardson set sender to arichardson@FreeBSD.org using -f From: Alex Richardson Date: Fri, 14 Dec 2018 23:53:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r342105 - head/sys/tools/fdt X-SVN-Group: head X-SVN-Commit-Author: arichardson X-SVN-Commit-Paths: head/sys/tools/fdt X-SVN-Commit-Revision: 342105 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 290F1713BC X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.84 / 15.00]; local_wl_from(0.00)[FreeBSD.org]; NEURAL_HAM_MEDIUM(-0.99)[-0.990,0]; NEURAL_HAM_SHORT(-0.97)[-0.966,0]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US]; NEURAL_HAM_LONG(-0.88)[-0.881,0] X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2018 23:53:29 -0000 Author: arichardson Date: Fri Dec 14 23:53:28 2018 New Revision: 342105 URL: https://svnweb.freebsd.org/changeset/base/342105 Log: make_dtb.sh: Use $CPP instead of assuming that cpp is in $PATH This fixes building in CheriBSD with a strict tmp path since we don't bootstrap a cpp but pass the full path to clang-cpp instead. While touching this file also fix all shellcheck warnings in make_dtb.sh. Reviewed By: manu Differential Revision: https://reviews.freebsd.org/D18376 Modified: head/sys/tools/fdt/make_dtb.sh head/sys/tools/fdt/make_dtbo.sh Modified: head/sys/tools/fdt/make_dtb.sh ============================================================================== --- head/sys/tools/fdt/make_dtb.sh Fri Dec 14 22:22:43 2018 (r342104) +++ head/sys/tools/fdt/make_dtb.sh Fri Dec 14 23:53:28 2018 (r342105) @@ -16,12 +16,13 @@ if [ -z "${MACHINE}" ]; then MACHINE=$(uname -m) fi -: ${DTC:=dtc} -: ${ECHO:=echo} +: "${DTC:=dtc}" +: "${ECHO:=echo}" +: "${CPP:=cpp}" for d in ${dts}; do - dtb=${dtb_path}/`basename $d .dts`.dtb + dtb="${dtb_path}/$(basename "$d" .dts).dtb" ${ECHO} "converting $d -> $dtb" - cpp -P -x assembler-with-cpp -I $S/gnu/dts/include -I $S/dts/${MACHINE} -I $S/gnu/dts/${MACHINE} -I $S/gnu/dts/ -include $d /dev/null | - ${DTC} -@ -O dtb -o $dtb -b 0 -p 1024 -i $S/dts/${MACHINE} -i $S/gnu/dts/${MACHINE} -i $S/gnu/dts/ + ${CPP} -P -x assembler-with-cpp -I "$S/gnu/dts/include" -I "$S/dts/${MACHINE}" -I "$S/gnu/dts/${MACHINE}" -I "$S/gnu/dts/" -include "$d" /dev/null | + ${DTC} -@ -O dtb -o "$dtb" -b 0 -p 1024 -i "$S/dts/${MACHINE}" -i "$S/gnu/dts/${MACHINE}" -i "$S/gnu/dts/" done Modified: head/sys/tools/fdt/make_dtbo.sh ============================================================================== --- head/sys/tools/fdt/make_dtbo.sh Fri Dec 14 22:22:43 2018 (r342104) +++ head/sys/tools/fdt/make_dtbo.sh Fri Dec 14 23:53:28 2018 (r342105) @@ -16,12 +16,13 @@ if [ -z "${MACHINE}" ]; then MACHINE=$(uname -m) fi -: ${DTC:=dtc} -: ${ECHO:=echo} +: "${DTC:=dtc}" +: "${ECHO:=echo}" +: "${CPP:=cpp}" for d in ${dtso}; do - dtb=${dtbo_path}/`basename $d .dtso`.dtbo + dtb="${dtbo_path}/$(basename "$d" .dtso).dtbo" ${ECHO} "converting $d -> $dtb" - cpp -P -x assembler-with-cpp -I $S/gnu/dts/include -I $S/dts/${MACHINE} -I $S/gnu/dts/${MACHINE} -include $d /dev/null | - ${DTC} -@ -O dtb -o $dtb -i $S/dts/${MACHINE} -i $S/gnu/dts/${MACHINE} + ${CPP} -P -x assembler-with-cpp -I "$S/gnu/dts/include" -I "$S/dts/${MACHINE}" -I "$S/gnu/dts/${MACHINE}" -include "$d" /dev/null | + ${DTC} -@ -O dtb -o "$dtb" -i "$S/dts/${MACHINE}" -i "$S/gnu/dts/${MACHINE}" done