summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 921218a95dc874fb0b42df73711ee73173c02ce4 (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
# Maintainer: Andrew Sun <adsun701 at gmail dot com>
# Contributor: orumin <dev at orum dot in>

_basename=check
pkgname="lib32-$_basename"
pkgver=0.15.1
pkgrel=1
pkgdesc="A unit testing framework for C (32-bit)"
arch=('x86_64')
url="https://libcheck.github.io/check/"
license=('LGPL')
depends=('lib32-glibc' "${_basename}")
makedepends=('git' 'gcc-multilib' 'lib32-gcc-libs')
_commit=9843d4811d30e8c99d79f325ad2063805f77f4ea  # tags/0.15.1
source=("git+https://github.com/libcheck/check#commit=$_commit")
md5sums=('SKIP')

pkgver() {
  cd $_basename
  git describe --tags | sed 's/-/+/g'
}

prepare() {
  cd $_basename
  autoreconf -fvi
}

build() {
  cd $_basename

  export CC='gcc -m32'
  export CXX='g++ -m32'
  export PKG_CONFIG_PATH='/usr/lib32/pkgconfig'

  ./configure --prefix=/usr --disable-static \
    --libdir=/usr/lib32 
  make
}

package() {
  cd $_basename
  make DESTDIR="$pkgdir" install
  rm -rf ${pkgdir}/usr/{bin,share,include}
}