mirror of
https://github.com/flatcar/scripts.git
synced 2025-09-25 15:41:04 +02:00
eclass/linux-info: Sync with Gentoo
It's from Gentoo commit f51cd5b64c14ddfb83488a12d538c66a4a309376.
This commit is contained in:
parent
c1fa5a93c3
commit
6bed045983
@ -1,4 +1,4 @@
|
|||||||
# Copyright 1999-2023 Gentoo Authors
|
# Copyright 1999-2024 Gentoo Authors
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
# @ECLASS: linux-info.eclass
|
# @ECLASS: linux-info.eclass
|
||||||
@ -696,11 +696,17 @@ linux-info_get_any_version() {
|
|||||||
die "${FUNCNAME}() called on non-Linux system, please fix the ebuild"
|
die "${FUNCNAME}() called on non-Linux system, please fix the ebuild"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! get_version; then
|
if [[ ${MERGE_TYPE} == binary && -z ${LINUX_INFO_BINARY_RESET} ]]; then
|
||||||
ewarn "Unable to calculate Linux Kernel version for build, attempting to use running version"
|
unset KV_FULL _LINUX_CONFIG_EXISTS_DONE KV_OUT_DIR
|
||||||
if ! get_running_version; then
|
LINUX_INFO_BINARY_RESET=1
|
||||||
die "Unable to determine any Linux Kernel version, please report a bug"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ ${MERGE_TYPE} != binary ]] && ! get_version; then
|
||||||
|
ewarn "Unable to calculate Linux Kernel version for build, attempting to use running version"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ -z ${KV_FULL} ]] && ! get_running_version; then
|
||||||
|
die "Unable to determine any Linux Kernel version, please report a bug"
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user