summaryrefslogtreecommitdiff
path: root/pcr/bctoolbox-git/PKGBUILD
blob: b03366823466993d2f4fc6f0af0b3d705190f249 (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
# Maintainer: André Silva <emulatorman@parabola.nu>

_pkgname=bctoolbox
pkgname="bctoolbox-git"
pkgver=r253.270ebc8
pkgrel=1
pkgdesc="Utilities library used by Belledonne Communications softwares like belle-sip, mediastreamer2 and linphone"
arch=('x86_64' 'i686')
url="https://github.com/BelledonneCommunications/bctoolbox"
license=('GPL2')
makedepends=('cmake' 'git')
depends=('mbedtls' 'bcunit-git')
conflicts=("${_pkgname}")
provides=("${_pkgname}")
source=("${_pkgname}-${pkgver}::git+https://github.com/BelledonneCommunications/bctoolbox#branch=master")
sha256sums=('SKIP')

pkgver() {
  cd $_pkgname-$pkgver
  printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

build() {
  cd $_pkgname-$pkgver
  cmake . -DCMAKE_INSTALL_PREFIX=$pkgdir/usr
  make
}

package() {
  cd $_pkgname-$pkgver
  make install
  
  if [ "${CARCH}" = "x86_64" ]; then
    cd "${pkgdir}"
    mv usr/lib64 usr/lib
  fi
}