diff options
Diffstat (limited to 'testing/ocaml-extlib/APKBUILD')
-rw-r--r-- | testing/ocaml-extlib/APKBUILD | 58 |
1 files changed, 49 insertions, 9 deletions
diff --git a/testing/ocaml-extlib/APKBUILD b/testing/ocaml-extlib/APKBUILD index c940509b441..51bcf7a895a 100644 --- a/testing/ocaml-extlib/APKBUILD +++ b/testing/ocaml-extlib/APKBUILD @@ -1,29 +1,32 @@ # Contributor: Fernando Casas Schossow <casasfernando@outlook.com> # Maintainer: Fernando Casas Schossow <casasfernando@outlook.com> pkgname=ocaml-extlib -pkgver=1.7.8 -pkgrel=0 +_pkgname=extlib +pkgver=1.7.9 +pkgrel=2 pkgdesc="OCaml ExtLib additions to the standard library" url="https://github.com/ygrek/ocaml-extlib" -arch="aarch64 ppc64le x86_64" # restricted by ocaml -license="LGPL-2.1-or-later-WITH-linking-exception" +arch="all !riscv64 !loongarch64" # ocaml +license="LGPL-2.1-or-later WITH OCaml-LGPL-linking-exception" makedepends="ocaml ocaml-findlib-dev ocaml-ocamldoc ocaml-cppo gawk" subpackages="$pkgname-dev $pkgname-doc" source="https://github.com/ygrek/ocaml-extlib/releases/download/$pkgver/extlib-$pkgver.tar.gz" -builddir="$srcdir/extlib-$pkgver" +builddir="$srcdir/$_pkgname-$pkgver" + +# 32-bit archs +case "$CARCH" in + arm*|x86) options="$options textrels" ;; +esac build() { - cd "$builddir" make build } check() { - cd "$builddir" make test } package() { - cd "$builddir" export DESTDIR="$pkgdir" export OCAMLFIND_DESTDIR="$DESTDIR/usr/lib/ocaml" mkdir -p "$OCAMLFIND_DESTDIR" @@ -31,6 +34,43 @@ package() { install -D -m644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE" } +dev() { + default_dev + + cd "$pkgdir" + + local path; find usr/lib/ocaml \( \ + -name '*.cmt' -o \ + -name '*.cmti' -o \ + -name '*.ml' -o \ + -name '*.mli' \ + \) | while read -r path + do + amove "$path" + done +} + +prepare_py_provides() { + local datadir="${subpkgdir:-$pkgdir}" + local pkgbasedir=${pkgbasedir:-"$startdir/pkg"} + local controldir="$pkgbasedir"/.control.${subpkgname:-$pkgname} + + options_has "!tracedeps" && return 0 + + ocaml4-abuild-find provides \ + "$datadir"/usr/lib/ocaml \ + "$controldir" \ + "$pkgver-r$pkgrel" +} + +scan_python3_dependency() { + local controldir="$2" datadir="$3" + + ocaml4-abuild-find requires \ + "$datadir"/usr/lib/ocaml \ + "$controldir" +} + sha512sums=" -664a8366fb4eed685bd8f8907dbc9a8103bbf75ebb5d7635f6db890722e673107aa052bd09c276f5ed10dc3695220234c382d90d4f8c4e6b93ff68dd22e876e4 extlib-1.7.8.tar.gz +2386ac69f037ea520835c0624d39ae9fbffe43a20b18e247de032232ed6f419d667b53d2314c6f56dc71d368bf0b6201a56c2f3f2a5bdfd933766c5a6cb98768 extlib-1.7.9.tar.gz " |