diff --git a/bin/buildiso.in b/bin/buildiso.in index 8bf7090..4fe99cb 100755 --- a/bin/buildiso.in +++ b/bin/buildiso.in @@ -35,8 +35,8 @@ show_profile(){ [[ ${target_arch} == 'x86_64' ]] && msg2 "multilib: %s" "${multilib}" msg2 "netinstall: %s" "${netinstall}" + msg2 "chrootcfg: %s" "${chrootcfg}" ${netinstall} && msg2 "netgroups: %s" "$(get_yaml)" - msg2 "unpackfs: %s" "${unpackfs}" msg2 "geoip: %s" "${geoip}" msg2 "efi_boot_loader: %s" "${efi_boot_loader}" diff --git a/bin/check-yaml.in b/bin/check-yaml.in index 0a30a40..5effd18 100644 --- a/bin/check-yaml.in +++ b/bin/check-yaml.in @@ -33,8 +33,9 @@ show_profile(){ [[ ${target_arch} == 'x86_64' ]] && msg2 "multilib: %s" "${multilib}" msg2 "netinstall: %s" "${netinstall}" + msg2 "chrootcfg: %s" "${chrootcfg}" ${netinstall} && msg2 "netgroups: %s" "$(get_yaml)" - msg2 "unpackfs: %s" "${unpackfs}" + msg2 "geoip: %s" "${geoip}" msg2 "efi_boot_loader: %s" "${efi_boot_loader}" diff --git a/data/profile.conf.example b/data/profile.conf.example index 5d7eef5..bef60eb 100644 --- a/data/profile.conf.example +++ b/data/profile.conf.example @@ -40,8 +40,8 @@ # the default url for the netinstall.yaml # netgroups="https://raw.githubusercontent.com/manjaro/manjaro-tools-iso-profiles/master/shared/netinstall" -# configure calamares to use chrootcfg instead of unpackfs -# unpackfs="true" +# configure calamares to use chrootcfg instead of unpackfs; default: unpackfs +# chrootcfg="false" # use geoip # geoip="true" diff --git a/docbook/profile.conf.xml b/docbook/profile.conf.xml index 52b098c..ae1b523 100644 --- a/docbook/profile.conf.xml +++ b/docbook/profile.conf.xml @@ -141,7 +141,7 @@ - unpackfs= + chrootcfg= Accepts (the default) diff --git a/lib/util-iso-image.sh b/lib/util-iso-image.sh index aa88e9a..475a08b 100644 --- a/lib/util-iso-image.sh +++ b/lib/util-iso-image.sh @@ -201,6 +201,19 @@ configure_system(){ esac } +configure_live_image(){ + msg "Configuring [live-image]" + detect_desktop_env "$1" + configure_hosts "$1" + configure_lsb "$1" + configure_mhwd "$1" + configure_system "$1" + configure_services "$1" + configure_calamares "$1" + write_live_session_conf "$1" + msg "Done configuring [live-image]" +} + make_repo(){ repo-add $1${mhwd_repo}/mhwd.db.tar.gz $1${mhwd_repo}/*pkg*z } diff --git a/lib/util-iso.sh b/lib/util-iso.sh index e0a9569..496c2db 100644 --- a/lib/util-iso.sh +++ b/lib/util-iso.sh @@ -171,12 +171,8 @@ make_iso() { gen_iso_fn(){ local vars=() name vars+=("${iso_name}") - if ! ${netinstall};then + if ! ${chrootcfg};then [[ -n ${profile} ]] && vars+=("${profile}") - else - if ${unpackfs};then - [[ -n ${profile} ]] && vars+=("${profile}") - fi fi [[ ${initsys} == 'openrc' ]] && vars+=("${initsys}") vars+=("${dist_release}") @@ -246,19 +242,6 @@ mount_image_select(){ fi } -configure_live_image(){ - msg "Configuring [live-image]" - detect_desktop_env "$1" - configure_hosts "$1" - configure_lsb "$1" - configure_mhwd "$1" - configure_system "$1" - configure_services "$1" - configure_calamares "$1" - write_live_session_conf "$1" - msg "Done configuring [live-image]" -} - make_image_live() { if [[ ! -e ${work_dir}/build.${FUNCNAME} ]]; then msg "Prepare [Live installation] (live-image)" diff --git a/lib/util-yaml.sh b/lib/util-yaml.sh index 942395c..bad9221 100644 --- a/lib/util-yaml.sh +++ b/lib/util-yaml.sh @@ -141,7 +141,15 @@ write_displaymanager_conf(){ local conf="${modules_dir}/displaymanager.conf" msg2 "Writing %s ..." "${conf##*/}" echo "---" > "$conf" - if ${unpackfs}; then + if ${chrootcfg}; then + echo "displaymanagers:" >> "$conf" + echo " - lightdm" >> "$conf" + echo " - gdm" >> "$conf" + echo " - mdm" >> "$conf" + echo " - sddm" >> "$conf" + echo " - lxdm" >> "$conf" + echo " - slim" >> "$conf" + else echo "displaymanagers:" >> "$conf" echo " - ${displaymanager}" >> "$conf" echo '' >> "$conf" @@ -150,14 +158,6 @@ write_displaymanager_conf(){ echo " executable: \"${default_desktop_executable}\"" >> "$conf" echo " desktopFile: \"${default_desktop_file}\"" >> "$conf" fi - else - echo "displaymanagers:" >> "$conf" - echo " - lightdm" >> "$conf" - echo " - gdm" >> "$conf" - echo " - mdm" >> "$conf" - echo " - sddm" >> "$conf" - echo " - lxdm" >> "$conf" - echo " - slim" >> "$conf" fi echo '' >> "$conf" echo "basicSetup: false" >> "$conf" @@ -255,14 +255,10 @@ write_mhwdcfg_conf(){ echo "driver: free" >> "$conf" fi echo '' >> "$conf" - if ${netinstall};then - if ${unpackfs};then - echo "local: true" >> "$conf" - else + if ${chrootcfg};then echo "local: false" >> "$conf" - fi else - echo "local: true" >> "$conf" + echo "local: true" >> "$conf" fi echo '' >> "$conf" echo 'repo: /opt/pacman-mhwd.conf' >> "$conf" @@ -284,10 +280,10 @@ write_postcfg_conf(){ get_yaml(){ local args=() ext="yaml" yaml - if ${unpackfs};then - args+=("hybrid") - else + if ${chrootcfg};then args+=('netinstall') + else + args+=("hybrid") fi args+=("${initsys}") [[ ${edition} == 'sonar' ]] && args+=("${edition}") @@ -348,14 +344,13 @@ write_settings_conf(){ echo " - partition" >> "$conf" echo " - mount" >> "$conf" if ${netinstall};then - if ${unpackfs};then + if ${chrootcfg}; then + echo " - chrootcfg" >> "$conf" + echo " - networkcfg" >> "$conf" + else echo " - unpackfs" >> "$conf" echo " - networkcfg" >> "$conf" echo " - packages" >> "$conf" - else - echo " - chrootcfg" >> "$conf" - echo " - networkcfg" >> "$conf" - fi else echo " - unpackfs" >> "$conf" echo " - networkcfg" >> "$conf" @@ -407,7 +402,9 @@ configure_calamares(){ if ${netinstall};then write_netinstall_conf - write_packages_conf + if ! ${chrootcfg}; then + write_packages_conf + fi fi write_bootloader_conf diff --git a/lib/util.sh b/lib/util.sh index 2d47a5d..174dc5f 100644 --- a/lib/util.sh +++ b/lib/util.sh @@ -370,8 +370,8 @@ check_profile_vars(){ if ! is_valid_bool "${netinstall}";then die "netinstall only accepts true/false value!" fi - if ! is_valid_bool "${unpackfs}";then - die "unpackfs only accepts true/false value!" + if ! is_valid_bool "${chrootcfg}";then + die "chrootcfg only accepts true/false value!" fi if ! is_valid_bool "${geoip}";then die "geoip only accepts true/false value!" @@ -456,7 +456,7 @@ load_profile_config(){ [[ -z ${netinstall} ]] && netinstall='false' - [[ -z ${unpackfs} ]] && unpackfs='true' + [[ -z ${chrootcfg} ]] && chrootcfg='false' #[[ -z ${netgroups} ]] && -- needs to be hardcoded for now, until a standard has been established # will be unlocked again after everything has been established. @@ -503,7 +503,7 @@ reset_profile(){ unset tracker_url unset piece_size unset netinstall - unset unpackfs + unset chrootcfg unset netgroups unset geoip } @@ -547,8 +547,8 @@ check_profile(){ [[ -f "${profile_dir}/Packages-Mhwd" ]] && packages_mhwd=${profile_dir}/Packages-Mhwd - if ! ${netinstall} && ! ${unpackfs};then - unpackfs="true" + if ! ${netinstall}; then + chrootcfg="false" fi }