blob: ae6ef2f685aea3e04974de39f6871135546211fa (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=ocaml-dtoa
_pkgname=dtoa
pkgver=0.3.2
pkgrel=0
pkgdesc="double-to-ascii ocaml implementation"
url="https://github.com/flowtype/ocaml-dtoa"
arch="all !x86 !armhf !armv7 !s390x !mips !mips64" # limited by ocaml aport
license="MIT"
depends="ocaml-runtime"
checkdepends="ocaml-ounit-dev"
makedepends="dune ocaml ocaml-findlib opam"
subpackages="$pkgname-dev"
source="https://github.com/flowtype/$pkgname/archive/v$pkgver/$pkgname-$pkgver.tar.gz
bignum_align-noinline.patch
"
build() {
dune build @install
}
check() {
dune runtest
}
package() {
mkdir -p "$pkgdir"/usr/lib/ocaml
dune install \
--destdir="$pkgdir" \
--prefix=/usr \
--libdir=/usr/lib/ocaml
# There's just a readme and changelog.
rm -Rf "$pkgdir"/usr/doc
# Remove annotation files and sources.
cd "$pkgdir"/usr/lib/ocaml/$_pkgname
rm -f *.cmt* *.ml
}
dev() {
default_dev
depends="$pkgname=$pkgver-r$pkgrel"
local sitelib="usr/lib/ocaml/$_pkgname"
mkdir -p "$subpkgdir"/$sitelib
cd "$pkgdir"/$sitelib
mv *.cmx *.cmxa *.mli "$subpkgdir"/$sitelib/
}
sha512sums="a5dcce83f53725c45b0891f6af6275c5e617d536a2d491852215c9aefbbd22c7ac65f2738795eaba3a162e360d2fa86b33a98cdefb030230045789179c300604 ocaml-dtoa-0.3.2.tar.gz
b5974d89debc14fb0beeb31a08d4a3d82298336488fc907005bcc2fcb1c5a1df12bc2b596956809f4982d9125995d01f08312f5591bd8857c6f0b136bf9aeb25 bignum_align-noinline.patch"
|