meta/classes/kernel.bbclass: revert 56fe5300ab5
PATCH 1/1 meta/classes/kernel.bbclass: revert 56fe5300ab5
This commit effectively reverts 56fe5300ab5 (except doing a revert at this point is not clean).
The Linux kernel contains a configuration option called CONFIG_LOCALVERSION which, if enabled, will change the boot log and "uname -a" from, for example, "4.10.2-yocto-standard" to "4.10.2-yocto-standard-00368-g827a1164b155".
According to the log message for 56fe5300ab5, the Linux kernel's scripts/setlocalversion script was leaving or appending a '+' to the end of directory names (e.g. /lib/modules/2.6.37+). This conversation can be seen at:
http://lists.openembedded.org/pipermail/openembedded-core/2011-December/053263.html
The solution was to touch an empty .scmversion file, which causes the kernel's CONFIG_LOCAVERSION logic to be entirely circumvented. This seems like a very big hammer to use in order to fix a trailing '+'. If users were enabling this kernel option, it wasn't having any effect. Also, by default, CONFIG_LOCALVERSION is disabled in linux-yocto kernels.
Commit 56fe5300ab5 was many years ago, and my current testing with CONFIG_LOCALVERSION enabled and 56fe5300ab5 reverted doesn't appear to cause trailing '+' characters to be appended to filenames in /lib/modules anymore. It appears as though the problem has been fixed somewhere else along the way. In which case, enable this functionality so setting this kernel option gives users the expected result.
--- meta/classes/kernel.bbclass | 6 ------ 1 file changed, 6 deletions(-)
meta/classes/kernel.bbclass +0 -6
@@ -451,12 +451,6 @@ check_oldest_kernel[vardepsexclude] += "OLDEST_KERNEL KERNEL_VERSION" do_configure[prefuncs] += "check_oldest_kernel" kernel_do_configure() { - # fixes extra + in /lib/modules/2.6.37+ - # $ scripts/setlocalversion . => + - # $ make kernelversion => 2.6.37 - # $ make kernelrelease => 2.6.37+ - touch ${B}/.scmversion ${S}/.scmversion - if [ "${S}" != "${B}" ] && [ -f "${S}/.config" ] && [ ! -f "${B}/.config" ]; then mv "${S}/.config" "${B}/.config" fi
Signature · 1 line
2.12.0.rc1.48.g076c053
Oops, kernel config option is wrong in description. v2 in 3, 2, 1...
Quoted 51 lines · Trevor Woerner
This commit effectively reverts
56fe5300ab5(except doing a revert at this point is not clean).The Linux kernel contains a configuration option called
CONFIG_LOCALVERSIONwhich, if enabled, will change the boot log and "uname -a" from, for example, "4.10.2-yocto-standard" to "4.10.2-yocto-standard-00368-g827a1164b155".According to the log message for
56fe5300ab5, the Linux kernel'sscripts/setlocalversionscript was leaving or appending a '+' to the end of directory names (e.g./lib/modules/2.6.37+). This conversation can be seen at:http://lists.openembedded.org/pipermail/openembedded-core/2011-December/053263.htmlThe solution was to touch an empty .scmversion file, which causes the kernel's
CONFIG_LOCAVERSIONlogic to be entirely circumvented. This seems like a very big hammer to use in order to fix a trailing '+'. If users were enabling this kernel option, it wasn't having any effect. Also, by default,CONFIG_LOCALVERSIONis disabled in linux-yocto kernels.Commit
56fe5300ab5was many years ago, and my current testing withCONFIG_LOCALVERSIONenabled and56fe5300ab5reverted doesn't appear to cause trailing '+' characters to be appended to filenames in/lib/modulesanymore. It appears as though the problem has been fixed somewhere else along the way. In which case, enable this functionality so setting this kernel option gives users the expected result.Signed-off-by Trevor Woerner <[email protected]>--- meta/classes/kernel.bbclass | 6 ------ 1 file changed, 6 deletions(-)meta/classes/kernel.bbclass +0
-7@@ -451,12 +451,6 @@ check_oldest_kernel[vardepsexclude] += "OLDEST_KERNEL KERNEL_VERSION" do_configure[prefuncs] += "check_oldest_kernel" kernel_do_configure() { - # fixes extra + in /lib/modules/2.6.37+ - # $ scripts/setlocalversion . => + - # $ make kernelversion => 2.6.37 - # $ make kernelrelease => 2.6.37+ - touch ${B}/.scmversion ${S}/.scmversion - if [ "${S}" != "${B}" ] && [ -f "${S}/.config" ] && [ ! -f "${B}/.config" ]; then mv "${S}/.config" "${B}/.config" fi --2.12.0.rc1.48.g076c053