Add files via upload
This commit is contained in:
parent
5e1f7e69b9
commit
bd47e02857
1 changed files with 27 additions and 18 deletions
|
@ -17,8 +17,8 @@ if [ "$system" != "n" ]
|
||||||
echo "Scripte werden heruntergeladen!"
|
echo "Scripte werden heruntergeladen!"
|
||||||
pacman -Sy arch-install-scripts xorriso cdrtools squashfs-tools wget
|
pacman -Sy arch-install-scripts xorriso cdrtools squashfs-tools wget
|
||||||
mkdir scripts
|
mkdir scripts
|
||||||
mkdir -p ${work_dir}
|
mkdir ${work_dir}
|
||||||
mkdir -p ${work_dir}/airootfs
|
mkdir ${work_dir}/airootfs
|
||||||
pacstrap -c -d -G -M ${work_dir}/airootfs base base-devel syslinux efibootmgr efitools grub intel-ucode
|
pacstrap -c -d -G -M ${work_dir}/airootfs base base-devel syslinux efibootmgr efitools grub intel-ucode
|
||||||
|
|
||||||
cd ${script_path}
|
cd ${script_path}
|
||||||
|
@ -66,18 +66,24 @@ mkdir ${work_dir}/iso/${install_dir}/${arch}
|
||||||
mkdir ${work_dir}/iso/${install_dir}/boot/${arch}
|
mkdir ${work_dir}/iso/${install_dir}/boot/${arch}
|
||||||
mkdir ${work_dir}/iso/${install_dir}/boot/syslinux
|
mkdir ${work_dir}/iso/${install_dir}/boot/syslinux
|
||||||
|
|
||||||
cp -R ${work_dir}/airootfs/usr/lib/syslinux/bios/* ${work_dir}iso/${install_dir}/boot/syslinux/
|
cp -R ${work_dir}/airootfs/usr/lib/syslinux/bios/* ${work_dir}/iso/${install_dir}/boot/syslinux/
|
||||||
cp ${work_dir}/airootfs/boot/initramfs-linux.img ${work_dir}/iso/arch/boot/${arch}/archiso.img
|
cp ${work_dir}/airootfs/boot/initramfs-linux.img ${work_dir}/iso/arch/boot/${arch}/archiso.img
|
||||||
cp ${work_dir}/airootfs/boot/vmlinuz-linux ${work_dir}/iso/arch/boot/${arch}/
|
cp ${work_dir}/airootfs/boot/vmlinuz-linux ${work_dir}/iso/arch/boot/${arch}/
|
||||||
cp ${work_dir}/airootfs/usr/lib/syslinux/bios/isolinux.bin ${work_dir}/iso/isolinux/
|
cp ${work_dir}/airootfs/usr/lib/syslinux/bios/isolinux.bin ${work_dir}/iso/isolinux/
|
||||||
cp ${work_dir}/airootfs/usr/lib/syslinux/bios/isohdpfx.bin ${work_dir}/iso/isolinux/
|
cp ${work_dir}/airootfs/usr/lib/syslinux/bios/isohdpfx.bin ${work_dir}/iso/isolinux/
|
||||||
cp ${work_dir}/airootfs/usr/lib/syslinux/bios/ldlinux.c32 ${work_dir}/iso/isolinux/
|
cp ${work_dir}/airootfs/usr/lib/syslinux/bios/ldlinux.c32 ${work_dir}/iso/isolinux/
|
||||||
|
|
||||||
|
read -p "Soll das System-Image neu aufgebaut werden?: [Y/n] " image
|
||||||
|
if [ "$image" != "n" ]
|
||||||
|
then
|
||||||
arch-chroot ${work_dir}/airootfs LANG=C pacman -Sl | awk '/\[installed\]$/ {print $1 "/" $2 "-" $3}' > /pkglist.txt
|
arch-chroot ${work_dir}/airootfs LANG=C pacman -Sl | awk '/\[installed\]$/ {print $1 "/" $2 "-" $3}' > /pkglist.txt
|
||||||
cp ${work_dir}/airootfs/pkglist.txt ${work_dir}/iso/${install_dir}/${arch}/
|
cp ${work_dir}/airootfs/pkglist.txt ${work_dir}/iso/${install_dir}/${arch}/
|
||||||
arch-chroot ${work_dir}/airootfs pacman -Scc
|
arch-chroot ${work_dir}/airootfs pacman -Scc
|
||||||
mksquashfs ${work_dir}/airootfs ${work_dir}/iso/${install_dir}/${arch}/airootfs.sfs -noappend -comp xz
|
mksquashfs ${work_dir}/airootfs ${work_dir}/iso/${install_dir}/${arch}/airootfs.sfs -noappend -comp xz
|
||||||
md5sum ${work_dir}/iso/${install_dir}/${arch}/airootfs.sfs > ${work_dir}/iso/${install_dir}/x86_64/airootfs.md5
|
md5sum ${work_dir}/iso/${install_dir}/${arch}/airootfs.sfs > ${work_dir}/iso/${install_dir}/x86_64/airootfs.md5
|
||||||
|
else
|
||||||
|
echo "Image wird nicht neu aufgebaut!!!"
|
||||||
|
fi
|
||||||
|
|
||||||
echo "DEFAULT menu.c32" > ${work_dir}/iso/${install_dir}/boot/syslinux/syslinux.cfg
|
echo "DEFAULT menu.c32" > ${work_dir}/iso/${install_dir}/boot/syslinux/syslinux.cfg
|
||||||
echo "PROMPT 0" >> ${work_dir}/iso/${install_dir}/boot/syslinux/syslinux.cfg
|
echo "PROMPT 0" >> ${work_dir}/iso/${install_dir}/boot/syslinux/syslinux.cfg
|
||||||
|
@ -100,36 +106,37 @@ echo " APPEND /arch/boot/syslinux/" >> ${work_dir}/iso/isolinux/isolinux.cfg
|
||||||
|
|
||||||
# EFI
|
# EFI
|
||||||
|
|
||||||
mkdir -p ${work_dir}/iso/EFI
|
mkdir ${work_dir}/iso/EFI
|
||||||
mkdir -p ${work_dir}/iso/EFI/archiso
|
mkdir ${work_dir}/iso/EFI/archiso
|
||||||
truncate -s 64M ${work_dir}/iso/EFI/archiso/efiboot.img
|
truncate -s 64M ${work_dir}/iso/EFI/archiso/efiboot.img
|
||||||
mkfs.fat -n ARCHISO_EFI ${work_dir}/iso/EFI/archiso/efiboot.img
|
mkfs.fat -n ARCHISO_EFI ${work_dir}/iso/EFI/archiso/efiboot.img
|
||||||
|
|
||||||
mkdir -p ${work_dir}/efiboot
|
mkdir ${work_dir}/efiboot
|
||||||
mount ${work_dir}/iso/EFI/archiso/efiboot.img ${work_dir}/efiboot
|
mount ${work_dir}/iso/EFI/archiso/efiboot.img ${work_dir}/efiboot
|
||||||
|
|
||||||
mkdir -p ${work_dir}/efiboot/EFI/archiso
|
mkdir ${work_dir}/efiboot/EFI/archiso
|
||||||
cp ${work_dir}/iso/${install_dir}/boot/${arch}/vmlinuz ${work_dir}/efiboot/EFI/archiso/vmlinuz.efi
|
cp ${work_dir}/iso/${install_dir}/boot/${arch}/vmlinuz-linux ${work_dir}/efiboot/EFI/archiso/vmlinuz.efi
|
||||||
cp ${work_dir}/iso/${install_dir}/boot/${arch}/archiso.img ${work_dir}/efiboot/EFI/archiso/archiso.img
|
cp ${work_dir}/iso/${install_dir}/boot/${arch}/archiso.img ${work_dir}/efiboot/EFI/archiso/archiso.img
|
||||||
|
|
||||||
cp ${work_dir}/airootfs/boot/intel-ucode.img ${work_dir}/iso/${install_dir}/boot/intel_ucode.img
|
cp ${work_dir}/airootfs/boot/intel-ucode.img ${work_dir}/iso/${install_dir}/boot/intel_ucode.img
|
||||||
cp ${work_dir}/iso/${install_dir}/boot/intel_ucode.img ${work_dir}/efiboot/EFI/archiso/intel_ucode.img
|
cp ${work_dir}/iso/${install_dir}/boot/intel_ucode.img ${work_dir}/efiboot/EFI/archiso/intel_ucode.img
|
||||||
|
|
||||||
mkdir -p ${work_dir}/efiboot/EFI/boot
|
mkdir ${work_dir}/efiboot/EFI/boot
|
||||||
cp ${work_dir}/airootfs/usr/share/efitools/efi/PreLoader.efi ${work_dir}/efiboot/EFI/boot/bootx64.efi
|
cp ${work_dir}/airootfs/usr/share/efitools/efi/PreLoader.efi ${work_dir}/efiboot/EFI/boot/bootx64.efi
|
||||||
|
|
||||||
cp ${work_dir}/airootfs/usr/share/efitools/efi/HashTool.efi ${work_dir}/efiboot/EFI/boot/
|
cp ${work_dir}/airootfs/usr/share/efitools/efi/HashTool.efi ${work_dir}/efiboot/EFI/boot/
|
||||||
|
|
||||||
cp ${work_dir}/airootfs/usr/lib/systemd/boot/efi/systemd-bootx64.efi ${work_dir}/efiboot/EFI/boot/loader.efi
|
cp ${work_dir}/airootfs/usr/lib/systemd/boot/efi/systemd-bootx64.efi ${work_dir}/efiboot/EFI/boot/loader.efi
|
||||||
|
|
||||||
|
mkdir ${work_dir}/efiboot/loader/entries
|
||||||
|
|
||||||
cd ${script_path}
|
cd ${script_path}
|
||||||
wget -c https://raw.githubusercontent.com/simono41/archiso/master/configs/releng/efiboot/loader/entries/uefi-shell-v1-x86_64.conf
|
wget -c https://raw.githubusercontent.com/simono41/archiso/master/configs/releng/efiboot/loader/entries/uefi-shell-v1-x86_64.conf
|
||||||
wget -c https://raw.githubusercontent.com/simono41/archiso/master/configs/releng/efiboot/loader/entries/uefi-shell-v2-x86_64.conf
|
wget -c https://raw.githubusercontent.com/simono41/archiso/master/configs/releng/efiboot/loader/entries/uefi-shell-v2-x86_64.conf
|
||||||
wget -c https://raw.githubusercontent.com/simono41/archiso/master/configs/releng/efiboot/loader/loader.conf
|
wget -c https://raw.githubusercontent.com/simono41/archiso/master/configs/releng/efiboot/loader/loader.conf
|
||||||
mkdir -p ${work_dir}/efiboot/loader/entries
|
cp loader.conf ${work_dir}/efiboot/loader/
|
||||||
cp ${script_path}/loader.conf ${work_dir}/efiboot/loader/
|
cp uefi-shell-v2-x86_64.conf ${work_dir}/efiboot/loader/entries/
|
||||||
cp ${script_path}/uefi-shell-v2-x86_64.conf ${work_dir}/efiboot/loader/entries/
|
cp uefi-shell-v1-x86_64.conf ${work_dir}/efiboot/loader/entries/
|
||||||
cp ${script_path}/uefi-shell-v1-x86_64.conf ${work_dir}/efiboot/loader/entries/
|
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
wget -c https://raw.githubusercontent.com/simono41/archiso/master/configs/releng/efiboot/loader/entries/archiso-x86_64-cd.conf
|
wget -c https://raw.githubusercontent.com/simono41/archiso/master/configs/releng/efiboot/loader/entries/archiso-x86_64-cd.conf
|
||||||
|
@ -142,15 +149,13 @@ cp ${work_dir}/iso/EFI/shellx64_v2.efi ${work_dir}/efiboot/EFI/
|
||||||
cp ${work_dir}/iso/EFI/shellx64_v1.efi ${work_dir}/efiboot/EFI/
|
cp ${work_dir}/iso/EFI/shellx64_v1.efi ${work_dir}/efiboot/EFI/
|
||||||
umount -d ${work_dir}/efiboot
|
umount -d ${work_dir}/efiboot
|
||||||
|
|
||||||
mkdir -p ${work_dir}/iso/EFI/boot
|
mkdir ${work_dir}/iso/EFI/boot
|
||||||
cd ${script_path}
|
|
||||||
cp ${script_path}/efiboot/loader/loader.conf ${work_dir}/iso/loader/
|
cp ${script_path}/efiboot/loader/loader.conf ${work_dir}/iso/loader/
|
||||||
cp ${script_path}/efiboot/loader/entries/uefi-shell-v2-x86_64.conf ${work_dir}/iso/loader/entries/
|
cp ${script_path}/efiboot/loader/entries/uefi-shell-v2-x86_64.conf ${work_dir}/iso/loader/entries/
|
||||||
cp ${script_path}/efiboot/loader/entries/uefi-shell-v1-x86_64.conf ${work_dir}/iso/loader/entries/
|
cp ${script_path}/efiboot/loader/entries/uefi-shell-v1-x86_64.conf ${work_dir}/iso/loader/entries/
|
||||||
cd ..
|
|
||||||
|
|
||||||
mkdir -p ${work_dir}/iso/loader
|
mkdir ${work_dir}/iso/loader
|
||||||
mkdir -p ${work_dir}/iso/loader/entries
|
mkdir ${work_dir}/iso/loader/entries
|
||||||
cd ${script_path}
|
cd ${script_path}
|
||||||
cp uefi-shell-v1-x86_64.conf ${work_dir}/iso/loader/entries/uefi-shell-v1-x86_64.conf
|
cp uefi-shell-v1-x86_64.conf ${work_dir}/iso/loader/entries/uefi-shell-v1-x86_64.conf
|
||||||
cp uefi-shell-v2-x86_64.conf ${work_dir}/iso/loader/entries/uefi-shell-v2-x86_64.conf
|
cp uefi-shell-v2-x86_64.conf ${work_dir}/iso/loader/entries/uefi-shell-v2-x86_64.conf
|
||||||
|
@ -181,5 +186,9 @@ xorriso -as mkisofs \
|
||||||
-eltorito\-catalog isolinux/boot.cat \
|
-eltorito\-catalog isolinux/boot.cat \
|
||||||
-no-emul-boot -boot-load-size 4 -boot-info-table \
|
-no-emul-boot -boot-load-size 4 -boot-info-table \
|
||||||
-isohybrid-mbr $(pwd)/${work_dir}/iso/isolinux/isohdpfx.bin \
|
-isohybrid-mbr $(pwd)/${work_dir}/iso/isolinux/isohdpfx.bin \
|
||||||
|
-eltorito-alt-boot \
|
||||||
|
-e EFI/archiso/efiboot.img \
|
||||||
|
-no-emul-boot \
|
||||||
|
-isohybrid-gpt-basdat \
|
||||||
-output ${out_dir}/arch-${iso_label}-$(date "+%y.%m.%d")-${arch}.iso ${work_dir}/iso/
|
-output ${out_dir}/arch-${iso_label}-$(date "+%y.%m.%d")-${arch}.iso ${work_dir}/iso/
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue