diff options
author | Mark Hatle <mark.hatle@windriver.com> | 2011-03-28 22:07:02 -0500 |
---|---|---|
committer | Saul Wold <sgw@linux.intel.com> | 2011-05-06 17:44:22 -0700 |
commit | 60ab27d71ba8e6bba49d1158d2668d6c739e2840 (patch) | |
tree | 375d03ead306a30e5a18cf8c34f4895b1a6fee49 /meta/recipes-extended/sat-solver/sat-solver/sat-solver_poky.patch | |
parent | d739fc53ebd49c9735f78b6036f54669ba825ea7 (diff) | |
download | poky-60ab27d71ba8e6bba49d1158d2668d6c739e2840.tar.gz |
Fix integration of zypper and sat-solver
Adjust the integration of zypper and sat-solver to ensure that all of the
defined architectures for a given machine are defined identically to Poky.
(From OE-Core rev: b2996efc015bc5ae0b8246924083e76fb5129cea)
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended/sat-solver/sat-solver/sat-solver_poky.patch')
-rw-r--r-- | meta/recipes-extended/sat-solver/sat-solver/sat-solver_poky.patch | 106 |
1 files changed, 106 insertions, 0 deletions
diff --git a/meta/recipes-extended/sat-solver/sat-solver/sat-solver_poky.patch b/meta/recipes-extended/sat-solver/sat-solver/sat-solver_poky.patch new file mode 100644 index 0000000000..b762bac854 --- /dev/null +++ b/meta/recipes-extended/sat-solver/sat-solver/sat-solver_poky.patch | |||
@@ -0,0 +1,106 @@ | |||
1 | Fix "arch" integration with Poky. | ||
2 | |||
3 | Add a missing "any" architecture type and update the semantics to use it. | ||
4 | |||
5 | Disable the built-in archpolicies structure, and replace it with one | ||
6 | we generate in the recipe. | ||
7 | |||
8 | Signed-off-by: Mark Hatle <mark.hatle@windriver.com> | ||
9 | |||
10 | diff --git a/src/knownid.h b/src/knownid.h | ||
11 | index 7757ae0..4b8bee7 100644 | ||
12 | --- a/src/knownid.h | ||
13 | +++ b/src/knownid.h | ||
14 | @@ -57,6 +57,7 @@ KNOWNID(SYSTEM_SYSTEM, "system:system"), | ||
15 | KNOWNID(ARCH_SRC, "src"), | ||
16 | KNOWNID(ARCH_NOSRC, "nosrc"), | ||
17 | KNOWNID(ARCH_NOARCH, "noarch"), | ||
18 | +KNOWNID(ARCH_ANY, "any"), | ||
19 | KNOWNID(ARCH_ALL, "all"), | ||
20 | |||
21 | KNOWNID(REPOSITORY_SOLVABLES, "repository:solvables"), | ||
22 | diff --git a/src/policy.c b/src/policy.c | ||
23 | index 55c8677..3356ff8 100644 | ||
24 | --- a/src/policy.c | ||
25 | +++ b/src/policy.c | ||
26 | @@ -486,6 +486,13 @@ policy_illegal_archchange(Solver *solv, Solvable *s1, Solvable *s2) | ||
27 | } | ||
28 | |||
29 | /* we allow changes to/from noarch */ | ||
30 | +#ifdef POKY_SEMANTICS | ||
31 | + if (a1 == a2 || | ||
32 | + a1 == ARCH_NOARCH || a2 == ARCH_NOARCH || | ||
33 | + a1 == ARCH_ANY || a2 == ARCH_ANY || | ||
34 | + a1 == ARCH_ALL || a2 == ARCH_ALL) | ||
35 | + return 0; | ||
36 | +#else | ||
37 | #ifndef DEBIAN_SEMANTICS | ||
38 | if (a1 == a2 || a1 == ARCH_NOARCH || a2 == ARCH_NOARCH) | ||
39 | return 0; | ||
40 | @@ -493,6 +500,7 @@ policy_illegal_archchange(Solver *solv, Solvable *s1, Solvable *s2) | ||
41 | if (a1 == a2 || a1 == ARCH_ALL || a2 == ARCH_ALL) | ||
42 | return 0; | ||
43 | #endif | ||
44 | +#endif | ||
45 | if (!pool->id2arch) | ||
46 | return 0; | ||
47 | a1 = a1 <= pool->lastarch ? pool->id2arch[a1] : 0; | ||
48 | diff --git a/src/poolarch.c b/src/poolarch.c | ||
49 | index 34a14a3..2d7cd70 100644 | ||
50 | --- a/src/poolarch.c | ||
51 | +++ b/src/poolarch.c | ||
52 | @@ -20,38 +20,8 @@ | ||
53 | #include "poolarch.h" | ||
54 | #include "util.h" | ||
55 | |||
56 | -const char *archpolicies[] = { | ||
57 | - "x86_64", "x86_64:i686:i586:i486:i386", | ||
58 | - "i686", "i686:i586:i486:i386", | ||
59 | - "i586", "i586:i486:i386", | ||
60 | - "i486", "i486:i386", | ||
61 | - "i386", "i386", | ||
62 | - "s390x", "s390x:s390", | ||
63 | - "s390", "s390", | ||
64 | - "ia64", "ia64:i686:i586:i486:i386", | ||
65 | - "ppc64", "ppc64:ppc", | ||
66 | - "ppc", "ppc", | ||
67 | - "armv7nhl", "armv7nhl:armv7hl", | ||
68 | - "armv7hl", "armv7hl", | ||
69 | - "armv7l", "armv7l:armv6l:armv5tejl:armv5tel:armv5l:armv4tl:armv4l:armv3l", | ||
70 | - "armv6l", "armv6l:armv5tejl:armv5tel:armv5l:armv4tl:armv4l:armv3l", | ||
71 | - "armv5tejl", "armv5tejl:armv5tel:armv5l:armv4tl:armv4l:armv3l", | ||
72 | - "armv5tel", "armv5tel:armv5l:armv4tl:armv4l:armv3l", | ||
73 | - "armv5l", "armv5l:armv4tl:armv4l:armv3l", | ||
74 | - "armv4tl", "armv4tl:armv4l:armv3l", | ||
75 | - "armv4l", "armv4l:armv3l", | ||
76 | - "armv3l", "armv3l", | ||
77 | - "sh3", "sh3", | ||
78 | - "sh4", "sh4", | ||
79 | - "sh4a", "sh4a:sh4", | ||
80 | - "sparc64v", "sparc64v:sparc64:sparcv9v:sparcv9:sparcv8:sparc", | ||
81 | - "sparc64", "sparc64:sparcv9:sparcv8:sparc", | ||
82 | - "sparcv9v", "sparcv9v:sparcv9:sparcv8:sparc", | ||
83 | - "sparcv9", "sparcv9:sparcv8:sparc", | ||
84 | - "sparcv8", "sparcv8:sparc", | ||
85 | - "sparc", "sparc", | ||
86 | - 0 | ||
87 | -}; | ||
88 | +/* Provide the const char *archpolicies structure */ | ||
89 | +#include "poky-arch.h" | ||
90 | |||
91 | void | ||
92 | pool_setarch(Pool *pool, const char *arch) | ||
93 | @@ -71,10 +41,10 @@ pool_setarch(Pool *pool, const char *arch) | ||
94 | pool->lastarch = 0; | ||
95 | return; | ||
96 | } | ||
97 | -#ifndef DEBIAN_SEMANTICS | ||
98 | - id = ARCH_NOARCH; | ||
99 | -#else | ||
100 | +#if defined(DEBIAN_SEMANTICS) || defined(POKY_SEMANTICS) | ||
101 | id = ARCH_ALL; | ||
102 | +#else | ||
103 | + id = ARCH_NOARCH; | ||
104 | #endif | ||
105 | lastarch = id + 255; | ||
106 | id2arch = sat_calloc(lastarch + 1, sizeof(Id)); | ||