diff options
author | Mark Hatle <mark.hatle@windriver.com> | 2011-03-16 10:28:08 -0500 |
---|---|---|
committer | Saul Wold <sgw@linux.intel.com> | 2011-03-16 17:46:47 -0700 |
commit | 0473eb2c2256f189d535cb5edc2724012ea1a407 (patch) | |
tree | fdba649f6326a86cd0f7c6b1eaf91b320902e896 /meta/recipes-extended | |
parent | d9d74a549dc7620f925109bb5ec13c9c823d6ac9 (diff) | |
download | poky-0473eb2c2256f189d535cb5edc2724012ea1a407.tar.gz |
sat-solver: Add workaround for RPM 5 db construction
The first time the database is created on an RPM5 system it works
correctly. However any subsequent rebuilds cause an empty database to
occur.
The following is from Michael Schroeder <mls@suse.de>:
> rpmdb2solv contains a hack that makes it use the unchanged already
> converted packages. To do this, it needs to get the database id
> for every installed packages by reading the "Name" index. This
> somehow doesn't seem to work with rpm5.
>
> As a workaround you can add a "ref = 0;" line at the top of the
> repo_add_rpmdb() function in ext/repo_rpmdb.c.
(From OE-Core rev: 3db47b9c2a40db8e94c30dca601b0ab82920c14f)
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended')
-rw-r--r-- | meta/recipes-extended/sat-solver/sat-solver/rpm5-solvdb.patch | 30 | ||||
-rw-r--r-- | meta/recipes-extended/sat-solver/sat-solver_git.bb | 3 |
2 files changed, 32 insertions, 1 deletions
diff --git a/meta/recipes-extended/sat-solver/sat-solver/rpm5-solvdb.patch b/meta/recipes-extended/sat-solver/sat-solver/rpm5-solvdb.patch new file mode 100644 index 0000000000..8ce1b150c5 --- /dev/null +++ b/meta/recipes-extended/sat-solver/sat-solver/rpm5-solvdb.patch | |||
@@ -0,0 +1,30 @@ | |||
1 | sat-solver rpmdb based solv database construction | ||
2 | |||
3 | The first time the database is created on an RPM5 system it works | ||
4 | correctly. However any subsequent rebuilds cause an empty database to | ||
5 | occur. | ||
6 | |||
7 | The following is from Michael Schroeder <mls@suse.de>: | ||
8 | > rpmdb2solv contains a hack that makes it use the unchanged already | ||
9 | > converted packages. To do this, it needs to get the database id | ||
10 | > for every installed packages by reading the "Name" index. This | ||
11 | > somehow doesn't seem to work with rpm5. | ||
12 | > | ||
13 | > As a workaround you can add a "ref = 0;" line at the top of the | ||
14 | > repo_add_rpmdb() function in ext/repo_rpmdb.c. | ||
15 | |||
16 | Signed-off-by: Mark Hatle <mark.hatle@windriver.com> | ||
17 | |||
18 | diff -ur git.orig/ext/repo_rpmdb.c git/ext/repo_rpmdb.c | ||
19 | --- git.orig/ext/repo_rpmdb.c 2011-03-16 09:43:50.470008215 -0500 | ||
20 | +++ git/ext/repo_rpmdb.c 2011-03-16 09:47:55.503989694 -0500 | ||
21 | @@ -1344,6 +1344,9 @@ | ||
22 | memset(&dbkey, 0, sizeof(dbkey)); | ||
23 | memset(&dbdata, 0, sizeof(dbdata)); | ||
24 | |||
25 | + /* Workaround for RPM 5 database construction */ | ||
26 | + ref = 0; | ||
27 | + | ||
28 | if (!rootdir) | ||
29 | rootdir = ""; | ||
30 | |||
diff --git a/meta/recipes-extended/sat-solver/sat-solver_git.bb b/meta/recipes-extended/sat-solver/sat-solver_git.bb index 54420cd154..a6519d5921 100644 --- a/meta/recipes-extended/sat-solver/sat-solver_git.bb +++ b/meta/recipes-extended/sat-solver/sat-solver_git.bb | |||
@@ -7,11 +7,12 @@ LIC_FILES_CHKSUM = "file://LICENSE.BSD;md5=62272bd11c97396d4aaf1c41bc11f7d8" | |||
7 | DEPENDS = "libcheck rpm zlib expat db" | 7 | DEPENDS = "libcheck rpm zlib expat db" |
8 | 8 | ||
9 | PV = "0.0-git${SRCPV}" | 9 | PV = "0.0-git${SRCPV}" |
10 | PR = "r4" | 10 | PR = "r5" |
11 | 11 | ||
12 | SRC_URI = "git://gitorious.org/opensuse/sat-solver.git;protocol=git \ | 12 | SRC_URI = "git://gitorious.org/opensuse/sat-solver.git;protocol=git \ |
13 | file://cmake.patch \ | 13 | file://cmake.patch \ |
14 | file://rpm5.patch \ | 14 | file://rpm5.patch \ |
15 | file://rpm5-solvdb.patch \ | ||
15 | file://db5.patch \ | 16 | file://db5.patch \ |
16 | file://builtin-arch.patch;apply=no \ | 17 | file://builtin-arch.patch;apply=no \ |
17 | file://no-builtin-arch.patch;apply=no \ | 18 | file://no-builtin-arch.patch;apply=no \ |