blob: 61ca0e271cf10e5eda9e42b9f1049066d484b268 (
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
56
57
58
59
60
61
62
63
|
# Contributor: Borys Zhukov <mp5@mp5.im>
# Maintainer: Borys Zhukov <mp5@mp5.im>
pkgname=ocaml
pkgver=4.04.1
pkgrel=0
pkgdesc="Main implementation of the Caml programming language"
url="http://caml.inria.fr"
arch="all !x86 !armhf !ppc64le"
license="LGPLv2"
makedepends="ncurses-dev zlib-dev gdbm-dev"
depends="ncurses-dev"
options="textrels"
subpackages="$pkgname-doc"
source="http://caml.inria.fr/pub/distrib/ocaml-${pkgver%.*}/$pkgname-$pkgver.tar.gz
010_all_execstacks.patch
020_all_configure.patch
050_all_objinfoldflags.patch
fix-s390x-mcontext-fields.patch
"
builddir="$srcdir/$pkgname-$pkgver"
build() {
cd "$builddir"
#strip out -fomit-frame-pointer due to -pg
local _cflags="$CFLAGS"
CFLAGS="-fPIC"
for i in $_cflags; do
case $i in
-fomit-frame-pointer);;
*) CFLAGS="$CFLAGS $i";;
esac
done
./configure -cc "${CC:-gcc}" \
--bindir /usr/bin \
--libdir /usr/lib/ocaml \
--mandir /usr/share/man
make -j1 world.opt
}
check() {
cd "$builddir"
# there seem to be some spurious failures, ignore until fixed
make test || true
cd testsuite
make report || true
}
package() {
cd "$builddir"
make BINDIR="$pkgdir"/usr/bin LIBDIR="$pkgdir"/usr/lib/ocaml MANDIR="$pkgdir"/usr/share/man install
install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
install -Dm644 Changes "$pkgdir"/usr/share/doc/$pkgname/Changes
find "$pkgdir"/usr/lib/ocaml -name \*.ml -delete
}
sha512sums="e7ecbd661026d1bb3dfb0416adb15a842514d3b76e85f8b0daa921b10e5773b7d99059fb038c0abd34ff150e4c82d0906c45f2fe2bc2569b0e8798d532c9e173 ocaml-4.04.1.tar.gz
71ac807fb1173863b9dcf8e5fb4e651e0155d6cd0e4b327f5457b83fc09e1b5fbe34150c5d8ccd24f0faff1a8419f5ed8310aa60af1f38c2766ccc37dc6c3835 010_all_execstacks.patch
286758402517a1345556d374b0c3fc49eb93f1ec2bb9ccd2ffe1cc043f59d93b154f68eb9ff410020a15d3d8f148b27f249b7f97954b0e8a080cdd32d6014b4a 020_all_configure.patch
61d9cae6c8be7c16ed4aa6fafc533e2879caadbbe0e023775c1d735c0e54e66e94b9ffab8dc0b0b12c19ccf5c389e05f62af822014d202ae54c52943a0639753 050_all_objinfoldflags.patch
76eeec042f21a3d81487275ac6745e598ceb0d30937870d8aa3f7186bb656ec950d3bd6dc42812a838dbdf6fa28794be5014277761c82a414e2e93b6ee2bea1e fix-s390x-mcontext-fields.patch"
|