summaryrefslogtreecommitdiff
path: root/pcr/mosquitto/PKGBUILD
blob: 652e756910c73ed646c396ade2bc910dc47f0233 (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
# This is the PKGBUILD for mosquitto, an MQTT broker and example clients
# Maintainer: Alexander Rust <mail at alr dot st> 
# Contributor: Dan Anderson <dan-anderson at cox dptnet>

pkgname=mosquitto
pkgver=1.1.3
pkgrel=2
pkgdesc="An Open Source MQTT v3.1 Broker"
arch=('i686' 'x86_64' 'arm' 'armv6h' 'mips64el')
url="http://mosquitto.org/"
makedepends=('python')
optdepends=('python: python support')
license=('BSD')
source=(http://mosquitto.org/files/source/$pkgname-$pkgver.tar.gz{,.asc} "$pkgname.service" )
md5sums=('fd0cae17221d778b0a002c31e6c3de9e'
         'SKIP'
         'b7cdd7a65d9a7ac5a8c2456f4b1f2d8f')

build() {
  cd "$srcdir/$pkgname-$pkgver"
  #Remove hardcoded prefix
  find -name Makefile -exec sed '/prefix=/d' -i {} \;

  make prefix=/usr
}

package() {
  cd "$srcdir/$pkgname-$pkgver"
  make prefix=/usr DESTDIR="$pkgdir/" install
  
  # Systemd service file
  install -Dm644 $srcdir/$pkgname.service $pkgdir/usr/lib/systemd/system/$pkgname.service
  
  # License files
  install -Dm644 LICENSE.txt $pkgdir/usr/share/licenses/$pkgname/LICENSE
  install -Dm644 LICENSE-3rd-party.txt $pkgdir/usr/share/licenses/$pkgname/LICENSE-3rd-party
}

# vim:set ts=2 sw=2 et: