summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 4b8b56811fc3dc9c0e79965385fc98ec77e3156f (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
# Maintainer: Kasper Laudrup <laudrup@stacktrace.dk>
pkgname=properties-cpp-bzr
pkgver=r17
pkgrel=3
pkgdesc="A very simple convenience library for handling properties and signals in C++11"
arch=('i686' 'x86_64')
url="https://launchpad.net/properties-cpp"
license=('LGPL3')
makedepends=('breezy' 'cmake')
provides=('properties-cpp')
source=('properties-cpp-bzr::bzr+https://code.launchpad.net/~phablet-team/properties-cpp/trunk')
md5sums=('SKIP')

_bzrtrunk=BZRURL
_bzrmod=MODNAME

prepare() {
  cd "$pkgname"
  # The tests requires a CMakeLists.txt to be present in the gmock
  # include dir which is not the case on Arch, so exclude it
  sed -i '/add_subdirectory(tests)/d' CMakeLists.txt
  # The pkgconfig files are located in /usr/share on Arch
  sed -i 's#${CMAKE_INSTALL_LIBDIR}#/usr/share#g' data/CMakeLists.txt
  mkdir -p build
  cd build
  cmake -Wno-dev -DCMAKE_INSTALL_PREFIX:PATH=/usr ..
}

pkgver() {
  cd "$pkgname"
  printf "r%s" "$(bzr revno)"
}

package() {
  cd "$pkgname/build"
  echo "pkgdir is $pkgdir"
  make DESTDIR="$pkgdir/" install
}