diff options
-rw-r--r-- | ObsoleteFiles.inc | 4 | ||||
-rw-r--r-- | stand/efi/boot1/Makefile | 23 | ||||
-rw-r--r-- | stand/efi/boot1/Makefile.fat | 4 | ||||
-rw-r--r-- | stand/efi/boot1/fat-amd64.tmpl.xz | bin | 1716 -> 0 bytes | |||
-rw-r--r-- | stand/efi/boot1/fat-arm.tmpl.xz | bin | 1708 -> 0 bytes | |||
-rw-r--r-- | stand/efi/boot1/fat-arm64.tmpl.xz | bin | 1720 -> 0 bytes | |||
-rw-r--r-- | stand/efi/boot1/fat-i386.tmpl.xz | bin | 1724 -> 0 bytes | |||
-rwxr-xr-x | stand/efi/boot1/generate-fat.sh | 79 | ||||
-rw-r--r-- | stand/efi/gptboot/Makefile | 1 | ||||
-rw-r--r-- | tools/build/mk/OptionalObsoleteFiles.inc | 1 |
10 files changed, 3 insertions, 109 deletions
diff --git a/ObsoleteFiles.inc b/ObsoleteFiles.inc index d3a3a597082d..2eaeb068a688 100644 --- a/ObsoleteFiles.inc +++ b/ObsoleteFiles.inc @@ -37,7 +37,9 @@ # -V OLD_FILES -V OLD_LIBS -V OLD_DIRS check-old | \ # xargs -n1 | sort | uniq -d; # done - + +# 20190904: Remove boot1.efifat +OLD_FILES+=boot/boot1.efifat # 20190903: pc-sysinstall(8) removed OLD_FILES+=usr/share/examples/pc-sysinstall/README OLD_FILES+=usr/share/examples/pc-sysinstall/pc-autoinstall.conf diff --git a/stand/efi/boot1/Makefile b/stand/efi/boot1/Makefile index 65b7d4f19364..818f76104bdb 100644 --- a/stand/efi/boot1/Makefile +++ b/stand/efi/boot1/Makefile @@ -62,9 +62,6 @@ CFLAGS+= -I${LDRSRC} FILES= ${BOOT1}.efi FILESMODE_${BOOT1}.efi= ${BINMODE} -.ifndef(NOFAT) -FILES+= ${BOOT1}.efifat -.endif LDSCRIPT= ${EFISRC}/loader/arch/${MACHINE}/ldscript.${MACHINE} LDFLAGS+= -Wl,-T${LDSCRIPT},-Bsymbolic,-znotext -shared @@ -100,24 +97,4 @@ ${BOOT1}.efi: ${PROG} -j .rela.dyn -j .reloc -j .eh_frame \ --output-target=${EFI_TARGET} ${.ALLSRC} ${.TARGET} -.ifndef(NOFAT) -# The following inserts our objects into a template FAT file system -# created by generate-fat.sh - -.include "Makefile.fat" - -${BOOT1}.efifat: ${BOOT1}.efi - @set -- `ls -l ${.ALLSRC}`; \ - x=$$(($$5-${BOOT1_MAXSIZE})); \ - if [ $$x -ge 0 ]; then \ - echo "boot1 $$x bytes too large; regenerate FAT templates?" >&2 ;\ - exit 1; \ - fi - echo ${.OBJDIR} - xz -d -c ${BOOTSRC}/efi/boot1/fat-${MACHINE}.tmpl.xz > ${.TARGET} - ${DD} if=${.ALLSRC} of=${.TARGET} seek=${BOOT1_OFFSET} conv=notrunc - -CLEANFILES+= ${BOOT1}.efi ${BOOT1}.efifat -.endif - .include <bsd.prog.mk> diff --git a/stand/efi/boot1/Makefile.fat b/stand/efi/boot1/Makefile.fat deleted file mode 100644 index 1d40fa8ab54c..000000000000 --- a/stand/efi/boot1/Makefile.fat +++ /dev/null @@ -1,4 +0,0 @@ -# This file autogenerated by generate-fat.sh - DO NOT EDIT -# $FreeBSD$ -BOOT1_OFFSET=0x2d -BOOT1_MAXSIZE=393216 diff --git a/stand/efi/boot1/fat-amd64.tmpl.xz b/stand/efi/boot1/fat-amd64.tmpl.xz Binary files differdeleted file mode 100644 index fe68cd8c2553..000000000000 --- a/stand/efi/boot1/fat-amd64.tmpl.xz +++ /dev/null diff --git a/stand/efi/boot1/fat-arm.tmpl.xz b/stand/efi/boot1/fat-arm.tmpl.xz Binary files differdeleted file mode 100644 index d8fea4150679..000000000000 --- a/stand/efi/boot1/fat-arm.tmpl.xz +++ /dev/null diff --git a/stand/efi/boot1/fat-arm64.tmpl.xz b/stand/efi/boot1/fat-arm64.tmpl.xz Binary files differdeleted file mode 100644 index 9e9fea278e41..000000000000 --- a/stand/efi/boot1/fat-arm64.tmpl.xz +++ /dev/null diff --git a/stand/efi/boot1/fat-i386.tmpl.xz b/stand/efi/boot1/fat-i386.tmpl.xz Binary files differdeleted file mode 100644 index d576a7bcb965..000000000000 --- a/stand/efi/boot1/fat-i386.tmpl.xz +++ /dev/null diff --git a/stand/efi/boot1/generate-fat.sh b/stand/efi/boot1/generate-fat.sh deleted file mode 100755 index a4389f98074a..000000000000 --- a/stand/efi/boot1/generate-fat.sh +++ /dev/null @@ -1,79 +0,0 @@ -#!/bin/sh - -# This script generates the dummy FAT filesystem used for the EFI boot -# blocks. It uses newfs_msdos to generate a template filesystem with the -# relevant interesting files. These are then found by grep, and the offsets -# written to a Makefile snippet. -# -# Because it requires root, and because it is overkill, we do not -# do this as part of the normal build. If makefs(8) grows workable FAT -# support, this should be revisited. - -# $FreeBSD$ - -FAT_SIZE=1600 #Size in 512-byte blocks of the produced image - -BOOT1_OFFSET=2d -BOOT1_SIZE=384k - -if [ $(id -u) != 0 ]; then - echo "${0##*/}: must run as root" >&2 - exit 1 -fi - -# Record maximum boot1 size in bytes -case $BOOT1_SIZE in -*k) - BOOT1_MAXSIZE=$(expr ${BOOT1_SIZE%k} '*' 1024) - ;; -*) - BOOT1_MAXSIZE=$BOOT1_SIZE - ;; -esac - -echo '# This file autogenerated by generate-fat.sh - DO NOT EDIT' > Makefile.fat -echo "# \$FreeBSD\$" >> Makefile.fat -echo "BOOT1_OFFSET=0x$BOOT1_OFFSET" >> Makefile.fat -echo "BOOT1_MAXSIZE=$BOOT1_MAXSIZE" >> Makefile.fat - -while read ARCH FILENAME; do - # Generate 800K FAT image - OUTPUT_FILE=fat-${ARCH}.tmpl - - dd if=/dev/zero of=$OUTPUT_FILE bs=512 count=$FAT_SIZE - DEVICE=`mdconfig -a -f $OUTPUT_FILE` - newfs_msdos -F 12 -L EFISYS $DEVICE - mkdir stub - mount -t msdosfs /dev/$DEVICE stub - - # Create and bless a directory for the boot loader - mkdir -p stub/efi/boot - - # Make a dummy file for boot1 - echo 'Boot1 START' | dd of=stub/efi/boot/$FILENAME cbs=$BOOT1_SIZE count=1 conv=block - # Provide a fallback startup.nsh - echo $FILENAME > stub/efi/boot/startup.nsh - - umount stub - mdconfig -d -u $DEVICE - rmdir stub - - # Locate the offset of the fake file - OFFSET=$(hd $OUTPUT_FILE | grep 'Boot1 START' | cut -f 1 -d ' ') - - # Convert to number of blocks - OFFSET=$(echo 0x$OFFSET | awk '{printf("%x\n",$1/512);}') - - # Validate the offset - if [ $OFFSET != $BOOT1_OFFSET ]; then - echo "Incorrect offset $OFFSET != $BOOT1_OFFSET" >&2 - exit 1 - fi - - xz -f $OUTPUT_FILE -done <<EOF - amd64 BOOTx64.efi - arm64 BOOTaa64.efi - arm BOOTarm.efi - i386 BOOTia32.efi -EOF diff --git a/stand/efi/gptboot/Makefile b/stand/efi/gptboot/Makefile index e4af52b31204..7768cd50ab46 100644 --- a/stand/efi/gptboot/Makefile +++ b/stand/efi/gptboot/Makefile @@ -4,7 +4,6 @@ # we don't want the gptboot.efifat thing created. MK_LOADER_ZFS=no EFI_DEBUG=yes -NOFAT=yes BOOT1?= gptboot .PATH: ${SRCTOP}/stand/efi/boot1 ${SRCTOP}/stand/libsa diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc index 29ea0f24609d..0473c5d7d167 100644 --- a/tools/build/mk/OptionalObsoleteFiles.inc +++ b/tools/build/mk/OptionalObsoleteFiles.inc @@ -618,7 +618,6 @@ OLD_FILES+=boot/boot0 OLD_FILES+=boot/boot0sio OLD_FILES+=boot/boot1 OLD_FILES+=boot/boot1.efi -OLD_FILES+=boot/boot1.efifat OLD_FILES+=boot/boot2 OLD_FILES+=boot/brand.4th OLD_FILES+=boot/cdboot |