aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2017-11-17 12:16:39 +0100
committerAndreas Eversberg <jolly@eversberg.eu>2017-11-25 19:28:36 +0100
commit45a5568f7032b11953d6ac4321970d5780eaf613 (patch)
tree9675d5b8a0a5c3bc958bbbbb9017563ebf026e15
parent0e3e4d92308e9da7a7f5eaeedb995259cd1ce021 (diff)
Restructure: Move sound from common code to 'libsound'
-rw-r--r--.gitignore1
-rw-r--r--configure.ac1
-rw-r--r--src/Makefile.am2
-rw-r--r--src/amps/Makefile.am1
-rw-r--r--src/anetz/Makefile.am1
-rw-r--r--src/bnetz/Makefile.am1
-rw-r--r--src/cnetz/Makefile.am1
-rw-r--r--src/common/Makefile.am1
-rw-r--r--src/common/sender.h2
-rw-r--r--src/jtacs/Makefile.am1
-rw-r--r--src/libmncc/mncc_console.c2
-rw-r--r--src/libsound/Makefile.am6
-rw-r--r--src/libsound/sound.h (renamed from src/common/sound.h)0
-rw-r--r--src/libsound/sound_alsa.c (renamed from src/common/sound_alsa.c)6
-rw-r--r--src/nmt/Makefile.am1
-rw-r--r--src/r2000/Makefile.am1
-rw-r--r--src/tacs/Makefile.am1
-rw-r--r--src/test/Makefile.am4
18 files changed, 26 insertions, 7 deletions
diff --git a/.gitignore b/.gitignore
index 855ddbf..5a7ad4e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -37,6 +37,7 @@ src/libfilter/libfilter.a
src/libwave/libwave.a
src/libfft/libfft.a
src/libmncc/libmncc.a
+src/libsound/libsound.a
src/common/libcommon.a
src/common/libmobile.a
src/anetz/libgermanton.a
diff --git a/configure.ac b/configure.ac
index 7b5779d..8a4e745 100644
--- a/configure.ac
+++ b/configure.ac
@@ -92,6 +92,7 @@ AC_OUTPUT(
src/libwave/Makefile
src/libfft/Makefile
src/libmncc/Makefile
+ src/libsound/Makefile
src/common/Makefile
src/anetz/Makefile
src/bnetz/Makefile
diff --git a/src/Makefile.am b/src/Makefile.am
index 708f01e..9b0653e 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,3 +1,3 @@
AUTOMAKE_OPTIONS = foreign
-SUBDIRS = libimage libcompandor libgoertzel libjitter libsquelch libhagelbarger libdtmf libtimer libsamplerate libscrambler libemphasis libfsk libfm libfilter libwave libfft libmncc common anetz bnetz cnetz nmt amps tacs jtacs r2000 tv test
+SUBDIRS = libsound libimage libcompandor libgoertzel libjitter libsquelch libhagelbarger libdtmf libtimer libsamplerate libscrambler libemphasis libfsk libfm libfilter libwave libfft libmncc common anetz bnetz cnetz nmt amps tacs jtacs r2000 tv test
diff --git a/src/amps/Makefile.am b/src/amps/Makefile.am
index ed9e455..c2fe952 100644
--- a/src/amps/Makefile.am
+++ b/src/amps/Makefile.am
@@ -39,6 +39,7 @@ amps_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
diff --git a/src/anetz/Makefile.am b/src/anetz/Makefile.am
index e4f1dcd..5c9c8d6 100644
--- a/src/anetz/Makefile.am
+++ b/src/anetz/Makefile.am
@@ -31,6 +31,7 @@ anetz_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
diff --git a/src/bnetz/Makefile.am b/src/bnetz/Makefile.am
index 5c89f08..88f7a44 100644
--- a/src/bnetz/Makefile.am
+++ b/src/bnetz/Makefile.am
@@ -27,6 +27,7 @@ bnetz_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
diff --git a/src/cnetz/Makefile.am b/src/cnetz/Makefile.am
index 53ef378..e01c685 100644
--- a/src/cnetz/Makefile.am
+++ b/src/cnetz/Makefile.am
@@ -30,6 +30,7 @@ cnetz_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
diff --git a/src/common/Makefile.am b/src/common/Makefile.am
index 83bc9e4..6d1e07b 100644
--- a/src/common/Makefile.am
+++ b/src/common/Makefile.am
@@ -5,7 +5,6 @@ noinst_LIBRARIES = libcommon.a libmobile.a
libcommon_a_SOURCES = \
sample.c \
debug.c \
- sound_alsa.c \
display_wave.c \
display_measurements.c
diff --git a/src/common/sender.h b/src/common/sender.h
index 09fab06..22a23a1 100644
--- a/src/common/sender.h
+++ b/src/common/sender.h
@@ -1,4 +1,4 @@
-#include "sound.h"
+#include "../libsound/sound.h"
#ifdef HAVE_SDR
#include "sdr.h"
#endif
diff --git a/src/jtacs/Makefile.am b/src/jtacs/Makefile.am
index d440d8b..61e7a44 100644
--- a/src/jtacs/Makefile.am
+++ b/src/jtacs/Makefile.am
@@ -25,6 +25,7 @@ jtacs_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
diff --git a/src/libmncc/mncc_console.c b/src/libmncc/mncc_console.c
index 41682aa..ac356c3 100644
--- a/src/libmncc/mncc_console.c
+++ b/src/libmncc/mncc_console.c
@@ -33,7 +33,7 @@
#include "mncc_console.h"
#include "cause.h"
#include "../common/call.h"
-#include "../common/sound.h"
+#include "../libsound/sound.h"
static int new_callref = 0; /* toward mobile */
diff --git a/src/libsound/Makefile.am b/src/libsound/Makefile.am
new file mode 100644
index 0000000..ffa876f
--- /dev/null
+++ b/src/libsound/Makefile.am
@@ -0,0 +1,6 @@
+AM_CPPFLAGS = -Wall -Wextra -g $(all_includes)
+
+noinst_LIBRARIES = libsound.a
+
+libsound_a_SOURCES = \
+ sound_alsa.c
diff --git a/src/common/sound.h b/src/libsound/sound.h
index 71293c0..71293c0 100644
--- a/src/common/sound.h
+++ b/src/libsound/sound.h
diff --git a/src/common/sound_alsa.c b/src/libsound/sound_alsa.c
index c18f123..a0fe878 100644
--- a/src/common/sound_alsa.c
+++ b/src/libsound/sound_alsa.c
@@ -21,9 +21,9 @@
#include <stdint.h>
#include <math.h>
#include <alsa/asoundlib.h>
-#include "sample.h"
-#include "debug.h"
-#include "sender.h"
+#include "../common/sample.h"
+#include "../common/debug.h"
+#include "../common/sender.h"
typedef struct sound {
snd_pcm_t *phandle, *chandle;
diff --git a/src/nmt/Makefile.am b/src/nmt/Makefile.am
index 80d0026..d6ad99c 100644
--- a/src/nmt/Makefile.am
+++ b/src/nmt/Makefile.am
@@ -38,6 +38,7 @@ nmt_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
diff --git a/src/r2000/Makefile.am b/src/r2000/Makefile.am
index 3a3b059..4066ff7 100644
--- a/src/r2000/Makefile.am
+++ b/src/r2000/Makefile.am
@@ -26,6 +26,7 @@ radiocom2000_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
diff --git a/src/tacs/Makefile.am b/src/tacs/Makefile.am
index a79bf8e..62d681f 100644
--- a/src/tacs/Makefile.am
+++ b/src/tacs/Makefile.am
@@ -26,6 +26,7 @@ tacs_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
diff --git a/src/test/Makefile.am b/src/test/Makefile.am
index d0507fa..dfdfd5f 100644
--- a/src/test/Makefile.am
+++ b/src/test/Makefile.am
@@ -24,6 +24,7 @@ test_filter_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
@@ -56,6 +57,7 @@ test_emphasis_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
@@ -77,6 +79,7 @@ test_dms_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \
@@ -98,6 +101,7 @@ test_sms_LDADD = \
$(top_builddir)/src/libwave/libwave.a \
$(top_builddir)/src/libfft/libfft.a \
$(top_builddir)/src/libmncc/libmncc.a \
+ $(top_builddir)/src/libsound/libsound.a \
$(ALSA_LIBS) \
$(UHD_LIBS) \
$(SOAPY_LIBS) \