diff options
Diffstat (limited to 'meta/recipes-extended/sat-solver/sat-solver_git.bb')
-rw-r--r-- | meta/recipes-extended/sat-solver/sat-solver_git.bb | 28 |
1 files changed, 26 insertions, 2 deletions
diff --git a/meta/recipes-extended/sat-solver/sat-solver_git.bb b/meta/recipes-extended/sat-solver/sat-solver_git.bb index 02b6c75507..54420cd154 100644 --- a/meta/recipes-extended/sat-solver/sat-solver_git.bb +++ b/meta/recipes-extended/sat-solver/sat-solver_git.bb | |||
@@ -7,14 +7,38 @@ 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 = "r3" | 10 | PR = "r4" |
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://db5.patch" | 15 | file://db5.patch \ |
16 | file://builtin-arch.patch;apply=no \ | ||
17 | file://no-builtin-arch.patch;apply=no \ | ||
18 | " | ||
16 | 19 | ||
17 | S = "${WORKDIR}/git" | 20 | S = "${WORKDIR}/git" |
18 | 21 | ||
19 | EXTRA_OECMAKE += "-DLIB=lib" | 22 | EXTRA_OECMAKE += "-DLIB=lib" |
23 | |||
20 | inherit cmake pkgconfig | 24 | inherit cmake pkgconfig |
25 | |||
26 | PACKAGE_ARCH = "${MACHINE_ARCH}" | ||
27 | |||
28 | do_archpatch () { | ||
29 | PKG_ARCH_TAIL=`sed -n ${S}/src/poolarch.c -e "s|^ \"\(${BASE_PACKAGE_ARCH}\)\",.*\"\(.*\)\",.*$|\2|p"` | ||
30 | if [ "x${PKG_ARCH_TAIL}" == x ]; then | ||
31 | PATCHFILE=${WORKDIR}/no-builtin-arch.patch | ||
32 | else | ||
33 | PATCHFILE=${WORKDIR}/builtin-arch.patch | ||
34 | fi | ||
35 | |||
36 | sed -i "${PATCHFILE}" \ | ||
37 | -e "s|@MACHINE_ARCH@|${MACHINE_ARCH}|g" \ | ||
38 | -e "s|@PKG_ARCH@|${BASE_PACKAGE_ARCH}|g" \ | ||
39 | -e "s|@PKG_ARCH_TAIL@|${PKG_ARCH_TAIL}|g" | ||
40 | |||
41 | patch -p1 -i "${PATCHFILE}" | ||
42 | } | ||
43 | |||
44 | addtask archpatch before do_patch after do_unpack | ||