2023-07-04 15:10:30 +00:00
|
|
|
# Contributor: Stefan Reimer <stefan@zero-downtime.net>
|
|
|
|
# Maintainer: Stefan Reimer <stefan@zero-downtime.net>
|
|
|
|
pkgname=falco
|
2024-10-25 16:22:11 +00:00
|
|
|
pkgver=0.39.1
|
2023-07-04 15:10:30 +00:00
|
|
|
pkgrel=0
|
|
|
|
pkgdesc="Falco is the open source solution for runtime security for hosts, containers, Kubernetes and the cloud"
|
|
|
|
url="https://github.com/falcosecurity/falco"
|
|
|
|
arch="x86_64 aarch64"
|
|
|
|
license="AGPL-3.0"
|
2024-06-24 13:03:39 +00:00
|
|
|
makedepends="cmake clang bpftool linux-headers bash perl autoconf elfutils-dev libtool argp-standalone
|
2023-11-07 16:31:20 +00:00
|
|
|
musl-fts-dev
|
|
|
|
musl-libintl
|
|
|
|
musl-legacy-error
|
2024-03-12 15:18:42 +00:00
|
|
|
musl-obstack-dev "
|
|
|
|
# protobuf-dev
|
|
|
|
# c-ares-dev
|
|
|
|
# openssl-dev
|
|
|
|
# curl-dev
|
|
|
|
# grpc-dev
|
|
|
|
# yaml-cpp-dev
|
|
|
|
# "
|
2023-07-04 15:10:30 +00:00
|
|
|
options="!check"
|
|
|
|
|
2023-07-31 18:19:31 +00:00
|
|
|
# Original config
|
|
|
|
# https://raw.githubusercontent.com/falcosecurity/rules/main/rules/falco_rules.yaml
|
|
|
|
# https://raw.githubusercontent.com/falcosecurity/falco/master/falco.yaml
|
|
|
|
|
|
|
|
source="
|
|
|
|
$pkgname-$pkgver.tar.gz::https://github.com/falcosecurity/falco/archive/refs/tags/$pkgver.tar.gz
|
|
|
|
falco.patch
|
|
|
|
rules.patch
|
2024-07-18 18:58:33 +00:00
|
|
|
falco.initd
|
2023-07-31 18:19:31 +00:00
|
|
|
"
|
2023-07-04 15:10:30 +00:00
|
|
|
|
2024-10-25 16:22:11 +00:00
|
|
|
subpackages="$pkgname-openrc"
|
|
|
|
|
2023-07-04 15:10:30 +00:00
|
|
|
prepare() {
|
|
|
|
[[ -d build ]] || mkdir build
|
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
|
|
|
cd build
|
2023-11-06 14:25:51 +00:00
|
|
|
|
|
|
|
cmake \
|
|
|
|
-DCPACK_GENERATOR=TGZ \
|
2023-07-04 15:10:30 +00:00
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
|
|
|
-DFALCO_VERSION=$pkgver \
|
|
|
|
-DCMAKE_INSTALL_PREFIX=/usr \
|
2023-11-06 14:25:51 +00:00
|
|
|
-DFALCO_ETC_DIR=/etc/falco \
|
2023-11-07 16:31:20 +00:00
|
|
|
-DUSE_BUNDLED_DEPS=On \
|
2024-03-12 15:18:42 +00:00
|
|
|
-DMINIMAL_BUILD=On \
|
|
|
|
-DUSE_DYNAMIC_LIBELF=Off \
|
2023-07-04 15:10:30 +00:00
|
|
|
-DMUSL_OPTIMIZED_BUILD=On \
|
2023-11-06 14:25:51 +00:00
|
|
|
-DBUILD_DRIVER=Off \
|
|
|
|
-DBUILD_BPF=Off \
|
2024-06-24 13:03:39 +00:00
|
|
|
-DBUILD_LIBSCAP_MODERN_BPF=On \
|
2024-10-25 16:22:11 +00:00
|
|
|
-DADD_FALCOCTL_DEPENDENCY=OFF \
|
2023-11-06 14:25:51 +00:00
|
|
|
..
|
2023-07-04 15:10:30 +00:00
|
|
|
|
2024-06-24 13:03:39 +00:00
|
|
|
make falco
|
2023-07-04 15:10:30 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
|
|
|
cd build
|
2023-07-31 18:19:31 +00:00
|
|
|
make DESTDIR="${pkgdir}" install
|
2023-07-04 15:10:30 +00:00
|
|
|
|
2023-07-31 18:19:31 +00:00
|
|
|
# patch falco config
|
|
|
|
cd $pkgdir/etc/falco
|
2023-11-08 13:00:26 +00:00
|
|
|
patch --no-backup-if-mismatch -i $srcdir/falco.patch
|
|
|
|
patch --no-backup-if-mismatch -i $srcdir/rules.patch
|
2024-06-24 13:03:39 +00:00
|
|
|
|
2023-07-04 15:10:30 +00:00
|
|
|
# We dont build anything on targets so remove sources
|
|
|
|
rm -rf $pkgdir/usr/src
|
|
|
|
rm -rf $pkgdir/usr/lib
|
|
|
|
rm -rf $pkgdir/usr/include
|
2024-07-18 18:58:33 +00:00
|
|
|
|
|
|
|
install -Dm755 "$srcdir"/$pkgname.initd \
|
|
|
|
"$pkgdir"/etc/init.d/$pkgname
|
2023-07-04 15:10:30 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
sha512sums="
|
2024-10-25 16:22:11 +00:00
|
|
|
bb547691640fed21cc4976f469cf3813f888d9cc55e1a4631133c8cd9e6b1adce1d279dddfdf6b191442eeacd0e635a48d4ffa10913059f6117b5710e284899e falco-0.39.1.tar.gz
|
2023-07-31 18:19:31 +00:00
|
|
|
b152fcf6cd81895efa37797ab7ff1aac7350b5f51f2648aa9e3cce9d5ece55791ddf82c396e9da216293e2379a785a294cc972f28a91162dc5bc88ab09e1ab08 falco.patch
|
2024-10-25 16:22:11 +00:00
|
|
|
b6cf8bda946b71241b332d25bcde73e73159ae0993be4291c158e23e44f927b4432d53b9d6d730aee442c94ffc75e119b9f6467e94a0950a19a5f1369afb4e13 rules.patch
|
2024-07-18 18:58:33 +00:00
|
|
|
9d1292a99bab7792bfe344940fa41ccf01318d5f30f854b01457e9f53ccca27f7f334466c061a11fbe8ebf918aeeb7f723b16a233c9e3bd60dd632d831ae9f5c falco.initd
|
2023-07-04 15:10:30 +00:00
|
|
|
"
|