summaryrefslogtreecommitdiff
path: root/libre/gmp-static/PKGBUILD
blob: 83fa8087d4f2e121f1517f58ba9113f877b43bba (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
# Maintainer: Márcio Silva <coadde@parabola.nu>
# based of gmp

_pkgname=gmp
pkgname=gmp-static
pkgver=6.1.0
pkgrel=3
pkgdesc="A free library for arbitrary precision arithmetic (static libraries only)"
arch=('i686' 'x86_64' 'armv7h')
url="http://gmplib.org/"
depends=('gcc-libs-static' 'gmp')
license=('LGPL3' 'GPL')
options=('staticlibs')
source=(https://gmplib.org/download/gmp/gmp-${pkgver}.tar.xz{,.sig})
md5sums=('a9868ef2556ad6a2909babcd1428f3c7'
         'SKIP')
validpgpkeys=('5972C48224C1E7E62AA0275D1150EE33C1A000B0')   # Marco Bodrato

build() {
  cd "${srcdir}/${_pkgname}-${pkgver}"

  ./configure --build=${CHOST} \
    --prefix=/usr \
    --enable-cxx
    # do not --enable-fat - see https://bugs.archlinux.org/task/47284 
  make
}

check() {
  cd "${srcdir}/${_pkgname}-${pkgver}"
  make check
}

package() {
  cd "${srcdir}/${_pkgname}-${pkgver}"
  make DESTDIR="${pkgdir}" install

  # remove conflicting files
  rm -vr ${pkgdir}/usr/{include,share}
  rm -v ${pkgdir}/usr/lib/libgmp*.so*
}