PKGBUILDs/community/bpftrace/PKGBUILD
2021-02-19 13:06:41 +00:00

43 lines
1.3 KiB
Bash

# Maintainer: Anatol Pomozov
# Contributor: Tommaso Sardelli <lacapannadelloziotom at gmail dot com>
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - upstream patch to fix FTBFS
buildarch=8
pkgname=bpftrace
pkgver=0.11.4
pkgrel=2
pkgdesc='High-level tracing language for Linux eBPF'
arch=('x86_64')
url='https://github.com/iovisor/bpftrace'
license=('Apache')
depends=('libelf' 'zlib' 'llvm-libs' 'clang' 'bcc' 'libbpf')
makedepends=('cmake' 'llvm' 'git' 'linux-headers')
options=(!strip)
source=("https://github.com/iovisor/bpftrace/archive/v$pkgver/bpftrace-$pkgver.tar.gz"
'https://github.com/iovisor/bpftrace/commit/330953c11190c23a12f98d374d1b5eb6d7aad1fe.patch')
sha512sums=('611a7e61dbd1f4cc52b7e51a1a143296ff7b2df115b3a28034c674d8eefb5d482cac551ab82d6b7cc2f6fc0668b07d2d9e283dff371fd9a3f649c80113fdca82'
'1daa3f0f4f91ba403e44786873a351c55be7ef7781138ca0465eb294879d60126e67e7900c4b36a91c61ed29855283f6b971caae800b4b3bd9420d7cd2ef23c3')
prepare() {
cd bpftrace-$pkgver
patch -p1 -i ../330953c11190c23a12f98d374d1b5eb6d7aad1fe.patch
}
build() {
cd bpftrace-$pkgver
mkdir -p build
cd build
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr ..
make
}
package() {
cd bpftrace-$pkgver/build
make DESTDIR="$pkgdir" install
}