# Contributor: Curt Tilmes # Maintainer: Curt Tilmes pkgname=moarvm pkgver=2021.07 pkgrel=0 pkgdesc="A VM with adaptive optimization and JIT compilation, built for Rakudo" url="http://moarvm.org/" # riscv64 doesn't compile, "Cannot implement AO_compare_and_swap_full on this architecture" arch="all !riscv64" license="Artistic-2.0" makedepends="perl libffi-dev" subpackages="$pkgname-dev $pkgname-doc" source="http://moarvm.org/releases/MoarVM-$pkgver.tar.gz" builddir="$srcdir"/MoarVM-"$pkgver" options="!check" # No tests build() { unset CPPFLAGS CFLAGS perl Configure.pl --prefix=/usr --has-libffi make } package() { install -Dm755 moar "$pkgdir"/usr/bin/moar install -Dm755 libmoar.so "$pkgdir"/usr/lib/libmoar.so } dev() { cd "$builddir" make DESTDIR="$builddir"/install install mkdir -p "$subpkgdir"/usr/share cp -r install/usr/include "$subpkgdir"/usr cp -r install/usr/share/nqp "$subpkgdir"/usr/share install -Dm644 install/usr/share/pkgconfig/moar.pc "$subpkgdir"/usr/lib/pkgconfig/moar.pc } doc() { cd "$builddir" mkdir -p "$subpkgdir"/usr/share/doc/"$pkgname" for file in Artistic2.txt CREDITS LICENSE MANIFEST README.markdown VERSION docs; do cp -r $file "$subpkgdir"/usr/share/doc/"$pkgname" done } sha512sums="7dffb8da9dd2720b9ff52f9a345e96a5dced5a2f1003270ef00a2b9244b4da4242e2d9890146d6648f9cfe7673c7c1433899bf3b2d7971e45496308d215d92f7 MoarVM-2021.07.tar.gz"