]> code.ossystems Code Review - openembedded-core.git/commitdiff
kernel.bbclass: Allow modules*.tar.gz generation to be inhibited
authorPhil Blundell <philb@gnu.org>
Sun, 23 Sep 2012 21:45:10 +0000 (21:45 +0000)
committerSaul Wold <sgw@linux.intel.com>
Wed, 19 Dec 2012 07:48:20 +0000 (23:48 -0800)
The modules.tar.gz archive is sometimes of no value and it can take
a noticeable time to build if many modules were enabled in the kernel
configuration.  The extraneous file also contributes to deploy/ clutter
and is a waste of disk space.

Allow it to be suppressed by setting MODULE_TARBALL_DEPLOY="0".

Signed-off-by: Phil Blundell <pb@pbcl.net>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
meta/classes/kernel.bbclass

index c5e054d3ce5aa83cfaa032f87d9b3d72c1fe19f7..aee8a77a9e22dfbdffca5cf9325271058086b4fd 100644 (file)
@@ -501,6 +501,7 @@ MODULE_TARBALL_BASE_NAME ?= "modules-${PE}-${PV}-${PR}-${MACHINE}-${DATETIME}.tg
 # Don't include the DATETIME variable in the sstate package signatures
 MODULE_TARBALL_BASE_NAME[vardepsexclude] = "DATETIME"
 MODULE_TARBALL_SYMLINK_NAME ?= "modules-${MACHINE}.tgz"
+MODULE_TARBALL_DEPLOY ?= "1"
 
 do_uboot_mkimage() {
        if test "x${KERNEL_IMAGETYPE}" = "xuImage" ; then 
@@ -529,7 +530,7 @@ addtask uboot_mkimage before do_install after do_compile
 
 kernel_do_deploy() {
        install -m 0644 ${KERNEL_OUTPUT} ${DEPLOYDIR}/${KERNEL_IMAGE_BASE_NAME}.bin
-       if (grep -q -i -e '^CONFIG_MODULES=y$' .config); then
+       if [ ${MODULE_TARBALL_DEPLOY} = "1" ] && (grep -q -i -e '^CONFIG_MODULES=y$' .config); then
                tar -cvzf ${DEPLOYDIR}/${MODULE_TARBALL_BASE_NAME} -C ${D} lib
                ln -sf ${MODULE_TARBALL_BASE_NAME}.bin ${MODULE_TARBALL_SYMLINK_NAME}
        fi