On Thu, Sep 9, 2021 at 1:21 PM Robin H. Johnson <robb...@gentoo.org> wrote: > > On Wed, Sep 01, 2021 at 02:44:11PM -0400, Mike Pagano wrote: > > Previously, the kernel Makefile had to define version variables > > as static string literals to be read. > > This change will allow varibles defined as non-static values > > to be read. > Hi, > > This change has broken infra systems where /usr/src/ is empty because > they use a binary kernel. /proc/config.gz does exist on those systems for this > use case. > > Specifically, any package that uses linux-info to issues warnings via the '~' > syntax now fails because "getfilevar_noexec VERSION ..." returns empty string. > > * Determining the location of the kernel source code > * Unable to find kernel sources at /usr/src/linux > * Please make sure that /usr/src/linux points at your running kernel, > * (or the kernel you wish to build against). > * Alternatively, set the KERNEL_DIR environment variable to the kernel > sources location > * Unable to calculate Linux Kernel version for build, attempting to use > running version > * ERROR: app-emulation/docker-20.10.7::gentoo failed (setup phase): > * Unable to determine any Linux Kernel version, please report a bug > * > * Call stack: > * ebuild.sh, line 127: Called pkg_setup > * docker-20.10.7.ebuild, line 110: Called kernel_is 'lt' '4' '5' > * linux-info.eclass, line 405: Called linux-info_get_any_version > * linux-info.eclass, line 678: Called die > * The specific snippet of code: > * die "Unable to determine any Linux Kernel version, > please report a bug" > > I'd like to propose that we revert the original CVS change that supported the > fallback to getfilevar_noexec: > https://gitweb.gentoo.org/repo/gentoo/historical.git/commit/eclass/linux-info.eclass?id=ab160a941f5f52c95b47129d3243c693b05401e5
I cannot reproduce this with /proc/config.gz present. % sudo ebuild docker-20.10.8.ebuild clean setup * docker-20.10.8.tar.gz BLAKE2B SHA512 size ;-) ... [ ok ] * Determining the location of the kernel source code * Unable to find kernel sources at /usr/src/linux * Please make sure that /usr/src/linux points at your running kernel, * (or the kernel you wish to build against). * Alternatively, set the KERNEL_DIR environment variable to the kernel sources location * Unable to calculate Linux Kernel version for build, attempting to use running version * Checking for suitable kernel configuration options... * CONFIG_BRIDGE_NETFILTER: is not set when it should be. * CONFIG_IP_NF_TARGET_MASQUERADE: is not set when it should be. * CONFIG_NETFILTER_XT_MATCH_IPVS: is not set when it should be. * CONFIG_IP_VS: is not set when it should be. * CONFIG_IP_VS_PROTO_TCP: is not set when it should be. * CONFIG_IP_VS_PROTO_UDP: is not set when it should be. * CONFIG_IP_VS_NFCT: is not set when it should be. * CONFIG_IP_VS_RR: is not set when it should be. * CONFIG_OVERLAY_FS: is not set when it should be. * Please check to make sure these options are set correctly. * Failure to do so may cause unexpected problems.