Commit b32708c6 authored by Alexandre Savard's avatar Alexandre Savard
Browse files

[#3561]

- Fixed Autotools mess in test/.
- Brought all the sub-libraries into a single library with LIBADD

Conflicts:

	sflphone-common/configure.ac
	sflphone-common/src/Makefile.am
	sflphone-common/src/audio/Makefile.am
	sflphone-common/src/video/Makefile.am
	sflphone-common/src/video/decoder/Makefile.am
	sflphone-common/test/Makefile.am
parent fbbd25d2
...@@ -407,7 +407,7 @@ AC_DEFUN([BB_ENABLE_DOXYGEN], ...@@ -407,7 +407,7 @@ AC_DEFUN([BB_ENABLE_DOXYGEN],
if test x$DOT = x; then if test x$DOT = x; then
if test "x$enable_dot" = xyes; then if test "x$enable_dot" = xyes; then
AC_MSG_ERROR([could not find dot]) AC_MSG_ERROR([could not find dot])
fi fi
enable_dot=no enable_dot=no
else else
...@@ -416,24 +416,22 @@ AC_MSG_ERROR([could not find dot]) ...@@ -416,24 +416,22 @@ AC_MSG_ERROR([could not find dot])
AM_CONDITIONAL(ENABLE_DOXYGEN, test x$enable_doc = xtrue) AM_CONDITIONAL(ENABLE_DOXYGEN, test x$enable_doc = xtrue)
AC_SUBST(enable_dot) AC_SUBST(enable_dot)
AC_SUBST(enable_html_docs) AC_SUBST(enable_html_docs)
AC_SUBST(enable_latex_docs) AC_SUBST(enable_latex_docs)
]) ])
# Acutally perform the doxygen check # Acutally perform the doxygen check
BB_ENABLE_DOXYGEN BB_ENABLE_DOXYGEN
dnl Datadir directory dnl Datadir directory
sflphone_datadir=$datadir/sflphone sflphone_datadir=$datadir/sflphone
AC_SUBST(sflphone_datadir) AC_SUBST(sflphone_datadir)
dnl Dbus Service activation part dnl Dbus Service activation part
DBUS_SERVICES_DIR="$datadir/dbus-1/services" DBUS_SERVICES_DIR="$datadir/dbus-1/services"
AC_SUBST(DBUS_SERVICES_DIR) AC_SUBST(DBUS_SERVICES_DIR)
AC_DEFINE_UNQUOTED(DBUS_SERVICES_DIR, "$DBUS_SERVICES_DIR", [Where services dir for DBUS is]) AC_DEFINE_UNQUOTED(DBUS_SERVICES_DIR, "$DBUS_SERVICES_DIR", [Where services dir for DBUS is])
# Go! # Go!
AC_SUBST(SFLPHONE_CFLAGS) AC_SUBST(SFLPHONE_CFLAGS)
AC_SUBST(SFLPHONE_LIBS) AC_SUBST(SFLPHONE_LIBS)
AC_OUTPUT AC_OUTPUT
AC_MSG_NOTICE([[Configuration done! Please make sure that pjsip library (libs/pjproject) has already been compiled. Run `make' to build the software.]]) AC_MSG_NOTICE([[Configuration done! Please make sure that pjsip library (libs/pjproject) has already been compiled. Run `make' to build the software.]])
...@@ -56,6 +56,9 @@ AM_CPPFLAGS = \ ...@@ -56,6 +56,9 @@ AM_CPPFLAGS = \
-DPREFIX=\"$(prefix)\" \ -DPREFIX=\"$(prefix)\" \
-DPROGSHAREDIR=\"${datadir}/sflphone\" \ -DPROGSHAREDIR=\"${datadir}/sflphone\" \
$(ZEROCONFFLAGS) \ $(ZEROCONFFLAGS) \
$(GSTREAMER_CFLAGS) \
$(LIBAVCODEC_CFLAGS) \
$(LIBSWSCALE_CFLAGS) \
$(IAX_FLAGS) \ $(IAX_FLAGS) \
$(SIP_CFLAGS) \ $(SIP_CFLAGS) \
-DCODECS_DIR=\""$(sflcodecdir)"\" \ -DCODECS_DIR=\""$(sflcodecdir)"\" \
......
...@@ -57,7 +57,10 @@ sflphoned_LDADD = \ ...@@ -57,7 +57,10 @@ sflphoned_LDADD = \
# sflphoned_LDFLAGS= -pg -luuid # sflphoned_LDFLAGS= -pg -luuid
sflphoned_LDFLAGS= $(UUID_LIBS) sflphoned_LDFLAGS= $(UUID_LIBS)
-DVERSION=\"$(VERSION)\"
# libsflphone
sflphoned_LDADD = ./libsflphone.la
noinst_LTLIBRARIES = libsflphone.la noinst_LTLIBRARIES = libsflphone.la
noinst_HEADERS = \ noinst_HEADERS = \
...@@ -87,6 +90,7 @@ libsflphone_la_LIBADD = \ ...@@ -87,6 +90,7 @@ libsflphone_la_LIBADD = \
./audio/codecs/libcodecdescriptor.la \ ./audio/codecs/libcodecdescriptor.la \
./audio/alsa/libalsalayer.la \ ./audio/alsa/libalsalayer.la \
./audio/pulseaudio/libpulselayer.la \ ./audio/pulseaudio/libpulselayer.la \
./video/libvideo.la \
./dbus/libdbus.la \ ./dbus/libdbus.la \
./config/libconfig.la \ ./config/libconfig.la \
./plug-in/libplugin.la \ ./plug-in/libplugin.la \
...@@ -94,6 +98,36 @@ libsflphone_la_LIBADD = \ ...@@ -94,6 +98,36 @@ libsflphone_la_LIBADD = \
./hooks/libhooks.la \ ./hooks/libhooks.la \
./history/libhistory.la ./history/libhistory.la
libsflphone_la_LDFLAGS = \
@CCGNU2_LIBS@ \
@CCEXT2_LIBS@ \
@ZRTPCPP_LIBS@ \
@GSTREAMER_LIBS@ \
@LIBAVCODEC_LIBS@ \
@LIBSWSCALE_LIBS@ \
$(PJSIP_LIBS) \
@CCRTP_LIBS@ \
@ALSA_LIBS@ \
@PULSEAUDIO_LIBS@ \
@SAMPLERATE_LIBS@ \
@libssl_LIBS@ \
@UUID_LIBS@
libsflphone_la_CFLAGS = \
@CCGNU2_CFLAGS@ \
@CCEXT2_CFLAGS@ \
@ZRTPCPP_CFLAGS@ \
@GSTREAMER_CFLAGS@ \
@LIBAVCODEC_CFLAGS@ \
@LIBSWSCALE_CFLAGS@ \
$(PJSIP_CFLAGS) \
@CCRTP_CFLAGS@ \
@ALSA_CFLAGS@ \
@PULSEAUDIO_CFLAGS@ \
@SAMPLERATE_CFLAGS@ \
@libssl_CFLAGS@ \
@UUID_CFLAGS@
libsflphone_la_SOURCES = libsflphone_la_SOURCES =
indent: indent:
......
...@@ -39,4 +39,12 @@ noinst_HEADERS = \ ...@@ -39,4 +39,12 @@ noinst_HEADERS = \
dcblocker.h \ dcblocker.h \
samplerateconverter.h samplerateconverter.h
libaudio_la_LIBADD = \
./audiortp/libaudiortp.la \
./codecs/libcodecdescriptor.la \
./alsa/libalsalayer.la \
./pulseaudio/libpulselayer.la \
./sound/libsound.la
include $(top_srcdir)/globals.mak
SUBDIRS = decoder rtp
AM_CXXFLAGS = $(GSTREAMER_CFLAGS)
noinst_LTLIBRARIES = libvideo.la
libvideo_la_SOURCES = \
VideoInputSource.cpp \
VideoInputSourceGst.cpp \
VideoEndpoint.cpp \
VideoFrame.cpp \
FrameFormat.cpp \
VideoDevice.cpp \
GstVideoDevice.cpp
libvideo_la_LIBADD = \
decoder/libvideodecoder.la \
rtp/libvideortp.la
libvideo_la_LDFLAGS = $(GSTREAMER_LIBS) $(LIBS)
noinst_HEADERS = \
VideoInputSource.h \
VideoInputSourceGst.h \
VideoEndpoint.h \
FrameFormat.h \
VideoDevice.h \
VideoFrame.h \
FrameFormat.h \
VideoDevice.h \
GstVideoDevice.h
include $(top_srcdir)/globals.mak
AM_CXXFLAGS = $(LIBAVCODEC_CFLAGS) $(LIBSWSCALE_CFLAGS)
noinst_LTLIBRARIES = libvideodecoder.la
libvideodecoder_la_SOURCES = \
H264Decoder.cpp \
VideoDecoder.cpp
noinst_HEADERS = \
VideoDecoder.h \
H264Decoder.h
libvideodecoder_la_LDFLAGS = $(LIBAVCODEC_LIBS) $(LIBSWSCALE_LIBS) $(LIBS)
libvideodecoder_la_LIBADD = $(LIBAVCODEC_LIBS) $(LIBSWSCALE_LIBS) $(LIBS)
\ No newline at end of file
include ../globals.mak include ../globals.mak
TESTS = test check_PROGRAMS = test
check_PROGRAMS = $(TESTS)
test_CXXFLAGS = $(CPPUNIT_CFLAGS) test_CXXFLAGS = $(CPPUNIT_CFLAGS)
test_LDADD = $(LLIBS) test_LDADD = $(LLIBS)
test_LDFLAGS = -ldl
test_SOURCES = main.cpp \ test_SOURCES = \
main.cpp \
validator.cpp \ validator.cpp \
validator.h \ validator.h \
accounttest.h \ accounttest.h \
...@@ -18,8 +19,6 @@ test_SOURCES = main.cpp \ ...@@ -18,8 +19,6 @@ test_SOURCES = main.cpp \
historytest.cpp \ historytest.cpp \
hookmanagertest.h \ hookmanagertest.h \
hookmanagertest.cpp \ hookmanagertest.cpp \
mainbuffertest.h \
mainbuffertest.cpp \
numbercleanertest.h \ numbercleanertest.h \
numbercleanertest.cpp \ numbercleanertest.cpp \
pluginmanagertest.h \ pluginmanagertest.h \
...@@ -35,9 +34,6 @@ test_SOURCES = main.cpp \ ...@@ -35,9 +34,6 @@ test_SOURCES = main.cpp \
LLIBS=$(CPPUNIT_LIBS) \ LLIBS=$(CPPUNIT_LIBS) \
../src/libsflphone.la \
$(ZEROCONFLIB) \
$(LIB_DNSSD) \
@ALSA_LIBS@ \ @ALSA_LIBS@ \
@PULSEAUDIO_LIBS@ \ @PULSEAUDIO_LIBS@ \
@CPPUNIT_LIBS@ \ @CPPUNIT_LIBS@ \
...@@ -48,27 +44,4 @@ LLIBS=$(CPPUNIT_LIBS) \ ...@@ -48,27 +44,4 @@ LLIBS=$(CPPUNIT_LIBS) \
@libssl_LIBS@ \ @libssl_LIBS@ \
@SAMPLERATE_LIBS@ \ @SAMPLERATE_LIBS@ \
$(PJSIP_LIBS) \ $(PJSIP_LIBS) \
../src/sflphoned-logger.o \ ../src/libsflphone.la
../src/sflphoned-managerimpl.o \
../src/sflphoned-account.o\
../src/sflphoned-accountcreator.o \
../src/sflphoned-call.o \
../src/sflphoned-conference.o \
../src/sflphoned-eventthread.o \
../src/sflphoned-managerimpl_registration.o \
../src/sflphoned-numbercleaner.o \
../src/sflphoned-observer.o \
../src/sflphoned-voiplink.o \
../src/sip/libsiplink_la-sipcall.o \
../src/iax/libiaxlink_la-iaxcall.o \
../src/sip/libsiplink_la-sipvoiplink.o \
../src/iax/libiaxlink_la-iaxvoiplink.o \
../src/sip/libsiplink_la-sipaccount.o \
../src/iax/libiaxlink_la-iaxaccount.o \
../src/sip/libsiplink_la-sdp.o \
../src/sip/libsiplink_la-sdpmedia.o \
../src/plug-in/pluginmanager.o \
../src/plug-in/audiorecorder/audiorecord.o \
../src/audio/samplerateconverter.o \
../src/audio/delaydetection.o \
../src/history/historymanager.o
\ No newline at end of file
...@@ -28,10 +28,10 @@ ...@@ -28,10 +28,10 @@
* as that of the covered work. * as that of the covered work.
*/ */
#include "logger.h" #include <logger.h>
#include "global.h" #include <manager.h>
#include "manager.h"
#include "constants.h" #define CONFIG_SAMPLE "sflphonedrc-sample"
#include <cppunit/CompilerOutputter.h> #include <cppunit/CompilerOutputter.h>
#include <cppunit/extensions/TestFactoryRegistry.h> #include <cppunit/extensions/TestFactoryRegistry.h>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment