sysext: Change the sysext seperator from : to |

To be able to use the SLOT syntax, which uses : we need to change the
sysext seperator to |.
This commit is contained in:
Daniel Zatovic 2025-04-01 11:57:06 +02:00
parent 5f54ecfd9e
commit 820bc74c3b
7 changed files with 21 additions and 21 deletions

View File

@ -33,7 +33,7 @@ DEFINE_string base_pkg "coreos-base/coreos" \
"The base portage package to base the build off of (only applies to prod images)"
DEFINE_string base_dev_pkg "coreos-base/coreos-dev" \
"The base portage package to base the build off of (only applies to dev containers)"
DEFINE_string base_sysexts "containerd-flatcar:app-containers/containerd,docker-flatcar:app-containers/docker&app-containers/docker-cli&app-containers/docker-buildx" \
DEFINE_string base_sysexts "containerd-flatcar|app-containers/containerd,docker-flatcar|app-containers/docker&app-containers/docker-cli&app-containers/docker-buildx" \
"Comma-separated list of name:package[&package[&package]] - build 'package' (a single package or a list of packages separated by '&') into sysext 'name', and include with OS image and update payload. Must be in order of dependencies, base sysexts come first."
DEFINE_string output_root "${DEFAULT_BUILD_ROOT}/images" \
"Directory in which to place image result directories (named by version)"

View File

@ -1,16 +1,16 @@
EXTRA_SYSEXTS=(
zfs:sys-fs/zfs
podman:app-containers/podman,net-misc/passt
python:dev-lang/python,dev-python/pip
nvidia-drivers-535:=x11-drivers/nvidia-drivers-535.230.02:-kernel-open
nvidia-drivers-535-open:=x11-drivers/nvidia-drivers-535.230.02:kernel-open
nvidia-drivers-550:=x11-drivers/nvidia-drivers-550.144.03:-kernel-open
nvidia-drivers-550-open:=x11-drivers/nvidia-drivers-550.144.03:kernel-open
"zfs|sys-fs/zfs"
"podman|app-containers/podman,net-misc/passt"
"python|dev-lang/python,dev-python/pip"
"nvidia-drivers-535|=x11-drivers/nvidia-drivers-535.230.02|-kernel-open"
"nvidia-drivers-535-open|=x11-drivers/nvidia-drivers-535.230.02|kernel-open"
"nvidia-drivers-550|=x11-drivers/nvidia-drivers-550.144.03|-kernel-open"
"nvidia-drivers-550-open|=x11-drivers/nvidia-drivers-550.144.03|kernel-open"
)
_get_unversioned_sysext_packages_unsorted() {
for sysext in "${EXTRA_SYSEXTS[@]}"; do
IFS=":" read -r _ PACKAGE_ATOMS _ <<< "$sysext"
IFS="|" read -r _ PACKAGE_ATOMS _ <<< "$sysext"
IFS=,
for atom in $PACKAGE_ATOMS; do

View File

@ -213,13 +213,13 @@ create_prod_sysexts() {
local image_name="$1"
local image_sysext_base="${image_name%.bin}_sysext.squashfs"
for sysext in "${EXTRA_SYSEXTS[@]}"; do
local name="flatcar-${sysext%%:*}"
local pkgs_and_useflags="${sysext#*:}"
local pkgs="${pkgs_and_useflags%%:*}"
local name="flatcar-${sysext%%|*}"
local pkgs_and_useflags="${sysext#*|}"
local pkgs="${pkgs_and_useflags%%|*}"
local pkg_array=(${pkgs//,/ })
local useflags=""
if [[ "$pkgs_and_useflags" == *:* ]]; then
useflags="${pkgs_and_useflags#*:}"
if [[ "$pkgs_and_useflags" == *\|* ]]; then
useflags="${pkgs_and_useflags#*|}"
fi
local useflags_array=(${useflags//,/ })

View File

@ -113,8 +113,8 @@ prev_pkginfo=""
sysext_lowerdirs="${sysext_mountdir}/rootfs-lower"
for sysext in ${sysexts_list//,/ }; do
# format is "<name>:<group>/<package>"
name="${sysext%:*}"
grp_pkg="${sysext#*:}"
name="${sysext%|*}"
grp_pkg="${sysext#*|}"
create_prod_sysext "${BOARD}" \
"${sysext_output_dir}" \
"${sysext_workdir}" \

View File

@ -288,7 +288,7 @@ sudo -E "${EMERGE_CMD[@]}" "${EMERGE_FLAGS[@]}" "$@"
info "Merging sysext packages now"
for sysext in "${EXTRA_SYSEXTS[@]}"; do
IFS=":" read SYSEXT_NAME PACKAGE_ATOMS USEFLAGS < <(echo "$sysext");
IFS="|" read SYSEXT_NAME PACKAGE_ATOMS USEFLAGS < <(echo "$sysext");
info "Building packages for $SYSEXT_NAME sysext with USE=$USEFLAGS"
IFS=,

View File

@ -6,6 +6,6 @@ if [[ ${1:-} = 'local' ]]; then
fi
ciabs_base_sysexts=(
'containerd-flatcar:app-containers/containerd'
'docker-flatcar:app-containers/docker&app-containers/docker-cli&app-containers/docker-buildx'
'containerd-flatcar|app-containers/containerd'
'docker-flatcar|app-containers/docker&app-containers/docker-cli&app-containers/docker-buildx'
)

View File

@ -280,7 +280,7 @@ function get_base_sysext_list() {
source "${scripts_repo}/ci-automation/base_sysexts.sh" 'local'
list_var_ref=( "${ciabs_base_sysexts[@]%%:*}" )
list_var_ref=( "${ciabs_base_sysexts[@]%%|*}" )
}
function get_extra_sysext_list() {
@ -291,7 +291,7 @@ function get_extra_sysext_list() {
local -a EXTRA_SYSEXTS
source "${scripts_repo}/build_library/extra_sysexts.sh"
list_var_ref=( "${EXTRA_SYSEXTS[@]%%:*}" )
list_var_ref=( "${EXTRA_SYSEXTS[@]%%|*}" )
}
# Generates reports with passed parameters. The report is redirected