diff options
| author | Jakub Jirutka <jakub@jirutka.cz> | 2018-07-07 18:57:25 +0200 |
|---|---|---|
| committer | Jakub Jirutka <jakub@jirutka.cz> | 2018-07-07 18:54:35 +0200 |
| commit | 12bef6276ca0bea6b67616ddf503cf25f6f25213 (patch) | |
| tree | de40b5f6d5194118bc0255c6213255353f9bb84d /testing | |
| parent | e91fef413761fc45151da5a05192f7c666762e62 (diff) | |
| download | aports-12bef6276ca0bea6b67616ddf503cf25f6f25213.tar.bz2 aports-12bef6276ca0bea6b67616ddf503cf25f6f25213.tar.xz | |
testing/ocaml-wtf8: new aport
https://github.com/flowtype/ocaml-wtf8
An ocaml library that implements a WTF-8 encoder and decoder
Diffstat (limited to 'testing')
| -rw-r--r-- | testing/ocaml-wtf8/APKBUILD | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/testing/ocaml-wtf8/APKBUILD b/testing/ocaml-wtf8/APKBUILD new file mode 100644 index 0000000000..54e3393545 --- /dev/null +++ b/testing/ocaml-wtf8/APKBUILD @@ -0,0 +1,53 @@ +# Contributor: Jakub Jirutka <jakub@jirutka.cz> +# Maintainer: Jakub Jirutka <jakub@jirutka.cz> +pkgname=ocaml-wtf8 +_pkgname=wtf8 +pkgver=1.0.1 +pkgrel=0 +pkgdesc="An ocaml library that implements a WTF-8 encoder and decoder" +url="https://github.com/flowtype/ocaml-wtf8" +arch="all !x86 !armhf !s390x" # limited by ocaml aport +license="MIT" +depends="ocaml-runtime" +makedepends="dune ocaml ocaml-findlib opam" +options="!check" # no tests provided +subpackages="$pkgname-dev" +source="https://github.com/flowtype/$pkgname/archive/v$pkgver/$pkgname-$pkgver.tar.gz" +builddir="$srcdir/$pkgname-$pkgver" + +build() { + cd "$builddir" + jbuilder build @install +} + +package() { + cd "$builddir" + + mkdir -p "$pkgdir"/usr/lib/ocaml + jbuilder install \ + --destdir="$pkgdir"/usr \ + --libdir="$pkgdir"/usr/lib/ocaml + + # There's just a readme and changelog. + rm -Rf "$pkgdir"/usr/doc + + # Remove annotation files and sources. + cd "$pkgdir"/usr/lib/ocaml/$_pkgname + rm -f *.cmt* *.ml + + chmod +x *.cmxs +} + +dev() { + default_dev + + depends="$pkgname=$pkgver-r$pkgrel" + local sitelib="usr/lib/ocaml/$_pkgname" + + mkdir -p "$subpkgdir"/$sitelib + + cd "$pkgdir"/$sitelib + mv *.cmx *.cmxa *.mli "$subpkgdir"/$sitelib/ +} + +sha512sums="f5c76346dfb365d128625538e76d8bbf0a3901cf25f437763105f32ffdbd0fcf2a8748253c694840de4978fb5c758fc709fcb00606278fb2683bed2c7af35c4c ocaml-wtf8-1.0.1.tar.gz" |
