OSDN Git Service

fixed arch name
authorkokkiemouse <kokkiemouse@gmail.com>
Fri, 11 Sep 2020 22:29:14 +0000 (07:29 +0900)
committerkokkiemouse <kokkiemouse@gmail.com>
Fri, 11 Sep 2020 22:29:14 +0000 (07:29 +0900)
channels/releng/codename.x86_64 [moved from channels/releng/codename.amd64 with 100% similarity]
lfbs

diff --git a/lfbs b/lfbs
index 726e4ba..513fb37 100755 (executable)
--- a/lfbs
+++ b/lfbs
@@ -23,7 +23,7 @@ codename="32"
 os_name="Fedora"
 iso_name="Fedora"
 
-arch=amd64
+arch=x86_64
 
 out_dir="${script_path}/out"
 iso_label="${os_name}_${codename}_${arch}"
@@ -263,6 +263,23 @@ make_basefs() {
     # run_cmd apt-get upgrade
 }
 
+
+prepare_build() {
+    if [[ ${EUID} -ne 0 ]]; then
+        _msg_error "This script must be run as root." 1
+    fi
+
+    [[ ! -d "${work_dir}" ]] && mkdir -p "${work_dir}"
+    [[ ! -d "${out_dir}" ]] && mkdir -p "${out_dir}"
+    umount_chroot
+
+    # Check codename
+    if [[ -z $(grep -h -v ^'#' ${channels_dir}/${channel_name}/codename.${arch} | grep -x ${codename}) ]]; then
+        _msg_error "This codename (${channel_name}) is not supported on this channel (${codename})."
+    fi
+
+}
+
 # 引数解析()
 # 参考記事:https://0e0.pw/ci83 https://0e0.pw/VJlg