diff options
Diffstat (limited to 'meta/recipes-core/musl/gcompat_git.bb')
-rw-r--r-- | meta/recipes-core/musl/gcompat_git.bb | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/meta/recipes-core/musl/gcompat_git.bb b/meta/recipes-core/musl/gcompat_git.bb new file mode 100644 index 0000000000..40fe8c6a5f --- /dev/null +++ b/meta/recipes-core/musl/gcompat_git.bb | |||
@@ -0,0 +1,60 @@ | |||
1 | # Copyright (C) 2021 Khem Raj <raj.khem@gmail.com> | ||
2 | # Released under the MIT license (see COPYING.MIT for the terms) | ||
3 | |||
4 | SUMMARY = "A library which provides glibc-compatible APIs for use on musl libc systems" | ||
5 | HOMEPAGE = "https://git.adelielinux.org/adelie/gcompat" | ||
6 | |||
7 | LICENSE = "NCSA" | ||
8 | LIC_FILES_CHKSUM = "file://LICENSE;md5=802b1aed7330d90086be4de63a3188e3" | ||
9 | |||
10 | SRC_URI = "git://git.adelielinux.org/adelie/gcompat.git;protocol=https;branch=current \ | ||
11 | file://0001-Add-fcntl64-wrapper.patch \ | ||
12 | " | ||
13 | SRC_URI:append:powerpc = "\ | ||
14 | file://0001-make-Static-PIE-does-not-work-on-musl-ppc.patch \ | ||
15 | " | ||
16 | PV = "1.1.0" | ||
17 | SRCREV = "b7bfe0b08c52fdc72e0c1d9d4dcb2129f1642bd6" | ||
18 | |||
19 | S = "${WORKDIR}/git" | ||
20 | |||
21 | inherit pkgconfig linuxloader siteinfo | ||
22 | |||
23 | DEPENDS += "musl-obstack" | ||
24 | |||
25 | GLIBC_LDSO = "${@get_glibc_loader(d)}" | ||
26 | MUSL_LDSO = "${@get_musl_loader(d)}" | ||
27 | |||
28 | EXTRA_OEMAKE = "LINKER_PATH=${MUSL_LDSO} \ | ||
29 | LOADER_NAME=`basename ${GLIBC_LDSO}` \ | ||
30 | " | ||
31 | |||
32 | do_configure () { | ||
33 | : | ||
34 | } | ||
35 | |||
36 | do_compile () { | ||
37 | oe_runmake | ||
38 | } | ||
39 | |||
40 | do_install () { | ||
41 | oe_runmake install 'DESTDIR=${D}${root_prefix}' | ||
42 | if [ "${SITEINFO_BITS}" = "64" ]; then | ||
43 | install -d ${D}${nonarch_base_libdir}${SITEINFO_BITS} | ||
44 | ln -rs ${D}${GLIBC_LDSO} ${D}${nonarch_base_libdir}${SITEINFO_BITS}/`basename ${GLIBC_LDSO}` | ||
45 | fi | ||
46 | install -d ${D}${libdir} | ||
47 | ln -sf ${base_libdir}/libgcompat.so.0 ${D}${libdir}/libgcompat.so | ||
48 | } | ||
49 | |||
50 | FILES:${PN} += "${nonarch_base_libdir}${SITEINFO_BITS}" | ||
51 | |||
52 | INSANE_SKIP:${PN} = "libdir" | ||
53 | |||
54 | RPROVIDES:${PN} += "musl-glibc-compat" | ||
55 | # | ||
56 | # We will skip parsing for non-musl systems | ||
57 | # | ||
58 | COMPATIBLE_HOST = ".*-musl.*" | ||
59 | |||
60 | UPSTREAM_CHECK_COMMITS = "1" | ||