1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-24 11:45:18 +03:00
aports/testing/hackrf/APKBUILD

47 lines
1.2 KiB
Text

# Contributor: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
# Maintainer: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
pkgname=hackrf
pkgver=2022.09.1
pkgrel=1
pkgdesc="Driver for HackRF, allowing general purpose software defined radio"
url="https://github.com/greatscottgadgets/hackrf"
arch="all"
license="GPL-2.0-only"
options="!check" # no test suite
makedepends="
cmake
fftw-dev
libusb-dev
ninja
"
subpackages="
$pkgname-static
$pkgname-dev
$pkgname-firmware:firmware:noarch
$pkgname-libs
"
source="$pkgname-$pkgver.tar.xz::https://github.com/greatscottgadgets/hackrf/releases/download/v$pkgver/hackrf-$pkgver.tar.xz"
build() {
cmake -B build -G Ninja \
-DCMAKE_BUILD_TYPE=MinSizeRel \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_INSTALL_LIBDIR=lib \
-DUDEV_RULES_PATH=/usr/lib/udev/rules.d \
host
cmake --build build
}
package() {
DESTDIR="$pkgdir" cmake --install build
}
firmware() {
pkgdesc="$pkgdesc (firmware)"
find "$builddir/firmware-bin" -type f -exec install -Dm644 -t "$subpkgdir/usr/share/hackrf/" {} \;
}
sha512sums="
c3b8b6f18cb80e3506c09dc71f2c01c127ad6d88ed028be3b659953cf7bb1e36b9dba83b4bb04c916bd7c2b66faeae1e602c53368e1e56454d6fe831961e01ee hackrf-2022.09.1.tar.xz
"