summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorAlexandre Belloni <alexandre.belloni@free-electrons.com>2014-02-07 17:30:32 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-02-11 11:56:56 +0000
commit2bdc00fe74cc3f2b7daf43c9109e0727764b0a38 (patch)
tree86f982f70dec2ab98c0de6e54ea80f80cd9b8118 /meta
parentb6bfcaa312f4d271692b78d3b615d34d7d66da7f (diff)
downloadpoky-2bdc00fe74cc3f2b7daf43c9109e0727764b0a38.tar.gz
kernel: use oldnoconfig before yes '' | make oldconfig
When using a defconfig, using yes '' | make oldconfig may not result in the correct configuration being set. For example: $ ARCH=mips make qi_lb60_defconfig # # configuration written to .config # $ grep USB_ETH .config CONFIG_USB_ETH=y # CONFIG_USB_ETH_RNDIS is not set # CONFIG_USB_ETH_EEM is not set $ cp arch/mips/configs/qi_lb60_defconfig .config $ yes '' | make ARCH=mips oldconfig [...] $ grep USB_ETH .config CONFIG_USB_ETH=m # CONFIG_USB_ETH_RNDIS is not set # CONFIG_USB_ETH_EEM is not set Using make olddefconfig solves that but we'll use the oldnoconfig alias for backward compatibility with older kernels. $ cp arch/mips/configs/qi_lb60_defconfig .config $ make ARCH=mips oldnoconfig scripts/kconfig/conf --olddefconfig Kconfig # # configuration written to .config # $ grep USB_ETH .config CONFIG_USB_ETH=y # CONFIG_USB_ETH_RNDIS is not set # CONFIG_USB_ETH_EEM is not set (From OE-Core rev: 9b75f6a5786ff7b2e6219d78b38f0032f100c660) Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/kernel.bbclass4
1 files changed, 3 insertions, 1 deletions
diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index db5d479000..3003fb1624 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -313,6 +313,8 @@ python sysroot_stage_all () {
313 oe.path.copyhardlinktree(d.expand("${D}${KERNEL_SRC_PATH}"), d.expand("${SYSROOT_DESTDIR}${KERNEL_SRC_PATH}")) 313 oe.path.copyhardlinktree(d.expand("${D}${KERNEL_SRC_PATH}"), d.expand("${SYSROOT_DESTDIR}${KERNEL_SRC_PATH}"))
314} 314}
315 315
316KERNEL_CONFIG_COMMAND ?= "oe_runmake oldnoconfig || yes '' | oe_runmake oldconfig"
317
316kernel_do_configure() { 318kernel_do_configure() {
317 # fixes extra + in /lib/modules/2.6.37+ 319 # fixes extra + in /lib/modules/2.6.37+
318 # $ scripts/setlocalversion . => + 320 # $ scripts/setlocalversion . => +
@@ -325,7 +327,7 @@ kernel_do_configure() {
325 if [ -f "${WORKDIR}/defconfig" ] && [ ! -f "${B}/.config" ]; then 327 if [ -f "${WORKDIR}/defconfig" ] && [ ! -f "${B}/.config" ]; then
326 cp "${WORKDIR}/defconfig" "${B}/.config" 328 cp "${WORKDIR}/defconfig" "${B}/.config"
327 fi 329 fi
328 yes '' | oe_runmake oldconfig 330 eval ${KERNEL_CONFIG_COMMAND}
329} 331}
330 332
331do_savedefconfig() { 333do_savedefconfig() {