mirror of
https://gitlab.archlinux.org/tpowa/archboot.git
synced 2024-09-19 19:40:37 +02:00
replace use_container_config with use_binfmt
This commit is contained in:
parent
409b87c556
commit
4ab7e8c78d
5 changed files with 7 additions and 7 deletions
|
@ -27,7 +27,7 @@ if [[ "${_RUNNING_ARCH}" == "aarch64" ]]; then
|
|||
fi
|
||||
if [[ "${_RUNNING_ARCH}" == "x86_64" ]]; then
|
||||
_pacman_chroot "${1}" "${_ARCHBOOT_AARCH64_CHROOT_PUBLIC}" "${_PACMAN_AARCH64_CHROOT}" || exit 1
|
||||
_create_pacman_conf "${1}" "use_container_config"
|
||||
_create_pacman_conf "${1}" "use_binfmt"
|
||||
_pacman_parameters "${1}" "use_binfmt"
|
||||
_install_base_packages "${1}" "use_binfmt" || exit 1
|
||||
_install_archboot "${1}" "use_binfmt" || exit 1
|
||||
|
|
|
@ -20,7 +20,7 @@ if [[ "${_RUNNING_ARCH}" == "aarch64" ]]; then
|
|||
fi
|
||||
if [[ "${_RUNNING_ARCH}" == "x86_64" ]]; then
|
||||
_pacman_chroot "${_REPODIR}" "${_ARCHBOOT_AARCH64_CHROOT_PUBLIC}" "${_PACMAN_AARCH64_CHROOT}" || exit 1
|
||||
_create_pacman_conf "${_REPODIR}" "use_container_config"
|
||||
_create_pacman_conf "${_REPODIR}" "use_binfmt"
|
||||
_pacman_parameters "${_REPODIR}" "use_binfmt"
|
||||
_download_packages "${_REPODIR}" "use_binfmt" || exit 1
|
||||
fi
|
||||
|
|
|
@ -27,7 +27,7 @@ if [[ "${_RUNNING_ARCH}" == "riscv64" ]]; then
|
|||
fi
|
||||
if [[ "${_RUNNING_ARCH}" == "x86_64" ]]; then
|
||||
_pacman_chroot "${1}" "${_ARCHBOOT_RISCV64_CHROOT_PUBLIC}" "${_PACMAN_RISCV64_CHROOT}" || exit 1
|
||||
_create_pacman_conf "${1}" "use_container_config"
|
||||
_create_pacman_conf "${1}" "use_binfmt"
|
||||
_pacman_parameters "${1}" "use_binfmt"
|
||||
_install_base_packages "${1}" "use_binfmt" || exit 1
|
||||
_install_archboot "${1}" "use_binfmt" || exit 1
|
||||
|
|
|
@ -20,7 +20,7 @@ if [[ "${_RUNNING_ARCH}" == "riscv64" ]]; then
|
|||
fi
|
||||
if [[ "${_RUNNING_ARCH}" == "x86_64" ]]; then
|
||||
_pacman_chroot "${_REPODIR}" "${_ARCHBOOT_RISCV64_CHROOT_PUBLIC}" "${_PACMAN_RISCV64_CHROOT}" || exit 1
|
||||
_create_pacman_conf "${_REPODIR}" "use_container_config"
|
||||
_create_pacman_conf "${_REPODIR}" "use_binfmt"
|
||||
_pacman_parameters "${_REPODIR}" "use_binfmt"
|
||||
_download_packages "${_REPODIR}" "use_binfmt" || exit 1
|
||||
fi
|
||||
|
|
|
@ -105,13 +105,13 @@ _prepare_pacman() {
|
|||
_create_pacman_conf() {
|
||||
if [[ -z "${_INSTALL_SOURCE}" ]]; then
|
||||
echo "Use default pacman.conf ..."
|
||||
[[ "${2}" == "use_container_config" ]] && _PACMAN_CONF="${1}${_PACMAN_CONF}"
|
||||
[[ "${2}" == "use_binfmt" ]] && _PACMAN_CONF="${1}${_PACMAN_CONF}"
|
||||
if ! grep -qw "\[archboot\]" "${_PACMAN_CONF}"; then
|
||||
echo "Adding archboot repository to ${_PACMAN_CONF} ..."
|
||||
echo "[archboot]" >> "${_PACMAN_CONF}"
|
||||
echo "Server = https://pkgbuild.com/~tpowa/archboot/pkg" >> "${_PACMAN_CONF}"
|
||||
fi
|
||||
[[ "${2}" == "use_container_config" ]] && _PACMAN_CONF="$(echo ${_PACMAN_CONF} | sed -e "s#^${1}##g")"
|
||||
[[ "${2}" == "use_binfmt" ]] && _PACMAN_CONF="$(echo ${_PACMAN_CONF} | sed -e "s#^${1}##g")"
|
||||
else
|
||||
echo "Use custom pacman.conf ..."
|
||||
_PACMAN_CONF="$(mktemp "${1}"/pacman.conf.XXX)"
|
||||
|
@ -123,7 +123,7 @@ _create_pacman_conf() {
|
|||
echo "ParallelDownloads = 5" >> "${_PACMAN_CONF}"
|
||||
echo "[archboot]" >> "${_PACMAN_CONF}"
|
||||
echo "Server = ${_INSTALL_SOURCE}" >> "${_PACMAN_CONF}"
|
||||
[[ "${2}" == "use_container_config" ]] && _PACMAN_CONF="$(basename ${_PACMAN_CONF})"
|
||||
[[ "${2}" == "use_binfmt" ]] && _PACMAN_CONF="$(basename ${_PACMAN_CONF})"
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue