diff options
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..e51aa81e0933 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,74 @@ +# Maintainer: shulhan <ms@kilabit.info> + +pkgname=stackdriver-collectd +pkgver=6.1.0 +pkgrel=1 + +pkgdesc="Stackdriver's monitoring agent based on collectd" +arch=(x86_64) +url='https://github.com/Stackdriver/collectd' +license=('MIT') +groups=() + +depends=( + 'curl' + 'iptables' + 'libxml2' + 'lua' + 'systemd-libs' + 'yajl' +) +makedepends=( + 'autoconf' + 'automake' + 'bison' + 'flex' + 'gcc' + 'libtool' + 'pkg-config' +) +optdepends=( + 'mariadb-libs' +) + +provides=('stackdriver-collectd') +conflicts=('collectd') + +backup=('etc/collectd.conf') +source=( + "${pkgname}-v${pkgver}.tar.gz::https://github.com/Stackdriver/collectd/archive/${pkgver}.tar.gz" + "collectd.conf" + "stackdriver-collectd.service" + "stackdriver-collectd.sh" +) +md5sums=('fef6db9b22153903ed98d4c888ccc35a' + '7a2c4528d4ff161d7ac665daedc5fb3c' + '251922321b6d566c8f1750402e4cfd21' + 'e4da9e61c35f6d74d3d76a02eb441ff2') + +prepare() { + cd collectd-${pkgver} + ./build.sh +} + +build() { + cd collectd-${pkgver} + ./configure + make +} + +package() { + cd collectd-${pkgver} + + # install binaries and libraries + make DESTDIR="${pkgdir}/" install + + # install license file and documentation + cd "${srcdir}/collectd-${pkgver}" + install -Dm 644 COPYING -t "${pkgdir}/usr/share/licenses/${pkgname}/" + + cd ${srcdir} + install -Dm 644 collectd.conf -t "${pkgdir}/opt/collectd/etc/" + install -Dm 644 stackdriver-collectd.service -t "${pkgdir}/usr/lib/systemd/system/" + install -Dm 644 stackdriver-collectd.sh -t "${pkgdir}/etc/profile.d/" +} |