1 |
commit: c11d84573635b6c31966906e82f1ba4f380143ac |
2 |
Author: Joshua Kinard <kumba <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Aug 22 13:28:51 2016 +0000 |
4 |
Commit: Joshua Kinard <kumba <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Aug 22 13:33:20 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c11d8457 |
7 |
|
8 |
kernel-2.eclass: Add 'K_FROM_GIT' var to replace hardcoded reference to sys-kernel/git-sources. |
9 |
|
10 |
This is to work around a possible bug in patch when attempting to patch |
11 |
kernel trees checked out from git that remove a symlink and replace it |
12 |
with a file of the same name. See Bug #507656. |
13 |
|
14 |
Signed-off-by: Joshua Kinard <kumba <AT> gentoo.org> |
15 |
Acked-by: Mike Pagano <mpagano <AT> gentoo.org> |
16 |
|
17 |
eclass/kernel-2.eclass | 5 ++++- |
18 |
1 file changed, 4 insertions(+), 1 deletion(-) |
19 |
|
20 |
diff --git a/eclass/kernel-2.eclass b/eclass/kernel-2.eclass |
21 |
index 3ecd6c3..6b4e844 100644 |
22 |
--- a/eclass/kernel-2.eclass |
23 |
+++ b/eclass/kernel-2.eclass |
24 |
@@ -49,6 +49,9 @@ |
25 |
# as a result the user cannot choose to apply those patches. |
26 |
# K_EXP_GENPATCHES_LIST - A list of patches to pick from "experimental" to apply when |
27 |
# the USE flag is unset and K_EXP_GENPATCHES_PULL is set. |
28 |
+# K_FROM_GIT - If set, this variable signals that the kernel sources derives from a git tree and special |
29 |
+# handling will be applied so that any patches that are applied will actually apply. |
30 |
+# |
31 |
# K_GENPATCHES_VER - The version of the genpatches tarball(s) to apply. |
32 |
# A value of "5" would apply genpatches-2.6.12-5 to |
33 |
# my-sources-2.6.12.ebuild |
34 |
@@ -1090,7 +1093,7 @@ unipatch() { |
35 |
# # |
36 |
# https://bugs.gentoo.org/show_bug.cgi?id=507656 # |
37 |
#################################################################### |
38 |
- if [[ ${PN} == "git-sources" ]] ; then |
39 |
+ if [[ -n ${K_FROM_GIT} ]] ; then |
40 |
if [[ ${KV_MAJOR} -gt 3 || ( ${KV_MAJOR} -eq 3 && ${KV_PATCH} -gt 15 ) && |
41 |
${RELEASETYPE} == -rc ]] ; then |
42 |
ebegin "Applying ${i/*\//} (-p1)" |