Skip to content

Commit

Permalink
comms/gqrx: add flavors for Qt5 and Qt6
Browse files Browse the repository at this point in the history
  • Loading branch information
martymac committed Oct 12, 2023
1 parent ddb103c commit 4918ddd
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions comms/gqrx/Makefile
@@ -1,8 +1,10 @@
PORTNAME= gqrx
PORTVERSION= 2.17.2
DISTVERSIONPREFIX= v
PORTREVISION= 1
PORTEPOCH= 1
CATEGORIES= comms hamradio
PKGNAMESUFFIX= -${FLAVOR}

MAINTAINER= martymac@FreeBSD.org
COMMENT= Software defined radio receiver powered by GNU Radio and Qt
Expand Down Expand Up @@ -31,16 +33,24 @@ LIB_DEPENDS= libgnuradio-runtime.so:comms/gnuradio \
libjack.so:audio/jack \
libportaudio.so:audio/portaudio

USES= cmake compiler:c++11-lang gl pkgconfig qt:6
FLAVORS= qt5 qt6
FLAVOR?= qt6

USES= cmake compiler:c++11-lang gl pkgconfig qt:${FLAVOR:S/qt//}

USE_GITHUB= yes
GH_ACCOUNT= gqrx-sdr
USE_GL= gl
USE_QT= base svg
_USE_QT_qt5= core gui network svg widgets
_USE_QT_qt6= base svg
USE_QT= ${_USE_QT_${FLAVOR}}

CONFLICTS_INSTALL= gqrx ${FLAVORS:N${FLAVOR}:S/^/${PORTNAME}-/}

# XXX Use Portaudio as Gqrx is invariably linked to it
# (auto-detected and used through Gnuradio CMake files)
CMAKE_ARGS+= -DLINUX_AUDIO_BACKEND:STRING="Portaudio"
CMAKE_ARGS+= -DLINUX_AUDIO_BACKEND:STRING="Portaudio" \
-DFORCE_QT${FLAVOR:S/qt//}:BOOL=ON

# XXX Work around Gnuradio 3.8 headers (gnuradio/rpcserver_aggregator.h) still
# using std::unary_function (removed with C++17). This breaks when building
Expand Down

0 comments on commit 4918ddd

Please sign in to comment.