diff options
author | Matt Housh <jaeger@morpheus.net> | 2014-01-11 15:42:24 -0600 |
---|---|---|
committer | Matt Housh <jaeger@morpheus.net> | 2014-01-11 15:42:24 -0600 |
commit | 22481f11da4f25cc5dc4f2679d250a563ebdde35 (patch) | |
tree | 74b55fab588d0da552a2edaae032e5fb497d08d3 /Makefile | |
parent | a05d0a5ddfbdcc6569003adee0e259e8e026a0f3 (diff) | |
download | iso-22481f11da4f25cc5dc4f2679d250a563ebdde35.tar.gz iso-22481f11da4f25cc5dc4f2679d250a563ebdde35.tar.xz |
Initial updates for 3.1
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 71 |
1 files changed, 67 insertions, 4 deletions
@@ -7,10 +7,11 @@ CRUXVERSION = 3.0 CUSTOMVERSION = COLLECTIONS = core opt xorg KERNEL_MIRROR = http://www.kernel.org -KERNEL_VERSION = 3.6.11 +KERNEL_VERSION = 3.7.10 KERNEL_PATCHES = BB_VERSION = 1.20.2 SYSLINUX_VERSION = 4.04 +GRUB2_VERSION = 2.00 MEMTEST_VERSION = 4.20 PKG_EXT = pkg.tar.xz PKGMK_CONF = $(PWD)/pkgmk.conf @@ -145,11 +146,66 @@ syslinux: iso/syslinux-$(SYSLINUX_VERSION)/isolinux.bin syslinux-clean: rm -rf iso/syslinux-$(SYSLINUX_VERSION) -syslinux-distclean: +syslinux-distclean: syslinux-clean rm -f iso/syslinux-$(SYSLINUX_VERSION).tar.gz +# grub2-efi +iso/grub-$(GRUB2_VERSION).tar.xz: + cd iso && wget http://ftp.gnu.org/gnu/grub/grub-$(GRUB2_VERSION).tar.xz + +iso/grub-$(GRUB2_VERSION): iso/grub-$(GRUB2_VERSION).tar.xz + tar -C iso -xJmf iso/grub-$(GRUB2_VERSION).tar.xz + sed -i -e '/gets is a/d' iso/grub-$(GRUB2_VERSION)/grub-core/gnulib/stdio.in.h + +iso/grub-$(GRUB2_VERSION)/x86_64/grub2-x86_64.efi: iso/grub-$(GRUB2_VERSION) + (cd iso/grub-$(GRUB2_VERSION) && \ + mkdir x86_64 && \ + cd x86_64 && \ + CFLAGS="-Wno-error" ../configure --with-platform=efi --target=x86_64 && \ + make && \ + cd grub-core && \ + ../grub-mkimage -d . -p '(cd0)/boot/grub' -o ../grub2-x86_64.efi \ + -O x86_64-efi '--prefix=(cd0)/boot/grub' \ + $(shell find *.mod | xargs | sed 's/.mod//g')) + +iso/grub-$(GRUB2_VERSION)/i386/grub2-i386.efi: iso/grub-$(GRUB2_VERSION) + (cd iso/grub-$(GRUB2_VERSION) && \ + mkdir i386 && \ + cd i386 && \ + CFLAGS="-Wno-error" ../configure --with-platform=efi --target=i386 && \ + make && \ + cd grub-core && \ + ../grub-mkimage -d . -p '(cd0)/boot/grub' -o ../grub2-i386.efi \ + -O i386-efi '--prefix=(cd0)/boot/grub' \ + $(shell find *.mod | xargs | sed 's/.mod//g')) + +grub2-efi: iso/grub-$(GRUB2_VERSION)/x86_64/grub2-x86_64.efi iso/grub-$(GRUB2_VERSION)/i386/grub2-i386.efi + +iso/efiboot.img: grub2-efi + dd if=/dev/zero of=iso/efiboot.img bs=1M count=8 + mkdosfs -n CRUX-EFI iso/efiboot.img + mkdir -p iso/efiboot + mount -o loop iso/efiboot.img iso/efiboot + mkdir -pv iso/efiboot/EFI/boot \ + iso/efiboot/boot/grub/x86_64-efi \ + iso/efiboot/boot/grub/i386-efi + cp iso/grub-$(GRUB2_VERSION)/x86_64/grub2-x86_64.efi \ + iso/efiboot/EFI/boot/bootx64.efi + cp iso/grub-$(GRUB2_VERSION)/i386/grub2-i386.efi \ + iso/efiboot/EFI/boot/bootia32.efi + umount iso/efiboot + +grub2-efi-clean: + rm -rf iso/grub-$(GRUB2_VERSION) iso/efiboot iso/efiboot.img + +grub2-efi-distclean: grub2-efi-clean + rm -f iso/grub2-$(GRUB2_VERSION).tar.xz + + + + # memtest86+ iso/isolinux/memtest86+-$(MEMTEST_VERSION).bin.gz: cd iso/isolinux && wget http://www.memtest.org/download/$(MEMTEST_VERSION)/memtest86+-$(MEMTEST_VERSION).bin.gz @@ -340,7 +396,7 @@ check-portstree: packages.all ##### image building ##### -image-base: check-root kernel syslinux initramfs rootfs setup.dependencies +image-base: check-root kernel syslinux initramfs rootfs setup.dependencies iso/efiboot.img @echo "Creating installation image base" @if [ -e $(IMG_ROOT_DIR) ]; then rm -rf $(IMG_ROOT_DIR); fi @mkdir -p $(IMG_ROOT_DIR)/boot @@ -382,6 +438,11 @@ iso: image-base memtest @cp iso/isolinux/{isolinux.cfg,*.msg} \ $(IMG_ROOT_DIR)/boot/isolinux @cp iso/isolinux/memtest86+-$(MEMTEST_VERSION).bin $(IMG_ROOT_DIR)/boot/isolinux/memtest86plus + @cp iso/efiboot.img $(IMG_ROOT_DIR)/boot/ + @mkdir -p $(IMG_ROOT_DIR)/boot/grub/{x86_64,i386}-efi + @cp -a iso/grub-$(GRUB2_VERSION)/x86_64/grub-core/*.{mod,lst} $(IMG_ROOT_DIR)/boot/grub/x86_64-efi/ + @cp -a iso/grub-$(GRUB2_VERSION)/i386/grub-core/*.{mod,lst} $(IMG_ROOT_DIR)/boot/grub/i386-efi/ + @cp iso/grub.cfg $(IMG_ROOT_DIR)/boot/grub/ @echo "- Creating ISO sort table" @echo "$(IMG_ROOT_DIR)/boot 100" > /tmp/iso.sort @echo "$(IMG_ROOT_DIR)/boot/isolinux 200" >> /tmp/iso.sort @@ -391,7 +452,9 @@ iso: image-base memtest @genisoimage -R -l -J -V "CRUX-$(CRUXVERSION)$(CUSTOMVERSION)" -A CRUX \ -b boot/isolinux/isolinux.bin \ -c boot/isolinux/isolinux.boot -no-emul-boot -boot-load-size 4 \ - -boot-info-table -sort /tmp/iso.sort -o "$(ISO_FILENAME)" $(IMG_ROOT_DIR) + -boot-info-table \ + -eltorito-alt-boot -e boot/efiboot.img -no-emul-boot \ + -sort /tmp/iso.sort -o "$(ISO_FILENAME)" $(IMG_ROOT_DIR) @md5sum `basename $(ISO_FILENAME)` > `basename $(ISO_FILENAME) .iso`.md5 @rm /tmp/iso.sort @echo "Done" |