aports/testing/ocaml-zed/APKBUILD
Celeste 40ea6c48d7 */*: add maintainer variable for aports i maintain
leaving the Maintainer comment there for better visual cues, syntax highlighting, and easy conversion to a Contributor comment

since Contributor comments are not being removed, just treat my Maintainer comments like Contributor ones, as a normal comment
2024-10-16 16:20:45 +00:00

83 lines
1.9 KiB
Text

# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Celeste <cielesti@protonmail.com>
maintainer="Celeste <cielesti@protonmail.com>"
pkgname=ocaml-zed
_pkgname=zed
pkgver=3.1.0
pkgrel=3
pkgdesc="Abstract engine for text edition in OCaml"
url="https://github.com/ocaml-community/zed"
arch="all !riscv64 !loongarch64" # ocaml
license="BSD-3-Clause"
depends_dev="
$pkgname=$pkgver-r$pkgrel
ocaml-camomile-dev
ocaml-charinfo_width-dev
ocaml-react-dev
"
makedepends="$depends_dev dune ocaml"
options="!check" # no tests provided
subpackages="$pkgname-dev"
source="$pkgname-$pkgver.tar.gz::https://github.com/ocaml-community/zed/archive/$pkgver.tar.gz
use-built-in-result-lib.patch
"
builddir="$srcdir/$_pkgname-$pkgver"
_ocamldir=usr/lib/ocaml
# 32-bit archs
case "$CARCH" in
arm*|x86) options="$options textrels" ;;
esac
build() {
dune build --release --verbose
}
package() {
dune install \
--destdir="$pkgdir" \
--docdir=/.omit
rm -Rf "$pkgdir"/.omit
}
dev() {
default_dev
cd "$pkgdir"
local path; find $_ocamldir \( \
-name '*.cmt' -o \
-name '*.cmti' -o \
-name '*.ml' -o \
-name '*.mli' \
\) | while read -r path
do
amove "$path"
done
}
prepare_py_provides() {
local datadir="${subpkgdir:-$pkgdir}"
local pkgbasedir=${pkgbasedir:-"$startdir/pkg"}
local controldir="$pkgbasedir"/.control.${subpkgname:-$pkgname}
options_has "!tracedeps" && return 0
ocaml4-abuild-find provides \
"$datadir"/usr/lib/ocaml \
"$controldir" \
"$pkgver-r$pkgrel"
}
scan_python3_dependency() {
local controldir="$2" datadir="$3"
ocaml4-abuild-find requires \
"$datadir"/usr/lib/ocaml \
"$controldir"
}
sha512sums="
d4457af15f970adb7b1ed543017e590fa0ecc47171d6dd520a1397f21ce0219caa30a9db7bedb76c0602d4f6d0f0684012cc33feafe18b848d3261a460dea10a ocaml-zed-3.1.0.tar.gz
03655451e382d7539589ef80a97e1e16edb6f269bbf95b5997c334f08dad0332807588dc9cb5b1e4aebee64c88fcd8d1d5015bdec044093dff19bbffa84b3b53 use-built-in-result-lib.patch
"