summaryrefslogtreecommitdiffstats
path: root/meta-fsl-ppc
diff options
context:
space:
mode:
authorChunrong Guo <B40290@freescale.com>2014-03-27 13:41:02 +0800
committerZhenhua Luo <zhenhua.luo@freescale.com>2014-04-02 11:16:59 +0800
commit18eb1a43e33ec477ba7ec3a4a8f0bdb427206ed5 (patch)
tree685c1183985ca623d37dce37485f13a37cd939cf /meta-fsl-ppc
parent2aa3a1ccfa820c8dd3188567a1fbc04ccef21a15 (diff)
downloadmeta-freescale-18eb1a43e33ec477ba7ec3a4a8f0bdb427206ed5.tar.gz
linux-qoriq-sdk: add git revision to the local version
Signed-off-by: Chunrong Guo <B40290@freescale.com>
Diffstat (limited to 'meta-fsl-ppc')
-rw-r--r--meta-fsl-ppc/recipes-kernel/linux/linux-qoriq-sdk.bb14
1 files changed, 11 insertions, 3 deletions
diff --git a/meta-fsl-ppc/recipes-kernel/linux/linux-qoriq-sdk.bb b/meta-fsl-ppc/recipes-kernel/linux/linux-qoriq-sdk.bb
index 0ff68ced9..275691ab5 100644
--- a/meta-fsl-ppc/recipes-kernel/linux/linux-qoriq-sdk.bb
+++ b/meta-fsl-ppc/recipes-kernel/linux/linux-qoriq-sdk.bb
@@ -9,6 +9,8 @@ require recipes-kernel/linux/linux-qoriq-sdk.inc
9 9
10PR = "${INC_PR}.1" 10PR = "${INC_PR}.1"
11 11
12SCMVERSION ?= "y"
13
12DEPENDS_append = " libgcc" 14DEPENDS_append = " libgcc"
13KERNEL_CC_append = " ${TOOLCHAIN_OPTIONS}" 15KERNEL_CC_append = " ${TOOLCHAIN_OPTIONS}"
14KERNEL_LD_append = " ${TOOLCHAIN_OPTIONS}" 16KERNEL_LD_append = " ${TOOLCHAIN_OPTIONS}"
@@ -23,7 +25,13 @@ do_configure_prepend() {
23 fi 25 fi
24 26
25 # append sdk version in kernel version if SDK_VERSION is defined 27 # append sdk version in kernel version if SDK_VERSION is defined
26 if [ -n "${SDK_VERSION}" ]; then 28 if [ -n "${SDK_VERSION}" ]; then
27 echo "CONFIG_LOCALVERSION=\"-${SDK_VERSION}\"" >> ${S}/.config 29 echo "CONFIG_LOCALVERSION=\"-${SDK_VERSION}\"" >> ${S}/.config
28 fi 30 fi
31
32 # Add GIT revision to the local version
33 if [ "${SCMVERSION}" = "y" ]; then
34 head=`git rev-parse --verify --short HEAD 2> /dev/null`
35 printf "%s%s" +g $head > ${S}/.scmversion
36 fi
29} 37}