diff options
-rw-r--r-- | distrib/amd64/common/Makefile.inc | 16 | ||||
-rw-r--r-- | distrib/amd64/ramdisk_cd/Makefile | 5 | ||||
-rw-r--r-- | distrib/amd64/ramdisk_cd/template | 1 |
3 files changed, 18 insertions, 4 deletions
diff --git a/distrib/amd64/common/Makefile.inc b/distrib/amd64/common/Makefile.inc index 340103b9663..46f50dec193 100644 --- a/distrib/amd64/common/Makefile.inc +++ b/distrib/amd64/common/Makefile.inc @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile.inc,v 1.26 2014/03/29 17:31:40 deraadt Exp $ +# $OpenBSD: Makefile.inc,v 1.27 2015/09/06 19:35:19 kettenis Exp $ TOP= ${.CURDIR}/.. @@ -18,9 +18,12 @@ VND?= vnd0 VND_DEV= /dev/${VND}a VND_RDEV= /dev/r${VND}a VND_CRDEV= /dev/r${VND}c +VND_IDEV= /dev/${VND}i +VND_IRDEV= /dev/r${VND}i PID!= echo $$$$ REALIMAGE!= echo /var/tmp/image.${PID} BOOT?= ${DESTDIR}/usr/mdec/boot +EFIBOOT?= ${DESTDIR}/usr/mdec/BOOTX64.EFI FLOPPYSIZE?= 2880 FLOPPYTYPE?= floppy3 @@ -30,9 +33,18 @@ ${FS}: bsd.gz dd if=/dev/zero of=${REALIMAGE} bs=512 count=${FLOPPYSIZE} vnconfig -v -c ${VND} ${REALIMAGE} .ifdef LBA - fdisk -yi -l ${FLOPPYSIZE} -f ${DESTDIR}/usr/mdec/mbr ${VND} + fdisk -yi -l ${FLOPPYSIZE} -b 960 -f ${DESTDIR}/usr/mdec/mbr ${VND} .endif +.ifdef TEMPLATE + disklabel -wAT ${TEMPLATE} ${VND} + newfs -t msdos ${VND_IRDEV} + mount ${VND_IDEV} ${MOUNT_POINT} + mkdir -p ${MOUNT_POINT}/efi/boot + cp ${EFIBOOT} ${MOUNT_POINT}/efi/boot + umount ${MOUNT_POINT} +.else disklabel -w ${VND} ${FLOPPYTYPE} +.endif newfs -m 0 -o space -i 524288 -c ${FLOPPYSIZE} ${VND_RDEV} mount ${VND_DEV} ${MOUNT_POINT} cp ${BOOT} ${.OBJDIR}/boot diff --git a/distrib/amd64/ramdisk_cd/Makefile b/distrib/amd64/ramdisk_cd/Makefile index 88a593d3f08..5605e838990 100644 --- a/distrib/amd64/ramdisk_cd/Makefile +++ b/distrib/amd64/ramdisk_cd/Makefile @@ -1,11 +1,12 @@ -# $OpenBSD: Makefile,v 1.7 2014/07/16 19:59:30 okan Exp $ +# $OpenBSD: Makefile,v 1.8 2015/09/06 19:35:19 kettenis Exp $ .PATH: ${.CURDIR}/../ramdisk RAMDISK=RAMDISK_CD -FLOPPYSIZE=6976 +FLOPPYSIZE=7936 FLOPPYTYPE=mini34 XNAME=miniroot LBA=1 +TEMPLATE=${.CURDIR}/template .include "${.CURDIR}/../common/Makefile.inc" diff --git a/distrib/amd64/ramdisk_cd/template b/distrib/amd64/ramdisk_cd/template new file mode 100644 index 00000000000..74743914568 --- /dev/null +++ b/distrib/amd64/ramdisk_cd/template @@ -0,0 +1 @@ +/ 2M-* 100% |