archrelease: copy trunk to extra-x86_64
[arch-packages.git] / swig / trunk / PKGBUILD
bloba54091d1338d8799a63d25519dea0abcd654ef33
1 # Maintainer: Felix Yan <felixonmars@archlinux.org>
2 # Contributor: Stéphane Gaudreault <stephane@archlinux.org>
3 # Contributor: Tom Newsom <Jeepster@gmx.co.uk>
5 pkgname=swig
6 pkgver=4.0.2
7 pkgrel=5
8 pkgdesc="Generate scripting interfaces to C/C++ code"
9 arch=('x86_64')
10 url="http://www.swig.org/"
11 license=('custom')
12 depends=('pcre' 'gcc-libs')
13 checkdepends=('ruby' 'python' 'java-environment' 'tcl' 'php' 'lua' 'r' 'go' 'boost')
14 source=(https://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.gz
15         jdk17.patch
16         python310.patch)
17 sha512sums=('05e7da70ce6d9a733b96c0bcfa3c1b82765bd859f48c74759bbf4bb1467acb1809caa310cba5e2b3280cd704fca249eaa0624821dffae1d2a75097c7f55d14ed'
18             '06671202b6a1f82e96166ada7982b9dd70ae5365dc90c4f24e81596963f7bd3960913f2eca5250ad76bee4b2e51f10ed922595722036e3da9da63d6aa988cb3e'
19             '3de6484d920d8ecf042102d40af3a375ecb1ead3c4e0bc45ae63633e5fd652f52e1938108f747514a654a19d93a783afe2968b141be56957f438162263d62d8a')
21 prepare() {
22   cd ${pkgname}-${pkgver}
23   patch -Np1 -i ../jdk17.patch
25   # https://github.com/swig/swig/issues/2044
26   patch -Np1 -i ../python310.patch
29 build() {
30   cd ${pkgname}-${pkgver}
31   ./configure --prefix=/usr
32   make
35 check() {
36   cd ${pkgname}-${pkgver}
37   make check PY3=y
40 package() {
41   cd ${pkgname}-${pkgver}
42   make DESTDIR="${pkgdir}" install
43   install -D -m644 LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
44   install -D -m644 LICENSE-UNIVERSITIES "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE-UNIVERSITIES