Subject: [alpine-aports] [PATCH] testing/ocaml-xml-light: new aport

From: Fernando Casas Schössow <[email-masked]>
Date: Thu, 7 Feb 2019 09:28:39 +0000

https://github.com/ncannasse/xml-light
Minimal XML parser and printer for OCaml
---
 testing/ocaml-xml-light/APKBUILD | 45 ++++++++++++++++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 testing/ocaml-xml-light/APKBUILD

diff --git a/testing/ocaml-xml-light/APKBUILD b/testing/ocaml-xml-light/APKBUILD
new file mode 100644
index 0000000000..eb536a4eee
--- /dev/null
+++ b/testing/ocaml-xml-light/APKBUILD
@@ -0,0 +1,45 @@
+# Contributor: Fernando Casas Schossow <[email-masked]>
+# Maintainer: Fernando Casas Schossow <[email-masked]>
+pkgname=ocaml-xml-light
+pkgver=2.4
+pkgrel=0
+pkgdesc="Minimal XML parser and printer for OCaml"
+url="https://github.com/ncannasse/xml-light"
+arch="all"
+license="LGPL-2.1-or-later-WITH-linking-exception"
+makedepends="ocaml ocaml-findlib-dev ocaml-ocamldoc gawk"
+subpackages="$pkgname-dev $pkgname-doc"
+source="https://github.com/ncannasse/xml-light/archive/$pkgver.tar.gz"
+builddir="$srcdir/xml-light-$pkgver"
+
+build() {
+	cd "$builddir"
+	make all
+	make doc
+	make opt
+}
+
+check() {
+	cd "$builddir"
+	./test.exe <<EOF
+<abc><123/></abc>
+
+EOF
+	./test_opt.exe <<EOF
+<abc><123/></abc>
+
+EOF
+}
+
+package() {
+	cd "$builddir"
+	export DESTDIR="$pkgdir"
+	export OCAMLFIND_DESTDIR="$DESTDIR/usr/lib/ocaml"
+	mkdir -p "$OCAMLFIND_DESTDIR" "$OCAMLFIND_DESTDIR/stublibs"
+	rm -f test.cmi
+	make install_ocamlfind
+	install -D -m644 README "$pkgdir/usr/share/licenses/$pkgname/README"
+	install -D -m644 -t "$pkgdir/usr/share/doc/$pkgname/html/" doc/*
+}
+
+sha512sums="029068c6eb48cd1223438dc0f86e1c5e6fd0412d160ea4d79928eec5e5f5843af46260d7240e4260851e9580e7f92d578c764c63c8e0acab348637455493ef02  2.4.tar.gz"
-- 
2.20.1

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---