mirror of
https://github.com/armbian/build
synced 2025-09-24 19:47:06 +07:00
- completely remove support for building under `buster` -- that's way too old, sorry. - de-hardcode `python3` invocations, instead use `python3_binary_path` set by `prepare_python3_binary_for_python_tools()` - juggle `$HOSTRELEASE`: read from actual host, or determined from Docker image name (during Dockerfile build) - TL;DR: include and use `python3.9` for focal-like host OS's
22 lines
1.2 KiB
Bash
22 lines
1.2 KiB
Bash
function obtain_and_check_hostrelease() {
|
|
# obtain the host release either from os-release or debian_version
|
|
declare -g HOSTRELEASE
|
|
HOSTRELEASE="$(cat /etc/os-release | grep VERSION_CODENAME | cut -d"=" -f2)"
|
|
[[ -z $HOSTRELEASE ]] && HOSTRELEASE="$(cut -d'/' -f1 /etc/debian_version)"
|
|
display_alert "Build host OS release" "${HOSTRELEASE:-(unknown)}" "info"
|
|
|
|
# Ubuntu Jammy x86_64 or arm64 is the only fully supported host OS release
|
|
# Using Docker/VirtualBox is the only supported way to run the build script on other Linux distributions
|
|
#
|
|
# NO_HOST_RELEASE_CHECK overrides the check for a supported host system
|
|
# Disable host OS check at your own risk. Any issues reported with unsupported releases will be closed without discussion
|
|
if [[ -z $HOSTRELEASE || "bullseye bookworm sid focal impish hirsute jammy kinetic lunar ulyana ulyssa uma una vanessa vera" != *"$HOSTRELEASE"* ]]; then
|
|
if [[ $NO_HOST_RELEASE_CHECK == yes ]]; then
|
|
display_alert "You are running on an unsupported system" "${HOSTRELEASE:-(unknown)}" "wrn"
|
|
display_alert "Do not report any errors, warnings or other issues encountered beyond this point" "" "wrn"
|
|
else
|
|
exit_with_error "Unsupported build system: '${HOSTRELEASE:-(unknown)}'"
|
|
fi
|
|
fi
|
|
}
|