[Buildroot] [git commit branch/next] package/gr-osmosdr: add support for HACKRF receivers
Thomas Petazzoni
thomas.petazzoni at bootlin.com
Wed Aug 30 20:38:30 UTC 2023
commit: https://git.buildroot.net/buildroot/commit/?id=060b88ace6772ceb016a1ebe45d415f10c194c6c
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/next
Signed-off-by: Martin Böh <contact at martb.dev>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni at bootlin.com>
---
package/gr-osmosdr/Config.in | 13 +++++++++++++
package/gr-osmosdr/gr-osmosdr.mk | 7 +++++++
2 files changed, 20 insertions(+)
diff --git a/package/gr-osmosdr/Config.in b/package/gr-osmosdr/Config.in
index d83de75282..72d3c3f481 100644
--- a/package/gr-osmosdr/Config.in
+++ b/package/gr-osmosdr/Config.in
@@ -36,4 +36,17 @@ config BR2_PACKAGE_GR_OSMOSDR_RFSPACE
help
Enable RFSPACE Receivers support
+config BR2_PACKAGE_GR_OSMOSDR_HACKRF
+ bool "Osmocom HACKRF support"
+ depends on !BR2_STATIC_LIBS # hackrf
+ depends on BR2_TOOLCHAIN_HAS_THREADS # hackrf
+ depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9 # hackrf
+ select BR2_PACKAGE_HACKRF
+ help
+ Enable Osmocom HACKRF support
+
+comment "hackrf support needs a toolchain w/ threads, dynamic library, gcc >= 4.9"
+ depends on BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS || \
+ !BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
+
endif
diff --git a/package/gr-osmosdr/gr-osmosdr.mk b/package/gr-osmosdr/gr-osmosdr.mk
index 6011a67539..8491c005d8 100644
--- a/package/gr-osmosdr/gr-osmosdr.mk
+++ b/package/gr-osmosdr/gr-osmosdr.mk
@@ -54,4 +54,11 @@ else
GR_OSMOSDR_CONF_OPTS += -DENABLE_RFSPACE=OFF
endif
+ifeq ($(BR2_PACKAGE_GR_OSMOSDR_HACKRF),y)
+GR_OSMOSDR_CONF_OPTS += -DENABLE_HACKRF=ON
+GR_OSMOSDR_DEPENDENCIES += hackrf
+else
+GR_OSMOSDR_CONF_OPTS += -DENABLE_HACKRF=OFF
+endif
+
$(eval $(cmake-package))
More information about the buildroot
mailing list