summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: f84d22dc5c77e1ae1a477e739616d83a02630b61 (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
# Maintainer: Hiral Patel <ahirapatel at gmail dot com>
_bpn=paho-mqtt-cpp
pkgname=${_bpn}-git
pkgver=1.2.0.r58.ge9db86f
pkgrel=1
pkgdesc="A C++ wrapper around paho-mqtt-c"
arch=('x86_64')
url="https://github.com/eclipse/paho.mqtt.cpp"
license=('EPL')
depends=(paho-mqtt-c gcc-libs openssl)
makedepends=(git cmake)
provides=(${_bpn})
conflicts=(${_bpn})
source=("$_bpn::git+https://github.com/eclipse/paho.mqtt.cpp.git")
md5sums=('SKIP')

pkgver() {
	cd $_bpn
	git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}

prepare() {
	mkdir -p build
}

build() {
	cd build
	cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_LIBDIR=/usr/lib ../$_bpn
	make
}

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