summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorDaniel Peukert2020-03-21 15:14:15 +0100
committerDaniel Peukert2020-03-21 15:14:15 +0100
commitd0397140df46334e39ca0af44926ed1d969d0cbc (patch)
treeaee71d00157aa798af20f8b16d3b8d8771c906e6 /PKGBUILD
downloadaur-d0397140df46334e39ca0af44926ed1d969d0cbc.tar.gz
Added ocaml-ppx_assert and dependencies
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD34
1 files changed, 34 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..2941ebb7c84
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,34 @@
+# Maintainer: Daniel Peukert <dan.peukert@gmail.com>
+# Contributor: Jakob Gahde <j5lx@fmail.co.uk>
+_projectname='ppx_cold'
+pkgname="ocaml-$_projectname"
+pkgver='0.13.0'
+pkgrel='1'
+pkgdesc='Expands [@Cold] into [@inline never][@specialise never][@Local never]'
+arch=('x86_64' 'i686' 'arm' 'armv6h' 'armv7h' 'aarch64')
+url="https://github.com/janestreet/$_projectname"
+license=('MIT')
+depends=('ocaml>=4.04.2' 'ocaml-base>=0.13.0' 'ocaml-ppxlib>=0.9.0')
+makedepends=('dune>=1.5.1')
+options=('!strip')
+source=("$pkgname-$pkgver-$pkgrel.tar.gz::$url/archive/v$pkgver.tar.gz")
+sha256sums=('d2e97191bdd465ad9e8f59169d48022ebfa2e21bb5ca764cd3be07d59a8e4642')
+
+_sourcedirectory="$_projectname-$pkgver"
+
+build() {
+ cd "$srcdir/$_sourcedirectory/"
+ dune build -p "$_projectname" --verbose
+}
+
+package() {
+ cd "$srcdir/$_sourcedirectory/"
+ DESTDIR="$pkgdir" dune install --prefix '/usr' --libdir 'lib/ocaml'
+
+ install -dm755 "$pkgdir/usr/share/doc/$pkgname"
+ mv "$pkgdir/usr/doc/$_projectname/"* "$pkgdir/usr/share/doc/$pkgname/"
+ rm -r "$pkgdir/usr/doc/"
+
+ install -dm755 "$pkgdir/usr/share/licenses/$pkgname"
+ ln -sf "/usr/share/doc/$pkgname/LICENSE.md" "$pkgdir/usr/share/licenses/$pkgname/LICENSE.md"
+}