From a76836c7b0f1e5fbda190139ce72e7cfdb2308d8 Mon Sep 17 00:00:00 2001 From: "A. Wilcox" Date: Fri, 21 Sep 2018 21:39:49 +0000 Subject: user/gcompat: new package --- user/gcompat/APKBUILD | 39 +++++++++++++++++++++++++++++++++++++++ user/gcompat/no-utmp.patch | 16 ++++++++++++++++ 2 files changed, 55 insertions(+) create mode 100644 user/gcompat/APKBUILD create mode 100644 user/gcompat/no-utmp.patch (limited to 'user/gcompat') diff --git a/user/gcompat/APKBUILD b/user/gcompat/APKBUILD new file mode 100644 index 000000000..84f8a70d1 --- /dev/null +++ b/user/gcompat/APKBUILD @@ -0,0 +1,39 @@ +# Maintainer: A. Wilcox +pkgname=gcompat +pkgver=0.3.0 +pkgrel=0 +pkgdesc="The GNU C Library compatibility layer for musl" +url="https://code.foxkit.us/adelie/gcompat" +arch="all" +options="!check" # No test suite. +license="UoI-NCSA" +depends="" +makedepends="libucontext-dev" +replaces="libc6-compat" +source="https://distfiles.adelielinux.org/source/gcompat/$pkgname-$pkgver.tar.xz + no-utmp.patch + " + +case "$CARCH" in +armel) _ld="ld-linux.so.3" ;; +armhf | armv7) _ld="ld-linux-armhf.so.3" ;; +aarch64) _ld="ld-linux-aarch64.so.1" ;; +x86) _ld="ld-linux.so.2" ;; +x86_64) _ld="ld-linux-x86-64.so.2" ;; +mips* | ppc | s390*) _ld="ld.so.1" ;; +ppc64le) _ld="ld64.so.2" ;; +ppc64) _ld="ld64.so.1" ;; +esac + +build() { + cd "$builddir" + make LINKER_PATH="/lib/ld-musl-${CARCH}.so.1" LOADER_NAME="$_ld" WITH_LIBUCONTEXT=YesPlease +} + +package() { + cd "$builddir" + make LINKER_PATH="/lib/ld-musl-${CARCH}.so.1" LOADER_NAME="$_ld" WITH_LIBUCONTEXT=YesPlease DESTDIR="$pkgdir" install +} + +sha512sums="1f7dd73efd556b7e0f7f1c80751185583de24daf4ab235b488ea1ab98cea2d3a94abed341b922be0bd43c8d539a00176b892c78acf09f2adacb279c09648b3be gcompat-0.3.0.tar.xz +34fbf97cfbad2bae219e238f5edcb55425c6d7c9be7dde02aa0e8223dbf163ff20f535539de2232a1ef3c6f47a92eac6e00484af99dc8beb192c761b15389b82 no-utmp.patch" diff --git a/user/gcompat/no-utmp.patch b/user/gcompat/no-utmp.patch new file mode 100644 index 000000000..c5d2251b1 --- /dev/null +++ b/user/gcompat/no-utmp.patch @@ -0,0 +1,16 @@ +--- gcompat-0.3.0/libgcompat/utmp.c.old 2018-09-05 02:26:02.850000000 +0000 ++++ gcompat-0.3.0/libgcompat/utmp.c 2018-09-21 21:39:17.350000000 +0000 +@@ -1,12 +1,11 @@ + #include /* NULL */ +-#include /* struct utmp */ + + /** + * Get user accounting database entries. + * + * LSB 5.0: LSB-Core-generic/baselib-getutent-r-3.html + */ +-int getutent_r(struct utmp *buffer, struct utmp **result) ++int getutent_r(void *buffer, void **result) + { + /* musl does not implement getutent(). */ + *result = NULL; -- cgit v1.2.3-70-g09d2