aboutsummaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac35
1 files changed, 16 insertions, 19 deletions
diff --git a/configure.ac b/configure.ac
index 7590896..ba5d65a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
# Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012 Her Majesty the
# Queen in Right of Canada (Communications Research Center Canada)
-# Copyright (C) 2022 Matthias P. Braendli, http://opendigitalradio.org
+# Copyright (C) 2023 Matthias P. Braendli, http://opendigitalradio.org
# This file is part of ODR-DabMod.
#
@@ -34,7 +34,7 @@ AC_PROG_CC
AM_PROG_CC_C_O
AC_PROG_INSTALL
-AX_CXX_COMPILE_STDCXX(11,noext,mandatory)
+AX_CXX_COMPILE_STDCXX(17,noext,mandatory)
EXTRA=""
AC_ARG_ENABLE([prof],
@@ -52,9 +52,9 @@ AC_ARG_ENABLE([zeromq],
AC_ARG_ENABLE([native],
[AS_HELP_STRING([--disable-native], [Do not compile with -march=native])],
[], [enable_native=yes])
-AC_ARG_ENABLE([easydabv3],
- [AS_HELP_STRING([--enable-easydabv3], [Build for EasyDABv3 board])],
- [], [enable_easydabv3=no])
+AC_ARG_ENABLE([dexter],
+ [AS_HELP_STRING([--enable-dexter], [Build for PrecisionWave Dexter board])],
+ [], [enable_dexter=no])
AC_ARG_ENABLE([limesdr],
[AS_HELP_STRING([--enable-limesdr], [Build for LimeSDR board])],
[], [enable_limesdr=no])
@@ -77,9 +77,7 @@ AX_CHECK_COMPILE_FLAG([-Wdouble-promotion], [CXXFLAGS="$CXXFLAGS -Wdouble-promot
AX_CHECK_COMPILE_FLAG(["-Wformat=2"], [CXXFLAGS="$CXXFLAGS -Wformat=2"], [], ["-Werror"])
AC_LANG_POP([C++])
-
-AS_IF([test "x$enable_easydabv3" = "xno"],
- [PKG_CHECK_MODULES([FFTW], [fftw3f], [], [AC_MSG_ERROR([FFTW is required])])])
+PKG_CHECK_MODULES([FFTW], [fftw3f], [], [AC_MSG_ERROR([FFTW is required])])
echo "Checking zeromq"
@@ -101,28 +99,27 @@ AS_IF([test "x$enable_trace" != "xno"],
# Define conditionals for Makefile.am
AM_CONDITIONAL([IS_GIT_REPO], [test -d '.git'])
-AM_CONDITIONAL([COMPILE_FOR_EASYDABV3], [test "x$enable_easydabv3" = "xyes"])
# Defines for config.h
AX_PTHREAD([], AC_MSG_ERROR([requires pthread]))
-AS_IF([test "x$enable_easydabv3" = "xno"],
- [PKG_CHECK_MODULES([SOAPYSDR], [SoapySDR], enable_soapysdr=yes, enable_soapysdr=no)])
+PKG_CHECK_MODULES([SOAPYSDR], [SoapySDR], enable_soapysdr=yes, enable_soapysdr=no)
AS_IF([test "x$enable_limesdr" = "xyes"],
[AC_CHECK_LIB([LimeSuite], [LMS_Init], [LIMESDR_LIBS="-lLimeSuite"],
[AC_MSG_ERROR([LimeSDR LimeSuite is required])])])
+AS_IF([test "x$enable_dexter" = "xyes"],
+ [AC_CHECK_LIB([iio], [iio_create_scan_context], [IIO_LIBS="-liio"],
+ [AC_MSG_ERROR([libiio is required])])])
+
AS_IF([test "x$enable_bladerf" = "xyes"],
[AC_CHECK_LIB([bladeRF], [bladerf_open], [BLADERF_LIBS="-lbladeRF"],
[AC_MSG_ERROR([BladeRF library is required])])])
AC_SUBST([CFLAGS], ["$CFLAGS $EXTRA $FFTW_CFLAGS $SOAPYSDR_CFLAGS $PTHREAD_CFLAGS"])
AC_SUBST([CXXFLAGS], ["$CXXFLAGS $EXTRA $FFTW_CFLAGS $SOAPYSDR_CFLAGS $PTHREAD_CFLAGS"])
-AC_SUBST([LIBS], ["$FFTW_LIBS $SOAPYSDR_LIBS $PTHREAD_LIBS $ZMQ_LIBS $LIMESDR_LIBS $BLADERF_LIBS"])
-
-AS_IF([test "x$enable_easydabv3" = "xyes" && test "x$enable_output_uhd" == "xyes"],
- AC_MSG_ERROR([Cannot enable both EasyDABv3 and UHD output]))
+AC_SUBST([LIBS], ["$FFTW_LIBS $SOAPYSDR_LIBS $PTHREAD_LIBS $ZMQ_LIBS $LIMESDR_LIBS $IIO_LIBS $BLADERF_LIBS"])
# Checks for UHD.
AS_IF([test "x$enable_output_uhd" = "xyes"],
@@ -144,12 +141,12 @@ AS_IF([test "x$enable_soapysdr" = "xyes"],
AS_IF([test "x$enable_limesdr" = "xyes"],
[AC_DEFINE(HAVE_LIMESDR, [1], [Define if LimeSDR output is enabled]) ])
+AS_IF([test "x$enable_dexter" = "xyes"],
+ [AC_DEFINE(HAVE_DEXTER, [1], [Define if Dexter output is enabled])])
+
AS_IF([test "x$enable_bladerf" = "xyes"],
[AC_DEFINE(HAVE_BLADERF, [1], [Define if BladeRF output is enabled]) ])
-AS_IF([test "x$enable_easydabv3" = "xyes"],
- AC_DEFINE(BUILD_FOR_EASYDABV3, [1], [Define if we are building for EasyDABv3]))
-
# Checks for header files.
AC_CHECK_HEADERS([fcntl.h limits.h memory.h netinet/in.h stdint.h stdlib.h string.h sys/time.h sys/timeb.h unistd.h])
@@ -217,7 +214,7 @@ echo "***********************************************"
echo
enabled=""
disabled=""
-for feat in prof trace output_uhd zeromq soapysdr easydabv3 limesdr bladerf
+for feat in prof trace output_uhd zeromq soapysdr limesdr bladerf dexter
do
eval var=\$enable_$feat
AS_IF([test "x$var" = "xyes"],