From 745cdf990f58ae9c72d3941e3c5f548f871d6cf7 Mon Sep 17 00:00:00 2001 From: Alex Gonzalez Date: Tue, 12 Mar 2013 18:13:41 +0100 Subject: [PATCH] meta-digi-arm: Add tarball build for linux-del. On a release, the kernel will not be built from a git repo but from a source tarball. Make the default to build from a tarball. https://jira.digi.com/browse/DEL-362 Signed-off-by: Alex Gonzalez --- .../recipes-kernel/linux/linux-del.inc | 3 -- .../linux/linux-del_2.6.35.14.bb | 32 +++++++++++++------ 2 files changed, 23 insertions(+), 12 deletions(-) diff --git a/meta-digi-arm/recipes-kernel/linux/linux-del.inc b/meta-digi-arm/recipes-kernel/linux/linux-del.inc index 5d67bf9b6..a80d7cb40 100644 --- a/meta-digi-arm/recipes-kernel/linux/linux-del.inc +++ b/meta-digi-arm/recipes-kernel/linux/linux-del.inc @@ -12,9 +12,6 @@ inherit kernel # Put a local version until we have a true SRCREV to point to LOCALVERSION ?= "+del" -SCMVERSION ?= "y" - -S = "${WORKDIR}/git" kernel_conf_variable() { CONF_SED_SCRIPT="$CONF_SED_SCRIPT /CONFIG_$1[ =]/d;" diff --git a/meta-digi-arm/recipes-kernel/linux/linux-del_2.6.35.14.bb b/meta-digi-arm/recipes-kernel/linux/linux-del_2.6.35.14.bb index 395499202..75c86599f 100644 --- a/meta-digi-arm/recipes-kernel/linux/linux-del_2.6.35.14.bb +++ b/meta-digi-arm/recipes-kernel/linux/linux-del_2.6.35.14.bb @@ -4,11 +4,18 @@ include linux-del.inc PR = "${INC_PR}.0" -SRCREV = "${AUTOREV}" +# Uncomment to build the from sources (internal use only) +# KERNEL_BUILD_SRC ?= "1" -LOCALVERSION_mx5 = "mx5+master" -LOCALVERSION_mxs = "mxs+master" -LOCALVERSION_cpx2_mxs = "mxs+gateways_master" +SRCREV = "710c80d243367dea31c5236abab3ddae8e93f490" + +# Checksums for 'linux-2.6-${SRCREV_SHORT}.tar.gz' tarballs +TARBALL_MD5 = "dedd680314594ab62f3771a1590748c1" +TARBALL_SHA256 = "2e4c35e80bae560c81f6074fb407d07de799582638ae8848190ca502be833869" + +LOCALVERSION_mx5 = "mx5" +LOCALVERSION_mxs = "mxs" +LOCALVERSION_cpx2_mxs = "mxs+gateways" KERNEL_CFG_FRAGS ?= "" KERNEL_CFG_FRAGS_append_mx5 = " file://config-accel-module.cfg file://config-sahara-module.cfg file://config-camera-module.cfg" @@ -16,17 +23,24 @@ KERNEL_CFG_FRAGS_append_ccimx51js = " file://config-battery-module.cfg" KERNEL_CFG_FRAGS_append_ccardimx28js = " ${@base_contains('DISTRO_FEATURES', 'x11', 'file://config-fb.cfg file://config-touch.cfg', '', d)}" KERNEL_CFG_FRAGS_append_ccardimx28js = " ${@base_contains('MACHINE_FEATURES', 'alsa', 'file://config-sound.cfg', '', d)}" -SRC_URI = " \ +SRCREV_SHORT = "${@'${SRCREV}'[:7]}" +SRC_URI_tarball = " \ + ${DIGI_MIRROR}/linux-2.6-${SRCREV_SHORT}.tar.gz;md5sum=${TARBALL_MD5};sha256sum=${TARBALL_SHA256} \ + " + +SRC_URI_git = " \ ${DIGI_LOG_GIT}linux-2.6.git;protocol=git;branch=refs/heads/master \ - file://defconfig \ - ${KERNEL_CFG_FRAGS} \ " -SRC_URI_cpx2 = " \ - ${DIGI_LOG_GIT}linux-2.6.git;protocol=git;branch=refs/heads/gateways/master \ +SRC_URI = "${@base_conditional('KERNEL_BUILD_SRC', '1' , '${SRC_URI_git}', '${SRC_URI_tarball}', d)}" +SRC_URI += " \ file://defconfig \ + ${KERNEL_CFG_FRAGS} \ " +S = "${@base_conditional('KERNEL_BUILD_SRC', '1' , '${WORKDIR}/git', '${WORKDIR}/linux-2.6-${SRCREV_SHORT}', d)}" +SCMVERSION = "${@base_conditional('KERNEL_BUILD_SRC', '1' , '1', '0', d)}" + FILES_kernel-image += "/boot/config*" COMPATIBLE_MACHINE = "(mxs|mx5)"