diff options
author | Jakub Jirutka <jakub@jirutka.cz> | 2018-03-11 00:48:15 +0100 |
---|---|---|
committer | Jakub Jirutka <jakub@jirutka.cz> | 2018-03-11 21:37:43 +0100 |
commit | f19a5a28ad3bfe797d3709975c822f563c8eb57b (patch) | |
tree | 99f0b7d83b351ebb27c8f0f3331d67fecb56d540 | |
parent | 91f8af81ecaa28b550fe2b04ed7307cea441e83e (diff) | |
download | aports-f19a5a28ad3bfe797d3709975c822f563c8eb57b.tar.bz2 aports-f19a5a28ad3bfe797d3709975c822f563c8eb57b.tar.xz |
testing/ocaml-ounit: new aport
http://ounit.forge.ocamlcore.org/
A unit test framework for OCaml
-rw-r--r-- | testing/ocaml-ounit/APKBUILD | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/testing/ocaml-ounit/APKBUILD b/testing/ocaml-ounit/APKBUILD new file mode 100644 index 0000000000..da44d61de7 --- /dev/null +++ b/testing/ocaml-ounit/APKBUILD @@ -0,0 +1,56 @@ +# Contributor: Jakub Jirutka <jakub@jirutka.cz> +# Maintainer: Jakub Jirutka <jakub@jirutka.cz> +pkgname=ocaml-ounit +_pkgname=ounit +pkgver=2.0.7 +pkgrel=0 +pkgdesc="A unit test framework for OCaml" +url="http://ounit.forge.ocamlcore.org/" +arch="all !x86 !armhf !s390x" # limited by ocaml aport +license="MIT" +depends="ocaml-runtime" +depends_dev="$pkgname=$pkgver-r$pkgrel" +makedepends="ocaml ocaml-findlib ocaml-ocamlbuild-dev ocamlbuild libxml2-utils" +options="!check" # FIXME: fix tests! +subpackages="$pkgname-dev" +source="http://forge.ocamlcore.org/frs/download.php/1738/$_pkgname-$pkgver.tar.gz" +builddir="$srcdir/$_pkgname-$pkgver" + +build() { + cd "$builddir" + + ./configure \ + --prefix=/usr \ + --disable-debug \ + --disable-docs \ + --enable-tests + make build +} + +check() { + cd "$builddir" + make test +} + +package() { + cd "$builddir" + + mkdir -p "$pkgdir"/usr/lib/ocaml + make install OCAMLFIND_DESTDIR="$pkgdir/usr/lib/ocaml" + + # Remove annotation files and sources. + cd "$pkgdir"/usr/lib/ocaml/oUnit + rm -f *.annot *.cmt* *.ml +} + +dev() { + local sitelib="usr/lib/ocaml/oUnit" + default_dev + + cd "$pkgdir"/$sitelib + + mkdir -p "$subpkgdir"/$sitelib + mv *.cmx *.cmxa *.mli "$subpkgdir"/$sitelib/ +} + +sha512sums="8691b350c9c9101449ad854e3a16ca9bacec07541286c6e36bd893e869772c8ac66371ecf72950a62a0720c41627ef8f0970d34c9b6e0a2a88fcbc8fe2d25172 ounit-2.0.7.tar.gz" |