37 lines
1.2 KiB
Bash
37 lines
1.2 KiB
Bash
# Template file for 'rustnet'
|
|
pkgname=rustnet
|
|
version=1.6.0
|
|
revision=1
|
|
archs="x86_64* aarch64*"
|
|
build_style=cargo
|
|
make_check_args="-- --skip test_ebpf"
|
|
hostmakedepends="pkg-config clang elfutils-devel"
|
|
makedepends="libpcap-devel elfutils-devel zlib-devel"
|
|
short_desc="Cross-platform network monitoring terminal UI tool built with Rust"
|
|
maintainer="zenobit <zen@osowoso.org>"
|
|
license="Apache-2.0"
|
|
homepage="https://github.com/domcyrus/rustnet"
|
|
changelog="https://raw.githubusercontent.com/domcyrus/rustnet/refs/heads/main/CHANGELOG.md"
|
|
distfiles="https://github.com/domcyrus/rustnet/archive/refs/tags/v${version}.tar.gz"
|
|
checksum=245fc7074d5f142fbf1c798233be86b715b4f2ce3b3cfec10fabdcbbc9345ddb
|
|
|
|
_setup_env() {
|
|
# workaround the cc-rs mixing CFLAGS for host and target.
|
|
# https://github.com/rust-lang/cc-rs/issues/1469
|
|
export CFLAGS_${RUST_BUILD//-/_}="${CFLAGS_host}" \
|
|
CXXFLAGS_${RUST_BUILD//-/_}="${CXXFLAGS_host}" \
|
|
LDFLAGS_${RUST_BUILD//-/_}="${LDFLAGS_host}" \
|
|
CFLAGS_${RUST_TARGET//-/_}="${CFLAGS}" \
|
|
CXXFLAGS_${RUST_TARGET//-/_}="${CXXFLAGS}" \
|
|
LDFLAGS_${RUST_TARGET//-/_}="${LDFLAGS}" \
|
|
CFLAGS="" CXXFLAGS="" LDFLAGS=""
|
|
}
|
|
|
|
pre_build() {
|
|
_setup_env
|
|
}
|
|
|
|
pre_install() {
|
|
_setup_env
|
|
}
|