blob: 901e818f14a58218abdc93fe8a2a3df03ba4d62a (
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
64
65
66
67
68
69
|
# Maintainer: xiretza <xiretza+aur@gmail.com>
# Maintainer: Rod Kay <rodakay5 at gmail dot com>
pkgname=libadalang
epoch=1
pkgver=21.0.0
pkgrel=3
pkgdesc="A high performance semantic engine for the Ada programming language."
arch=('i686' 'x86_64')
url="https://github.com/AdaCore/libadalang"
license=('GPL3' 'custom')
depends=("gnatcoll-iconv" "gnatcoll-gmp")
makedepends=('gprbuild' 'python-setuptools' 'python-mako' 'python-funcy' 'python-e3-core' 'python-docutils')
source=("libadalang-$pkgver.tar.gz::https://github.com/AdaCore/libadalang/archive/v$pkgver.tar.gz"
"langkit-$pkgver.tar.gz::https://github.com/AdaCore/langkit/archive/v$pkgver.tar.gz")
noextract=()
sha256sums=('afc4b54619d5ee003ba2828969071fa38ced4f68319cc5aeee4736981258b935'
'534d1e56f03961a6f28d248956b040b31429e602640c07f1b5ff89f76e9fcf5f')
build()
{
cd "$srcdir/libadalang-$pkgver"
export PYTHONPATH="$srcdir/langkit-$pkgver:$PYTHONPATH"
python ada/manage.py generate
python ada/manage.py build --build-mode=prod --gargs="-R -cargs $CFLAGS -largs $LDFLAGS -gargs"
make -C dev_manual html
}
package()
{
cd "$srcdir/libadalang-$pkgver"
python ada/manage.py install --build-mode=prod "$pkgdir/usr"
# Install the developers manual
cd dev_manual/_build/html
for file in $(find . -type f); do
install -m 644 -D ${file} "$pkgdir/usr/share/doc/$pkgname"/${file#source/}
done
cd "$srcdir/libadalang-$pkgver"
# Install the license.
install -D -m644 \
"COPYING3" \
"$pkgdir/usr/share/licenses/$pkgname/COPYING3"
# Install the custom license.
install -D -m644 \
"COPYING.RUNTIME" \
"$pkgdir/usr/share/licenses/$pkgname/COPYING.RUNTIME"
# Install the Python binding
cd build/python
python setup.py install --root="$pkgdir"
rm -fr "$pkgdir/usr/python"
# Fix ocaml bindings location
mkdir -p "$pkgdir/usr/lib/ocaml/"
mv "$pkgdir/usr/ocaml" "$pkgdir/usr/lib/ocaml/libadalang"
}
|