]> git.ipfire.org Git - ipfire-2.x.git/blobdiff - lfs/cdrom
suricata: Change midstream policy to "pass-flow"
[ipfire-2.x.git] / lfs / cdrom
index f18b80a033dc57bf13c9350789e100aa032ecf52..fed69f171539731ebdabf381ae499af3ce5d68a5 100644 (file)
--- a/lfs/cdrom
+++ b/lfs/cdrom
@@ -1,7 +1,7 @@
 ###############################################################################
 #                                                                             #
 # IPFire.org - A linux based firewall                                         #
-# Copyright (C) 2007-2018  IPFire Team  <info@ipfire.org>                     #
+# Copyright (C) 2007-2021  IPFire Team  <info@ipfire.org>                     #
 #                                                                             #
 # This program is free software: you can redistribute it and/or modify        #
 # it under the terms of the GNU General Public License as published by        #
@@ -32,16 +32,9 @@ TARGET     = $(DIR_INFO)/$(THISAPP)
 # Fail when there is an error in the tar pipe
 SHELL=/bin/bash -o pipefail
 
-ifeq "$(BUILD_PLATFORM)" "arm"
-       TAR_OPTIONS =
-else
-       TAR_OPTIONS = --lzma
-endif
-
 HAS_MEMTEST = 0
 HAS_IPXE = 0
 HAS_ISOLINUX = 0
-HAS_KERNEL = 1
 
 ifeq "$(BUILD_PLATFORM)" "x86"
        HAS_MEMTEST = 1
@@ -49,10 +42,6 @@ ifeq "$(BUILD_PLATFORM)" "x86"
        HAS_ISOLINUX = 1
 endif
 
-ifeq "$(BUILD_ARCH)" "armv5tel"
-       HAS_KERNEL = 0
-endif
-
 ISO_ARGS = -J -r -v \
        -A "$(NAME) $(VERSION) $(BUILD_ARCH)" \
        -V "$(NAME) $(VERSION) $(BUILD_ARCH)"
@@ -129,6 +118,8 @@ GRUB_EFI_MODULES = \
        true \
        usb_keyboard
 
+ISO_FILE = /install/images/$(SNAME)-$(VERSION)-core$(CORE)-$(BUILD_ARCH).iso
+
 ###############################################################################
 # Top-level Rules
 ###############################################################################
@@ -139,7 +130,7 @@ check :
 
 download :
 
-md5 :
+b2 :
 
 ###############################################################################
 # Installation Details
@@ -155,7 +146,7 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
 
        # Clear mtab (prevents .journal problems)
        rm -vf /etc/mtab
-       echo > /etc/mtab
+       ln -s /proc/self/mounts /etc/mtab
 
        # Create filelist for packaging.
        BUILDTARGET="$(BUILDTARGET)" BUILD_ARCH="$(BUILD_ARCH)" KVER="$(KVER)" \
@@ -166,12 +157,12 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
        # Compress root filesystem
        # Reason for this tar+untar+tar is removing of entries listed two or more in src/ROOTFILES
        rm -rf $(DIR_TMP)/root && mkdir -p $(DIR_TMP)/root
-       tar -c --exclude='#*' --exclude='proc/*' --exclude='dev/pts/*' --exclude='tmp/*' \
+       tar $(TAR_OPTIONS) -c --exclude='#*' --exclude='proc/*' --exclude='dev/pts/*' --exclude='tmp/*' \
                --exclude='__pycache__' \
-               -C / --files-from=$(DIR_TMP)/ROOTFILES | tar -x -C $(DIR_TMP)/root
+               -C / --files-from=$(DIR_TMP)/ROOTFILES | tar $(TAR_OPTIONS) -x -C $(DIR_TMP)/root
        rm -f $(DIR_TMP)/ROOTFILES
        mkdir $(DIR_TMP)/root/sys
-       cd $(DIR_TMP)/root && tar cf - * | xz $(XZ_OPT) > $(DIR_TMP)/cdrom/distro.img
+       cd $(DIR_TMP)/root && tar $(TAR_OPTIONS) -cf - * | zstd $(ZSTD_OPTIONS) > $(DIR_TMP)/cdrom/distro.img
        rm -rf $(DIR_TMP)/root
 
        # Other files
@@ -185,10 +176,8 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
 
        mkdir -p $(DIR_TMP)/cdrom/boot/isolinux
 
-ifeq "$(HAS_KERNEL)" "1"
        cp /boot/vmlinuz-$(KVER)-ipfire $(DIR_TMP)/cdrom/boot/isolinux/vmlinuz
-       dracut --force --early-microcode -a "installer" --strip --xz $(DIR_TMP)/cdrom/boot/isolinux/instroot $(KVER)-ipfire
-endif
+       dracut --force -a "installer" --strip $(DIR_TMP)/cdrom/boot/isolinux/instroot $(KVER)-ipfire
 
 ifeq "$(HAS_ISOLINUX)" "1"
        dd if=/dev/zero  bs=1k count=2            > $(DIR_TMP)/cdrom/boot/isolinux/boot.catalog
@@ -203,7 +192,7 @@ endif
 
 ifeq "$(HAS_MEMTEST)" "1"
        # Install memtest
-       cp /usr/lib/memtest86+/memtest.bin $(DIR_TMP)/cdrom/boot/isolinux/memtest
+       cp /usr/lib/memtest86+/memtest.efi $(DIR_TMP)/cdrom/boot/isolinux/memtest
 endif
 
 ifeq "$(HAS_IPXE)" "1"
@@ -231,7 +220,7 @@ ifeq "$(EFI)" "1"
                < $(DIR_SRC)/config/cdrom/grub.cfg > $(DIR_TMP)/cdrom/EFI/BOOT/grub.cfg
 
        # Create the EFI Eltorito image
-       dd if=/dev/zero of=$(DIR_TMP)/cdrom/boot/isolinux/efiboot.img bs=1k count=1440
+       dd if=/dev/zero of=$(DIR_TMP)/cdrom/boot/isolinux/efiboot.img bs=1k count=2880
        mkdosfs -F 12 -n "IPFIRE_EFI" $(DIR_TMP)/cdrom/boot/isolinux/efiboot.img
 
        # Mount the EFI image
@@ -252,9 +241,8 @@ endif
                                                xargs md5sum > md5sum.txt
 
        mkdir -p /install/images
-       cd $(DIR_TMP)/cdrom && mkisofs $(ISO_ARGS) \
-               -o /install/images/$(SNAME)-$(VERSION).$(BUILD_ARCH)-full-core$(CORE).iso .
+       cd $(DIR_TMP)/cdrom && mkisofs $(ISO_ARGS) -o $(ISO_FILE) .
 
 ifeq "$(HAS_ISOLINUX)" "1"
-       isohybrid $(ISOHYBRID_ARGS) /install/images/$(SNAME)-$(VERSION).$(BUILD_ARCH)-full-core$(CORE).iso
+       isohybrid $(ISOHYBRID_ARGS) $(ISO_FILE)
 endif