summaryrefslogtreecommitdiffstats
path: root/sys/boot/Makefile.inc
diff options
context:
space:
mode:
authorngie <ngie@FreeBSD.org>2017-05-28 01:14:59 +0000
committerngie <ngie@FreeBSD.org>2017-05-28 01:14:59 +0000
commit8bb80d0cc082cd4232953f4a74c3e822e754af0e (patch)
tree7d9f68fca9f2fca67ac15c6866c00e1d2d01b535 /sys/boot/Makefile.inc
parent4e90ae005dc94b7406d625aabf890337b7c7f39f (diff)
downloadFreeBSD-src-8bb80d0cc082cd4232953f4a74c3e822e754af0e.zip
FreeBSD-src-8bb80d0cc082cd4232953f4a74c3e822e754af0e.tar.gz
MFC r309412,r316109,r316132:
r309412 (by imp): dd is currently a bootstrap tool. It really doesn't have any business being a bootstrap tool. However, for reproducible build output, FreeBSD added dd status=none because it was otherwise difficult to suppress the status information, but retain any errors that might happen. There's no real reason that dd has to be a build tool, other than we use status=none unconditional. Remove dd from a bootstrap tool entirely by only using status=none when available. This may also help efforts to build the system on non-FreeBSD hosts as well. r316109: Don't hardcode input files for stage 1/2 bootloaders; use .ALLSRC instead This is a better pattern to follow when creating the bootloaders and doing the relevant space checks to make sure that the sizes aren't exceeded (and thus, copy-pasting is a bit less error prone). r316132: Parameterize out 7680 (15 * 512) as BOOT2SIZE, similar to sys/boot/i386/zfsboot/... This is being done to make it easier to change in the future--this action might be needed sooner rather than later because of gcc 6.3.0 bailing, stating that there is negative free space left (deficit) in the boot2 bootloader.
Diffstat (limited to 'sys/boot/Makefile.inc')
-rw-r--r--sys/boot/Makefile.inc7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/boot/Makefile.inc b/sys/boot/Makefile.inc
index 3545446..5d1d51a 100644
--- a/sys/boot/Makefile.inc
+++ b/sys/boot/Makefile.inc
@@ -1,3 +1,10 @@
# $FreeBSD$
SSP_CFLAGS=
+
+# The boot loader build uses dd status=none, where possible, for reproducible
+# build output (since performance varies from run to run). Trouble is that
+# option was recently (10.3) added to FreeBSD and is non-standard. Only use it
+# when this test succeeds rather than require dd to be a bootstrap tool.
+DD_NOSTATUS!=(dd status=none count=0 2> /dev/null && echo status=none) || true
+DD=dd ${DD_NOSTATUS}
OpenPOWER on IntegriCloud