summaryrefslogtreecommitdiffstats
path: root/recipes-kernel/linux/files/setlocalversion.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-kernel/linux/files/setlocalversion.patch')
-rw-r--r--recipes-kernel/linux/files/setlocalversion.patch63
1 files changed, 63 insertions, 0 deletions
diff --git a/recipes-kernel/linux/files/setlocalversion.patch b/recipes-kernel/linux/files/setlocalversion.patch
new file mode 100644
index 0000000..f0925de
--- /dev/null
+++ b/recipes-kernel/linux/files/setlocalversion.patch
@@ -0,0 +1,63 @@
1diff -uNr a/Makefile b/Makefile
2--- a/Makefile 2012-05-11 10:45:09.669169201 +0200
3+++ b/Makefile 2012-05-11 10:44:57.285708701 +0200
4@@ -949,6 +949,7 @@
5 # Store (new) KERNELRELASE string in include/config/kernel.release
6 include/config/kernel.release: include/config/auto.conf FORCE
7 $(Q)rm -f $@
8+ $(Q)rm -f .scmversion
9 $(Q)echo "$(KERNELVERSION)$$($(CONFIG_SHELL) $(srctree)/scripts/setlocalversion $(srctree))" > $@
10
11
12@@ -1463,6 +1464,7 @@
13 $(PERL) $(src)/scripts/checkstack.pl $(CHECKSTACK_ARCH)
14
15 kernelrelease:
16+ $(Q)rm -f .scmversion
17 @echo "$(KERNELVERSION)$$($(CONFIG_SHELL) $(srctree)/scripts/setlocalversion $(srctree))"
18
19 kernelversion:
20diff -uNr a/scripts/setlocalversion b/scripts/setlocalversion
21--- a/scripts/setlocalversion 2012-05-11 10:40:11.926141561 +0200
22+++ b/scripts/setlocalversion 2012-05-11 10:43:04.818608594 +0200
23@@ -49,12 +49,6 @@
24 # it, because this version is defined in the top level Makefile.
25 if [ -z "`git describe --exact-match 2>/dev/null`" ]; then
26
27- # If only the short version is requested, don't bother
28- # running further git commands
29- if $short; then
30- echo "+"
31- return
32- fi
33 # If we are past a tagged commit (like
34 # "v2.6.30-rc5-302-g72357d5"), we pretty print it.
35 if atag="`git describe 2>/dev/null`"; then
36@@ -98,11 +92,6 @@
37 fi
38 fi
39
40- # Are there uncommitted changes?
41- # These are represented by + after the changeset id.
42- case "$hgid" in
43- *+|*+\ *) printf '%s' -dirty ;;
44- esac
45
46 # All done with mercurial
47 return
48@@ -163,15 +152,6 @@
49 if test "$CONFIG_LOCALVERSION_AUTO" = "y"; then
50 # full scm version string
51 res="$res$(scm_version)"
52-else
53- # append a plus sign if the repository is not in a clean
54- # annotated or signed tagged state (as git describe only
55- # looks at signed or annotated tags - git tag -a/-s) and
56- # LOCALVERSION= is not specified
57- if test "${LOCALVERSION+set}" != "set"; then
58- scm=$(scm_version --short)
59- res="$res${scm:++}"
60- fi
61 fi
62
63 echo "$res"