OSDN Git Service

[update] : Added norescue_entry
authorhayao <shun819.mail@gmail.com>
Sun, 11 Oct 2020 03:16:00 +0000 (12:16 +0900)
committerhayao <shun819.mail@gmail.com>
Tue, 13 Oct 2020 14:26:49 +0000 (23:26 +0900)
allarch.sh
build.sh
channels/releng/config.any
channels/releng/syslinux/archiso_select.cfg [deleted file]
channels/releng/syslinux/archiso_sys_nosplash.cfg [deleted file]
default.conf

index d5586ad..0edc5d3 100755 (executable)
@@ -496,6 +496,7 @@ prepare_build() {
     check_bool noiso
     check_bool noaur
     check_bool customized_syslinux
+    check_bool norescue_entry
 
     # Unmount
     umount_chroot
@@ -963,7 +964,11 @@ make_syslinux() {
     fi
 
     # Rename rescue config
-    mv "${work_dir}/iso/${install_dir}/boot/syslinux/archiso_sys_rescue.cfg" "${work_dir}/iso/${install_dir}/boot/syslinux/archiso_sys_rescue_${arch}.cfg"
+    if [[ "${norescue_entry}" = false ]]; then
+        mv "${work_dir}/iso/${install_dir}/boot/syslinux/archiso_sys_rescue.cfg" "${work_dir}/iso/${install_dir}/boot/syslinux/archiso_sys_rescue_${arch}.cfg"
+    else
+        remove "${work_dir}/iso/${install_dir}/boot/syslinux/archiso_sys_rescue.cfg"
+    fi
 
     # copy files
     cp "${work_dir}"/${arch}/airootfs/usr/lib/syslinux/bios/*.c32 "${work_dir}/iso/${install_dir}/boot/syslinux"
@@ -982,7 +987,7 @@ make_syslinux_loadfiles() {
         _write_load "INCLUDE boot/syslinux/archiso_head.cfg"
         for _arch in ${all_arch[@]}; do 
             _write_load "INCLUDE boot/syslinux/archiso_${_pxe_or_sys}_${_arch}.cfg"
-            if [[ "${_pxe_or_sys}" = "sys" ]]; then
+            if [[ "${_pxe_or_sys}" = "sys" ]] && [[ "${norescue_entry}" = false ]]; then
                 _write_load "INCLUDE boot/syslinux/archiso_sys_rescue_${arch}.cfg"
             fi
         done
index b41f685..c27fe48 100755 (executable)
--- a/build.sh
+++ b/build.sh
@@ -585,6 +585,7 @@ prepare_build() {
     check_bool noiso
     check_bool noaur
     check_bool customized_syslinux
+    check_bool norescue_entry
     check_bool rebuild
     check_bool debug
     check_bool bash_debug
@@ -1058,6 +1059,12 @@ make_syslinux() {
         cp "${script_path}/syslinux/splash.png" "${work_dir}/iso/${install_dir}/boot/syslinux"
     fi
 
+    # Remove rescue config
+    if [[ "${norescue_entry}" = true ]]; then
+        remove "${work_dir}/iso/${install_dir}/boot/syslinux/archiso_sys_rescue.cfg"
+        sed -i "s|$(cat "${work_dir}/iso/${install_dir}/boot/syslinux/archiso_sys_load.cfg" | grep "archiso_sys_rescue")||g" "${work_dir}/iso/${install_dir}/boot/syslinux/archiso_sys_load.cfg" 
+    fi
+
     # copy files
     cp "${work_dir}"/${arch}/airootfs/usr/lib/syslinux/bios/*.c32 "${work_dir}/iso/${install_dir}/boot/syslinux"
     cp "${work_dir}/${arch}/airootfs/usr/lib/syslinux/bios/lpxelinux.0" "${work_dir}/iso/${install_dir}/boot/syslinux"
index 90583fb..51ae1ff 100644 (file)
@@ -62,6 +62,11 @@ kernel_mkinitcpio_profile="${_kernel_config_line[2]}"
 # Change the default behavior of "--shmkalteriso".
 shmkalteriso=true
 
+# Do not add rescue mode launch items
+# If true, do not add items such as "without GUI" or "Safe graphics".
+# This setting cannot be changed by an argument.
+norescue_entry=true
+
 # List of packages required for build
 # The following packages are checked to see if they are installed before running build.sh
 # Also, wizard.sh will install it automatically.
diff --git a/channels/releng/syslinux/archiso_select.cfg b/channels/releng/syslinux/archiso_select.cfg
deleted file mode 100644 (file)
index bf59640..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-# Yamada Hayao
-# Twitter: @Hayao0819
-# Email  : hayao@fascode.net
-#
-# (c) 2019-2020 Fascode Network.
-#
-
-DEFAULT arch_%ARCH%
-TIMEOUT 100
diff --git a/channels/releng/syslinux/archiso_sys_nosplash.cfg b/channels/releng/syslinux/archiso_sys_nosplash.cfg
deleted file mode 100644 (file)
index 3c2b40c..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-# Yamada Hayao
-# Twitter: @Hayao0819
-# Email  : hayao@fascode.net
-#
-# (c) 2019-2020 Fascode Network.
-#
-
-LABEL arch_%ARCH%
-TEXT HELP
-Boot the %OS_NAME% (%ARCH%) live medium.
-It allows you to install %OS_NAME% or perform system maintenance.
-ENDTEXT
-MENU LABEL Boot %OS_NAME% (%ARCH%)
-LINUX boot/%ARCH%/%KERNEL_FILENAME%
-INITRD boot/intel_ucode.img,boot/amd_ucode.img,boot/%ARCH%/archiso.img
-APPEND archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL%
index 1fbb92c..1d3dbfc 100644 (file)
@@ -114,6 +114,11 @@ include_info=true
 # This setting cannot be changed by an argument.
 customized_syslinux=true
 
+# Do not add rescue mode launch items
+# If true, do not add items such as "without GUI" or "Safe graphics".
+# This setting cannot be changed by an argument.
+norescue_entry=false
+
 
 #-- kernel config --#
 # Set the kernel that live session use.