mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-04-13 02:36:34 +02:00
Email for maintainer of ocaml-num (alpine-mips-patches) bounced. Permission has been obtained from the other 2 maintainers involved.
80 lines
2 KiB
Text
80 lines
2 KiB
Text
# Contributor: Fernando Casas Schossow <casasfernando@outlook.com>
|
|
# Maintainer: Celeste <cielesti@protonmail.com>
|
|
maintainer="Celeste <cielesti@protonmail.com>"
|
|
pkgname=ocaml-calendar
|
|
_pkgname=calendar
|
|
pkgver=2.04
|
|
pkgrel=4
|
|
pkgdesc="Objective Caml library for managing dates and times"
|
|
url="https://forge.ocamlcore.org/projects/calendar/"
|
|
arch="all !riscv64 !loongarch64" # ocaml
|
|
license="LGPL-2.1-or-later WITH OCaml-LGPL-linking-exception"
|
|
makedepends="ocaml ocaml-findlib-dev ocaml-ocamldoc gawk"
|
|
subpackages="$pkgname-dev $pkgname-doc"
|
|
source="https://download.ocamlcore.org/calendar/calendar/$pkgver/calendar-$pkgver.tar.gz"
|
|
builddir="$srcdir/$_pkgname-$pkgver"
|
|
|
|
# 32-bit archs
|
|
case "$CARCH" in
|
|
arm*|x86) options="$options textrels" ;;
|
|
esac
|
|
|
|
build() {
|
|
./configure --prefix=/usr --libdir=/usr/lib
|
|
make
|
|
}
|
|
|
|
check() {
|
|
make tests
|
|
}
|
|
|
|
package() {
|
|
export DESTDIR="$pkgdir"
|
|
export OCAMLFIND_DESTDIR="$DESTDIR/usr/lib/ocaml"
|
|
mkdir -p "$OCAMLFIND_DESTDIR"
|
|
make install
|
|
install -D -m644 COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"
|
|
install -D -m644 LGPL "$pkgdir/usr/share/licenses/$pkgname/LGPL"
|
|
install -D -m644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
|
|
}
|
|
|
|
dev() {
|
|
default_dev
|
|
|
|
cd "$pkgdir"
|
|
|
|
local path; find usr/lib/ocaml \( \
|
|
-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="
|
|
3941768428eda47f47912846cc2921ee82c722bda7cf6095c1c8bdcfebc19bb8f64ebb1a25475396d2a49c186b83421af63602a54a261684117b1c036a66cf3d calendar-2.04.tar.gz
|
|
"
|