aboutsummaryrefslogtreecommitdiffstats
path: root/testing/bpftrace
diff options
context:
space:
mode:
Diffstat (limited to 'testing/bpftrace')
-rw-r--r--testing/bpftrace/APKBUILD37
1 files changed, 37 insertions, 0 deletions
diff --git a/testing/bpftrace/APKBUILD b/testing/bpftrace/APKBUILD
new file mode 100644
index 0000000000..c1663ee174
--- /dev/null
+++ b/testing/bpftrace/APKBUILD
@@ -0,0 +1,37 @@
+# Maintainer: Konstantin Kulikov <k.kulikov2@gmail.com>
+pkgname=bpftrace
+pkgver=0.9
+pkgrel=0
+pkgdesc="High-level tracing language for Linux eBPF"
+url="https://github.com/iovisor/bpftrace"
+arch="x86_64"
+license="Apache-2.0"
+makedepends="cmake llvm7-dev llvm7-static clang-dev clang-static
+ flex-dev bison elfutils-dev linux-headers bcc"
+source="$pkgname-$pkgver.tar.gz::https://github.com/iovisor/bpftrace/archive/v$pkgver.tar.gz"
+# Tests require root, network to download gmock and a few tests fail.
+options="!check"
+builddir="$srcdir/$pkgname-$pkgver/build"
+
+prepare() {
+ default_prepare
+ mkdir $builddir
+}
+
+build() {
+ cmake \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DCMAKE_CXX_FLAGS="$CXXFLAGS" \
+ -DCMAKE_C_FLAGS="$CFLAGS" \
+ -DBUILD_TESTING:BOOL=OFF \
+ ..
+ make
+}
+
+package() {
+ make DESTDIR="$pkgdir" install
+ mv $pkgdir/usr/man $pkgdir/usr/share/bpftrace/
+}
+
+sha512sums="771c412a6b1ee7a7d5bba9e0910633056c6f5523e5d1efd9d7ccb5b9f9b462b7bda8d170c5ed0653f3c1bfd5cc77fce2fd552f12eb8222a8747620b3dc9b49f8 bpftrace-0.9.tar.gz"