Browse code

c/f:cmake: Fix building with libevent2 (required)

Stefan Sayer authored on 27/02/2014 14:42:47
Showing 1 changed files
... ...
@@ -86,6 +86,8 @@ MESSAGE(STATUS "SEMS doc prefix was set to: ${SEMS_DOC_PREFIX}")
86 86
 
87 87
 SET(CMAKE_VERBOSE_MAKEFILE ON)
88 88
 
89
+FIND_PACKAGE(Libevent2 REQUIRED)
90
+
89 91
 # compile with spandsp DTMF detection? see soft-switch.org
90 92
 #   this needs a fairly new version of spandsp - tested with 0.0.4pre11
91 93
 #   will not work with spandsp 0.0.2 .
Browse code

c/f: fix APP_NAME for CMake build system

Stefan Sayer authored on 27/02/2014 14:40:31
Showing 1 changed files
... ...
@@ -27,6 +27,8 @@ ENDIF(EXISTS ${CMAKE_SOURCE_DIR}/.git)
27 27
 
28 28
 MESSAGE(STATUS "Configuring ${CMAKE_PROJECT_NAME} v. ${SEMS_VERSION}")
29 29
 
30
+SET(SEMS_APP_NAME "sems")
31
+
30 32
 IF(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR AND NOT MSVC_IDE)
31 33
 	message(FATAL_ERROR "In-source builds are not allowed.
32 34
 CMake would overwrite all makefiles distributed with SEMS.
Browse code

Allow build against external iLBC

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 03/08/2012 09:18:37
Showing 1 changed files
... ...
@@ -40,7 +40,7 @@ OPTION(SEMS_USE_SPANDSP       "Build with spandsp" OFF)
40 40
 OPTION(SEMS_USE_LIBSAMPLERATE "Build with libsamplerate" OFF)
41 41
 OPTION(SEMS_USE_ZRTP          "Build with ZRTP" OFF)
42 42
 OPTION(SEMS_USE_MP3           "Build with Lame MP3" OFF)
43
-OPTION(SEMS_USE_ILBC          "Build with bundled iLBC library" ON)
43
+OPTION(SEMS_USE_ILBC          "Build with iLBC library (fallback to bundled)" ON)
44 44
 OPTION(SEMS_USE_TTS           "Build with Text-to-speech support (requires Flite)" OFF)
45 45
 OPTION(SEMS_USE_OPENSSL       "Build with OpenSSL" OFF)
46 46
 OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
... ...
@@ -124,9 +124,14 @@ ELSE(SEMS_USE_MP3)
124 124
 ENDIF(SEMS_USE_MP3)
125 125
 
126 126
 IF(SEMS_USE_ILBC)
127
-	MESSAGE(STATUS "Using bundled iLBC library: YES (default)")
127
+	FIND_PACKAGE(Ilbc)
128
+	IF(ILBC_FOUND)
129
+		MESSAGE(STATUS "Using iLBC library: YES (external)")
130
+	ELSE(ILBC_FOUND)
131
+		MESSAGE(STATUS "Using iLBC library: YES (bundled, default)")
132
+	ENDIF(ILBC_FOUND)
128 133
 ELSE(SEMS_USE_ILBC)
129
-	MESSAGE(STATUS "Using bundled iLBC library: NO")
134
+	MESSAGE(STATUS "Uusing iLBC library: NO")
130 135
 ENDIF(SEMS_USE_ILBC)
131 136
 
132 137
 # build in support for monitoring?
Browse code

Search for possibly missing res_search

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 02/10/2010 13:54:11
Showing 1 changed files
... ...
@@ -229,6 +229,12 @@ ELSE(RTMP_FOUND)
229 229
 	MESSAGE(STATUS "Using librtmp: NO")
230 230
 ENDIF(RTMP_FOUND)
231 231
 
232
+# Check for res_search in -lresolv
233
+include(${CMAKE_SOURCE_DIR}/cmake/CheckSymbolExists.cmake)
234
+SET(CMAKE_REQUIRED_LIBRARIES resolv)
235
+CHECK_SYMBOL_EXISTS(res_search resolv.h HAVE_RES_SEARCH)
236
+MESSAGE(STATUS "Have res_search: ${HAVE_RES_SEARCH} ")
237
+
232 238
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/ampi)
233 239
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/amci)
234 240
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core)
Browse code

Updated version in CMakefile

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 03/08/2012 09:05:41
Showing 1 changed files
... ...
@@ -13,7 +13,7 @@ set( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
13 13
 PROJECT (SEMS)
14 14
 
15 15
 SET(SEMS_MAJOR_VERSION 1)
16
-SET(SEMS_MINOR_VERSION 5)
16
+SET(SEMS_MINOR_VERSION 6)
17 17
 SET(SEMS_BUILD_VERSION 0)
18 18
 SET(SEMS_EXTRA_VERSION dev)
19 19
 
Browse code

Add libzrtp support to the CMakeFile

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 05/04/2012 13:06:18
Showing 1 changed files
... ...
@@ -108,12 +108,10 @@ ENDIF(SEMS_USE_LIBSAMPLERATE)
108 108
 
109 109
 # ZRTP support? (see zfoneproject.com)
110 110
 IF(SEMS_USE_ZRTP)
111
-	# TODO
112
-	SET(ZRTP_FOUND TRUE)
111
+	FIND_PACKAGE(Libzrtp REQUIRED)
113 112
 	MESSAGE(STATUS "Using libzrtp: YES")
114 113
 	ADD_DEFINITIONS(-DWITH_ZRTP -DBUILD_ZRTP_MUTEXES -DBUILD_DEFAULT_CACHE -DBUILD_DEFAULT_TIMER -DUNIX -DBUILD_ZRTP_MUTEXES)
115 114
 ELSE(SEMS_USE_ZRTP)
116
-	SET(ZRTP_FOUND FALSE)
117 115
 	MESSAGE(STATUS "Using libzrtp: NO (default)")
118 116
 ENDIF(SEMS_USE_ZRTP)
119 117
 
Browse code

Move sems.h template to the core directory

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 16/02/2012 14:10:59
Showing 1 changed files
... ...
@@ -235,7 +235,7 @@ INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/ampi)
235 235
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/amci)
236 236
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core)
237 237
 
238
-CONFIGURE_FILE( sems.h.cmake ${SEMS_SOURCE_DIR}/core/sems.h )
238
+CONFIGURE_FILE( ${SEMS_SOURCE_DIR}/core/sems.h.cmake ${SEMS_SOURCE_DIR}/core/sems.h )
239 239
 
240 240
 IF(CMAKE_COMPILER_IS_GNUCC)
241 241
 	SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_THREAD_SAFE -D_REENTRANT -Wall -fPIC -g -O2")
Browse code

Add rtmp module to CMake buildsystem

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 29/11/2011 18:12:32
Showing 1 changed files
... ...
@@ -223,6 +223,13 @@ ELSE(LIBEV_FOUND)
223 223
 	MESSAGE(STATUS "Using libev: NO")
224 224
 ENDIF(LIBEV_FOUND)
225 225
 
226
+# Let's try to find librtmp development files
227
+FIND_PACKAGE(Librtmp)
228
+IF(RTMP_FOUND)
229
+	MESSAGE(STATUS "Using librtmp: YES")
230
+ELSE(RTMP_FOUND)
231
+	MESSAGE(STATUS "Using librtmp: NO")
232
+ENDIF(RTMP_FOUND)
226 233
 
227 234
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/ampi)
228 235
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/amci)
Browse code

Fix compiling with cmake on MacOSX

Tested-by: Peter Lemenkov <lemenkov@gmail.com>

Raphael Coeffic authored on 17/03/2011 11:24:20 • Peter Lemenkov committed on 17/03/2011 14:03:09
Showing 1 changed files
... ...
@@ -3,6 +3,7 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
3 3
 IF(COMMAND cmake_policy)
4 4
 	# Don't do automatic escaping of variables
5 5
 	CMAKE_POLICY(SET CMP0005 OLD)
6
+	CMAKE_POLICY(SET CMP0003 NEW)
6 7
 ENDIF(COMMAND cmake_policy)
7 8
 
8 9
 
Browse code

New version 1.5.0 in CMake-file

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 17/03/2011 11:15:29
Showing 1 changed files
... ...
@@ -12,7 +12,7 @@ set( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
12 12
 PROJECT (SEMS)
13 13
 
14 14
 SET(SEMS_MAJOR_VERSION 1)
15
-SET(SEMS_MINOR_VERSION 4)
15
+SET(SEMS_MINOR_VERSION 5)
16 16
 SET(SEMS_BUILD_VERSION 0)
17 17
 SET(SEMS_EXTRA_VERSION dev)
18 18
 
Browse code

added tools to CMake

Stefan Sayer authored on 02/03/2011 00:03:37
Showing 1 changed files
... ...
@@ -265,5 +265,6 @@ SET(CMAKE_SHARED_LIBRARY_PREFIX "")
265 265
 
266 266
 ADD_SUBDIRECTORY (core)
267 267
 ADD_SUBDIRECTORY (apps)
268
+ADD_SUBDIRECTORY (tools)
268 269
 
269 270
 #SET_DIRECTORY_PROPERTIES(ADDITIONAL_MAKE_CLEAN_FILES *~)
Browse code

Add more definitions to CMakefiles

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 11/02/2011 17:15:14
Showing 1 changed files
... ...
@@ -240,6 +240,27 @@ ENDIF(CMAKE_COMPILER_IS_GNUCXX)
240 240
 SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_DEBUG")
241 241
 SET(CMAKE_C_FLAGS_DEBUG   "${CMAKE_C_FLAGS_DEBUG}   -D_DEBUG")
242 242
 
243
+# compile with session thread pool support?
244
+#      use this for very high concurrent call count
245
+#      applications (e.g. for signaling only)
246
+#      if compiled with thread pool, there will be a
247
+#      thread pool of configurable size processing the
248
+#      signaling and application logic of the calls.
249
+#      if compiled without thread pool support, every
250
+#      session will have its own thread.
251
+#
252
+#ADD_DEFINITIONS(-DSESSION_THREADPOOL)
253
+
254
+#ADD_DEFINITIONS(-DNO_THREADID_LOG)
255
+#ADD_DEFINITIONS(-DLOG_LOC_DATA_ATEND)
256
+
257
+# Support for long debug messages? (useful for debugging SIP messages' contents)
258
+#
259
+# disable for slight performance gain
260
+ADD_DEFINITIONS(-DLOG_BUFFER_LEN=2048)
261
+
262
+#ADD_DEFINITIONS(-DDEBUG_PLAYOUTBUF)
263
+
243 264
 SET(CMAKE_SHARED_LIBRARY_PREFIX "")
244 265
 
245 266
 ADD_SUBDIRECTORY (core)
Browse code

Change version to 1.4.0 in CMake-file

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 08/02/2011 19:56:41
Showing 1 changed files
... ...
@@ -12,7 +12,7 @@ set( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
12 12
 PROJECT (SEMS)
13 13
 
14 14
 SET(SEMS_MAJOR_VERSION 1)
15
-SET(SEMS_MINOR_VERSION 3)
15
+SET(SEMS_MINOR_VERSION 4)
16 16
 SET(SEMS_BUILD_VERSION 0)
17 17
 SET(SEMS_EXTRA_VERSION dev)
18 18
 
Browse code

Move CMake defines

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 03/01/2011 19:16:24
Showing 1 changed files
... ...
@@ -89,6 +89,7 @@ SET(CMAKE_VERBOSE_MAKEFILE ON)
89 89
 #   (which means that current debian and gentoo packages don't work)
90 90
 IF(SEMS_USE_SPANDSP)
91 91
 	FIND_PACKAGE(Spandsp REQUIRED)
92
+	ADD_DEFINITIONS(-DUSE_SPANDSP -D__STDC_LIMIT_MACROS)
92 93
 	MESSAGE(STATUS "Using spandsp: YES")
93 94
 ELSE(SEMS_USE_SPANDSP)
94 95
 	MESSAGE(STATUS "Using spandsp: NO (default)")
... ...
@@ -98,6 +99,7 @@ ENDIF(SEMS_USE_SPANDSP)
98 99
 # (see http://www.mega-nerd.com/SRC/)
99 100
 IF(SEMS_USE_LIBSAMPLERATE)
100 101
 	FIND_PACKAGE(Libsamplerate REQUIRED)
102
+	ADD_DEFINITIONS(-DUSE_LIBSAMPLERATE)
101 103
 	MESSAGE(STATUS "Using libsamplerate: YES")
102 104
 ELSE(SEMS_USE_LIBSAMPLERATE)
103 105
 	MESSAGE(STATUS "Using libsamplerate: NO (default)")
... ...
@@ -137,6 +139,7 @@ ELSE(SEMS_USE_MONITORING)
137 139
 ENDIF(SEMS_USE_MONITORING)
138 140
 
139 141
 IF(SEMS_USE_IPV6)
142
+	ADD_DEFINITIONS(-DSUPPORT_IPV6)
140 143
 	MESSAGE(STATUS "Enable IPv6 support: YES")
141 144
 ELSE(SEMS_USE_IPV6)
142 145
 	MESSAGE(STATUS "Enable IPv6 support: NO (default)")
Browse code

Simplify checking whether we're buinding devel version or not

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 02/10/2010 18:01:43
Showing 1 changed files
... ...
@@ -16,14 +16,14 @@ SET(SEMS_MINOR_VERSION 3)
16 16
 SET(SEMS_BUILD_VERSION 0)
17 17
 SET(SEMS_EXTRA_VERSION dev)
18 18
 
19
-FIND_PATH(IS_DEVEL ".git" PATHS "${CMAKE_SOURCE_DIR}")
20
-IF(IS_DEVEL)
19
+IF(EXISTS ${CMAKE_SOURCE_DIR}/.git)
21 20
 	SET(SEMS_VERSION
22 21
 	    "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}-${SEMS_EXTRA_VERSION}")
23
-ELSE(IS_DEVEL)
22
+ELSE(EXISTS ${CMAKE_SOURCE_DIR}/.git)
24 23
 	SET(SEMS_VERSION
25 24
 	    "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}")
26
-ENDIF(IS_DEVEL)
25
+ENDIF(EXISTS ${CMAKE_SOURCE_DIR}/.git)
26
+
27 27
 MESSAGE(STATUS "Configuring ${CMAKE_PROJECT_NAME} v. ${SEMS_VERSION}")
28 28
 
29 29
 IF(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR AND NOT MSVC_IDE)
Browse code

Add jsonrpc module to CMake buildsystem

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 02/10/2010 10:25:27
Showing 1 changed files
... ...
@@ -211,6 +211,15 @@ ELSE(MISDN_FOUND)
211 211
 	MESSAGE(STATUS "Using mISDN: NO")
212 212
 ENDIF(MISDN_FOUND)
213 213
 
214
+# Let's try to find libev development files
215
+FIND_PACKAGE(Libev)
216
+IF(LIBEV_FOUND)
217
+	MESSAGE(STATUS "Using libev: YES")
218
+ELSE(LIBEV_FOUND)
219
+	MESSAGE(STATUS "Using libev: NO")
220
+ENDIF(LIBEV_FOUND)
221
+
222
+
214 223
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/ampi)
215 224
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/amci)
216 225
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core)
Browse code

Try to set CMake policy only if it allows that

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 02/10/2010 09:50:51
Showing 1 changed files
... ...
@@ -1,7 +1,10 @@
1 1
 CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
2 2
 
3
-# Don't do automatic escaping of variables
4
-CMAKE_POLICY(SET CMP0005 OLD)
3
+IF(COMMAND cmake_policy)
4
+	# Don't do automatic escaping of variables
5
+	CMAKE_POLICY(SET CMP0005 OLD)
6
+ENDIF(COMMAND cmake_policy)
7
+
5 8
 
6 9
 # Add path for additional FindXXX.cmake scenarios
7 10
 set( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
Browse code

Split SIp detection code into is own CMake module

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 02/10/2010 09:45:06
Showing 1 changed files
... ...
@@ -168,25 +168,20 @@ ENDIF(SEMS_USE_OPENSSL)
168 168
 FIND_PACKAGE(PythonLibs)
169 169
 IF(PYTHONLIBS_FOUND OR PYTHON_LIBRARIES)
170 170
 	SET(PYTHONLIBS_FOUND TRUE)
171
-	GET_FILENAME_COMPONENT(PYTHON_LD_PATH ${PYTHON_LIBRARIES} PATH)
172 171
 	MESSAGE(STATUS "Found Python includes:	${PYTHON_INCLUDE_PATH}/Python.h")
173 172
 	MESSAGE(STATUS "Found Python library: ${PYTHON_LIBRARIES}")
174
-	MESSAGE(STATUS "Found Python library path: ${PYTHON_LD_PATH}")
175 173
 	MESSAGE(STATUS "Using Python: YES")
176 174
 ELSE(PYTHONLIBS_FOUND OR PYTHON_LIBRARIES)
177 175
 	MESSAGE(STATUS "Using Python: NO")
178 176
 ENDIF(PYTHONLIBS_FOUND OR PYTHON_LIBRARIES)
179 177
 
180 178
 # Let's try to find SIP (Python bindings generator) development files
181
-FIND_PATH(SIP_INCLUDE_DIR sip.h PATHS ${PYTHON_INCLUDE_PATH})
182
-IF(SIP_INCLUDE_DIR)
183
-	SET(SIP_FOUND TRUE)
184
-	MESSAGE(STATUS "Found SIP includes:	${SIP_INCLUDE_DIR}/sip.h")
179
+FIND_PACKAGE(SIP)
180
+IF(SIP_FOUND)
185 181
 	MESSAGE(STATUS "Using SIP: YES")
186
-ELSE(SIP_INCLUDE_DIR)
187
-	SET(SIP_FOUND FALSE)
182
+ELSE(SIP_FOUND)
188 183
 	MESSAGE(STATUS "Using SIP: NO")
189
-ENDIF(SIP_INCLUDE_DIR)
184
+ENDIF(SIP_FOUND)
190 185
 
191 186
 # Let's try to find MySQL++ development files
192 187
 FIND_PACKAGE(MySQLpp)
Browse code

Use -dev suffix only for devel builds

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 02/10/2010 09:21:20
Showing 1 changed files
... ...
@@ -12,8 +12,16 @@ SET(SEMS_MAJOR_VERSION 1)
12 12
 SET(SEMS_MINOR_VERSION 3)
13 13
 SET(SEMS_BUILD_VERSION 0)
14 14
 SET(SEMS_EXTRA_VERSION dev)
15
-SET(SEMS_VERSION
16
-    "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}-${SEMS_EXTRA_VERSION}")
15
+
16
+FIND_PATH(IS_DEVEL ".git" PATHS "${CMAKE_SOURCE_DIR}")
17
+IF(IS_DEVEL)
18
+	SET(SEMS_VERSION
19
+	    "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}-${SEMS_EXTRA_VERSION}")
20
+ELSE(IS_DEVEL)
21
+	SET(SEMS_VERSION
22
+	    "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}")
23
+ENDIF(IS_DEVEL)
24
+MESSAGE(STATUS "Configuring ${CMAKE_PROJECT_NAME} v. ${SEMS_VERSION}")
17 25
 
18 26
 IF(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR AND NOT MSVC_IDE)
19 27
 	message(FATAL_ERROR "In-source builds are not allowed.
Browse code

Split off some library-specific search rules for CMake from main file

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

Peter Lemenkov authored on 02/10/2010 07:55:11
Showing 1 changed files
... ...
@@ -3,6 +3,9 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
3 3
 # Don't do automatic escaping of variables
4 4
 CMAKE_POLICY(SET CMP0005 OLD)
5 5
 
6
+# Add path for additional FindXXX.cmake scenarios
7
+set( CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
8
+
6 9
 PROJECT (SEMS)
7 10
 
8 11
 SET(SEMS_MAJOR_VERSION 1)
... ...
@@ -74,38 +77,18 @@ SET(CMAKE_VERBOSE_MAKEFILE ON)
74 77
 #   will not work with spandsp 0.0.2 .
75 78
 #   (which means that current debian and gentoo packages don't work)
76 79
 IF(SEMS_USE_SPANDSP)
77
-	FIND_LIBRARY(SPANDSP_LIBRARIES NAMES spandsp)
78
-	FIND_PATH(SPANDSP_INCLUDE_DIR spandsp.h)
79
-	IF(SPANDSP_INCLUDE_DIR AND SPANDSP_LIBRARIES)
80
-		SET(SPANDSP_FOUND TRUE)
81
-		MESSAGE(STATUS "Found spandsp includes:	${SPANDSP_INCLUDE_DIR}/spandsp.h")
82
-		MESSAGE(STATUS "Found spandsp library: ${SPANDSP_LIBRARIES}")
83
-		MESSAGE(STATUS "Using spandsp: YES")
84
-	ELSE(SPANDSP_INCLUDE_DIR AND SPANDSP_LIBRARIES)
85
-		SET(SPANDSP_FOUND FALSE)
86
-		MESSAGE(FATAL_ERROR "Could NOT find spandsp development files")
87
-	ENDIF(SPANDSP_INCLUDE_DIR AND SPANDSP_LIBRARIES)
80
+	FIND_PACKAGE(Spandsp REQUIRED)
81
+	MESSAGE(STATUS "Using spandsp: YES")
88 82
 ELSE(SEMS_USE_SPANDSP)
89
-	SET(SPANDSP_FOUND FALSE)
90 83
 	MESSAGE(STATUS "Using spandsp: NO (default)")
91 84
 ENDIF(SEMS_USE_SPANDSP)
92 85
 
93 86
 # compile with sample rate conversion from secret rabbit code?
94 87
 # (see http://www.mega-nerd.com/SRC/)
95 88
 IF(SEMS_USE_LIBSAMPLERATE)
96
-	FIND_LIBRARY(LIBSAMPLERATE_LIBRARIES NAMES samplerate)
97
-	FIND_PATH(LIBSAMPLERATE_INCLUDE_DIR samplerate.h)
98
-	IF(LIBSAMPLERATE_INCLUDE_DIR AND LIBSAMPLERATE_LIBRARIES)
99
-		SET(LIBSAMPLERATE_FOUND TRUE)
100
-		MESSAGE(STATUS "Found libsamplerate includes: ${LIBSAMPLERATE_INCLUDE_DIR}/samplerate.h")
101
-		MESSAGE(STATUS "Found libsamplerate library: ${LIBSAMPLERATE_LIBRARIES}")
102
-		MESSAGE(STATUS "Using libsamplerate: YES")
103
-	ELSE(LIBSAMPLERATE_INCLUDE_DIR AND LIBSAMPLERATE_LIBRARIES)
104
-		SET(LIBSAMPLERATE_FOUND FALSE)
105
-		MESSAGE(FATAL_ERROR "Could NOT find libsamplerate development files")
106
-	ENDIF(LIBSAMPLERATE_INCLUDE_DIR AND LIBSAMPLERATE_LIBRARIES)
89
+	FIND_PACKAGE(Libsamplerate REQUIRED)
90
+	MESSAGE(STATUS "Using libsamplerate: YES")
107 91
 ELSE(SEMS_USE_LIBSAMPLERATE)
108
-	SET(LIBSAMPLERATE_FOUND FALSE)
109 92
 	MESSAGE(STATUS "Using libsamplerate: NO (default)")
110 93
 ENDIF(SEMS_USE_LIBSAMPLERATE)
111 94
 
... ...
@@ -122,19 +105,9 @@ ENDIF(SEMS_USE_ZRTP)
122 105
 
123 106
 # Lame MP3 support
124 107
 IF(SEMS_USE_MP3)
125
-	FIND_LIBRARY(LAME_LIBRARIES NAMES mp3lame)
126
-	FIND_PATH(LAME_INCLUDE_DIR lame/lame.h)
127
-	IF(LAME_INCLUDE_DIR AND LAME_LIBRARIES)
128
-		SET(LAME_FOUND TRUE)
129
-		MESSAGE(STATUS "Found lame mp3 includes: ${LAME_INCLUDE_DIR}/lame/lame.h")
130
-		MESSAGE(STATUS "Found lame mp3 library: ${LAME_LIBRARIES}")
131
-		MESSAGE(STATUS "Using lame mp3: YES")
132
-	ELSE(LAME_INCLUDE_DIR AND LAME_LIBRARIES)
133
-		SET(LAME_FOUND FALSE)
134
-		MESSAGE(FATAL_ERROR "Could NOT find lame development files")
135
-	ENDIF(LAME_INCLUDE_DIR AND LAME_LIBRARIES)
108
+	FIND_PACKAGE(Lame REQUIRED)
109
+	MESSAGE(STATUS "Using lame mp3: YES")
136 110
 ELSE(SEMS_USE_MP3)
137
-	SET(LAME_FOUND FALSE)
138 111
 	MESSAGE(STATUS "Using lame mp3: NO (default)")
139 112
 ENDIF(SEMS_USE_MP3)
140 113
 
... ...
@@ -159,30 +132,20 @@ ELSE(SEMS_USE_IPV6)
159 132
 ENDIF(SEMS_USE_IPV6)
160 133
 
161 134
 # Let's try to find GSM library and header files
162
-FIND_LIBRARY(GSM_LIBRARIES NAMES gsm)
163
-FIND_PATH(GSM_INCLUDE_DIR gsm.h)
164
-IF(GSM_INCLUDE_DIR AND GSM_LIBRARIES)
165
-	SET(GSM_FOUND TRUE)
166
-	MESSAGE(STATUS "Found gsm includes: ${GSM_INCLUDE_DIR}/gsm.h")
167
-	MESSAGE(STATUS "Found gsm library: ${GSM_LIBRARIES}")
135
+FIND_PACKAGE(Gsm)
136
+IF(GSM_FOUND)
168 137
 	MESSAGE(STATUS "Using gsm: YES")
169
-ELSE(GSM_INCLUDE_DIR AND GSM_LIBRARIES)
170
-	SET(GSM_FOUND FALSE)
138
+ELSE(GSM_FOUND)
171 139
 	MESSAGE(STATUS "Using gsm: NO")
172
-ENDIF (GSM_INCLUDE_DIR AND GSM_LIBRARIES)
140
+ENDIF(GSM_FOUND)
173 141
 
174 142
 # Let's try to find SPEEX library and header files
175
-FIND_LIBRARY(SPEEX_LIBRARIES NAMES speex)
176
-FIND_PATH(SPEEX_INCLUDE_DIR speex/speex.h)
177
-IF(SPEEX_INCLUDE_DIR AND SPEEX_LIBRARIES)
178
-	SET(SPEEX_FOUND TRUE)
179
-	MESSAGE(STATUS "Found speex includes: ${SPEEX_INCLUDE_DIR}/speex/speex.h")
180
-	MESSAGE(STATUS "Found speex library: ${SPEEX_LIBRARIES}")
143
+FIND_PACKAGE(Speex)
144
+IF(SPEEX_FOUND)
181 145
 	MESSAGE(STATUS "Using speex: YES")
182
-ELSE(SPEEX_INCLUDE_DIR AND SPEEX_LIBRARIES)
183
-	SET(SPEEX_FOUND FALSE)
146
+ELSE(SPEEX_FOUND)
184 147
 	MESSAGE(STATUS "Using speex: NO")
185
-ENDIF (SPEEX_INCLUDE_DIR AND SPEEX_LIBRARIES)
148
+ENDIF(SPEEX_FOUND)
186 149
 
187 150
 IF(SEMS_USE_OPENSSL)
188 151
 	FIND_PACKAGE(OpenSSL REQUIRED QUIETLY)
... ...
@@ -218,48 +181,29 @@ ELSE(SIP_INCLUDE_DIR)
218 181
 ENDIF(SIP_INCLUDE_DIR)
219 182
 
220 183
 # Let's try to find MySQL++ development files
221
-FIND_LIBRARY(MYSQLPP_LIBRARIES NAMES mysqlpp)
222
-FIND_PATH(MYSQLPP_INCLUDE_DIR mysql++/mysql++.h)
223
-IF(MYSQLPP_INCLUDE_DIR AND MYSQLPP_LIBRARIES)
224
-	SET(MYSQLPP_FOUND TRUE)
225
-	MESSAGE(STATUS "Found MySQL++ includes:	${MYSQLPP_INCLUDE_DIR}/mysql++/mysql++.h")
226
-	MESSAGE(STATUS "Found MySQL++ library: ${MYSQLPP_LIBRARIES}")
184
+FIND_PACKAGE(MySQLpp)
185
+IF(MYSQLPP_FOUND)
227 186
 	MESSAGE(STATUS "Using MySQL++: YES")
228
-ELSE(MYSQLPP_INCLUDE_DIR AND MYSQLPP_LIBRARIES)
229
-	SET(MYSQLPP_FOUND FALSE)
187
+ELSE(MYSQLPP_FOUND)
230 188
 	MESSAGE(STATUS "Using MySQL++: NO")
231
-ENDIF(MYSQLPP_INCLUDE_DIR AND MYSQLPP_LIBRARIES)
189
+ENDIF(MYSQLPP_FOUND)
232 190
 
233 191
 # Let's try to find Flite library and header files
234 192
 IF(SEMS_USE_TTS)
235
-	FIND_LIBRARY(FLITE_LIBRARIES NAMES flite)
236
-	FIND_PATH(FLITE_INCLUDE_DIR flite/flite.h)
237
-	IF(FLITE_INCLUDE_DIR AND FLITE_LIBRARIES)
238
-		SET(FLITE_FOUND TRUE)
239
-		MESSAGE(STATUS "Found flite includes: ${FLITE_INCLUDE_DIR}/flite/flite.h")
240
-		MESSAGE(STATUS "Found flite library: ${FLITE_LIBRARIES}")
241
-		MESSAGE(STATUS "Using flite: YES")
242
-	ELSE(FLITE_INCLUDE_DIR AND FLITE_LIBRARIES)
243
-		SET(FLITE_FOUND FALSE)
244
-		MESSAGE(FATAL_ERROR "CANNOT find flite devel files")
245
-	ENDIF (FLITE_INCLUDE_DIR AND FLITE_LIBRARIES)
193
+	FIND_PACKAGE(Flite REQUIRED)
194
+	MESSAGE(STATUS "Using text-to-speech: YES")
246 195
 ELSE(SEMS_USE_TTS)
247 196
 	SET(FLITE_FOUND FALSE)
248 197
 	MESSAGE(STATUS "Using text-to-speech: NO (default)")
249 198
 ENDIF(SEMS_USE_TTS)
250 199
 
251 200
 # Let's try to find mISDN library and header files
252
-FIND_LIBRARY(MISDN_LIBRARIES NAMES mISDN)
253
-FIND_PATH(MISDN_INCLUDE_DIR mISDNuser/mISDNlib.h)
254
-IF(MISDN_INCLUDE_DIR AND MISDN_LIBRARIES)
255
-	SET(MISDN_FOUND TRUE)
256
-	MESSAGE(STATUS "Found mISDN includes: ${MISDN_INCLUDE_DIR}/mISDNuser/mISDNlib.h")
257
-	MESSAGE(STATUS "Found mISDN library: ${MISDN_LIBRARIES}")
201
+FIND_PACKAGE(MISDN)
202
+IF(MISDN_FOUND)
258 203
 	MESSAGE(STATUS "Using mISDN: YES")
259
-ELSE(MISDN_INCLUDE_DIR AND MISDN_LIBRARIES)
260
-	SET(MISDN_FOUND FALSE)
204
+ELSE(MISDN_FOUND)
261 205
 	MESSAGE(STATUS "Using mISDN: NO")
262
-ENDIF (MISDN_INCLUDE_DIR AND MISDN_LIBRARIES)
206
+ENDIF(MISDN_FOUND)
263 207
 
264 208
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/ampi)
265 209
 INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core/amci)
Browse code

Added workarounfd for weird behaviour of CMake 2.4 while handling static libs.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1951 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 02/06/2010 13:59:47
Showing 1 changed files
... ...
@@ -32,6 +32,12 @@ OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
32 32
 OPTION(SEMS_USE_IPV6          "Build with IPv6 support" OFF)
33 33
 OPTION(MAX_RTP_SESSIONS:int   "How many rtp sessions SEMS will handle simultaneously? (default 2048)" 2048)
34 34
 
35
+# Fix weird static libs handling in old CMake
36
+IF (${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} STREQUAL "2.4")
37
+	SET(SEMS_WORKAROUND_FOR_OLD_CMAKE_2_4_FOR_STATIC_LIBS  ON)
38
+ELSE (${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} STREQUAL "2.4")
39
+	SET(SEMS_WORKAROUND_FOR_OLD_CMAKE_2_4_FOR_STATIC_LIBS  OFF)
40
+ENDIF (${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} STREQUAL "2.4")
35 41
 
36 42
 # add -lm and -lpthread to all targets
37 43
 SET(CMAKE_DL_LIBS ${CMAKE_DL_LIBS} m pthread)
Browse code

Fix newest variables escaping strategy on new CMake

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1949 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 02/06/2010 13:13:04
Showing 1 changed files
... ...
@@ -1,5 +1,8 @@
1 1
 CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
2 2
 
3
+# Don't do automatic escaping of variables
4
+CMAKE_POLICY(SET CMP0005 OLD)
5
+
3 6
 PROJECT (SEMS)
4 7
 
5 8
 SET(SEMS_MAJOR_VERSION 1)
Browse code

Since now, sems can be compiled with older CMake (except few modules). Thus we need to lower required CMake version.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1923 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 19/05/2010 09:52:17
Showing 1 changed files
... ...
@@ -1,4 +1,4 @@
1
-CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
1
+CMAKE_MINIMUM_REQUIRED(VERSION 2.4)
2 2
 
3 3
 PROJECT (SEMS)
4 4
 
Browse code

Old CMake doesn't set PYTHONLIBS_FOUND variable

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1773 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 02/04/2010 13:03:39
Showing 1 changed files
... ...
@@ -186,15 +186,16 @@ ENDIF(SEMS_USE_OPENSSL)
186 186
 
187 187
 # Let's try to find Python development files
188 188
 FIND_PACKAGE(PythonLibs)
189
-IF(PYTHONLIBS_FOUND)
189
+IF(PYTHONLIBS_FOUND OR PYTHON_LIBRARIES)
190
+	SET(PYTHONLIBS_FOUND TRUE)
190 191
 	GET_FILENAME_COMPONENT(PYTHON_LD_PATH ${PYTHON_LIBRARIES} PATH)
191 192
 	MESSAGE(STATUS "Found Python includes:	${PYTHON_INCLUDE_PATH}/Python.h")
192 193
 	MESSAGE(STATUS "Found Python library: ${PYTHON_LIBRARIES}")
193 194
 	MESSAGE(STATUS "Found Python library path: ${PYTHON_LD_PATH}")
194 195
 	MESSAGE(STATUS "Using Python: YES")
195
-ELSE(PYTHONLIBS_FOUND)
196
+ELSE(PYTHONLIBS_FOUND OR PYTHON_LIBRARIES)
196 197
 	MESSAGE(STATUS "Using Python: NO")
197
-ENDIF(PYTHONLIBS_FOUND)
198
+ENDIF(PYTHONLIBS_FOUND OR PYTHON_LIBRARIES)
198 199
 
199 200
 # Let's try to find SIP (Python bindings generator) development files
200 201
 FIND_PATH(SIP_INCLUDE_DIR sip.h PATHS ${PYTHON_INCLUDE_PATH})
Browse code

Fix search paths for LAME includes.

Signed-off-by: Самусенко Андрей <samusenko@msm.ru>
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1748 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 01/04/2010 09:00:04
Showing 1 changed files
... ...
@@ -114,10 +114,10 @@ ENDIF(SEMS_USE_ZRTP)
114 114
 # Lame MP3 support
115 115
 IF(SEMS_USE_MP3)
116 116
 	FIND_LIBRARY(LAME_LIBRARIES NAMES mp3lame)
117
-	FIND_PATH(LAME_INCLUDE_DIR lame.h)
117
+	FIND_PATH(LAME_INCLUDE_DIR lame/lame.h)
118 118
 	IF(LAME_INCLUDE_DIR AND LAME_LIBRARIES)
119 119
 		SET(LAME_FOUND TRUE)
120
-		MESSAGE(STATUS "Found lame mp3 includes: ${LAME_INCLUDE_DIR}/lame.h")
120
+		MESSAGE(STATUS "Found lame mp3 includes: ${LAME_INCLUDE_DIR}/lame/lame.h")
121 121
 		MESSAGE(STATUS "Found lame mp3 library: ${LAME_LIBRARIES}")
122 122
 		MESSAGE(STATUS "Using lame mp3: YES")
123 123
 	ELSE(LAME_INCLUDE_DIR AND LAME_LIBRARIES)
Browse code

Fix typo in code, which performs searches for LAME mp3 library.

Signed-off-by: Самусенко Андрей <samusenko@msm.ru>
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1747 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 01/04/2010 08:51:23
Showing 1 changed files
... ...
@@ -112,7 +112,7 @@ ELSE(SEMS_USE_ZRTP)
112 112
 ENDIF(SEMS_USE_ZRTP)
113 113
 
114 114
 # Lame MP3 support
115
-IF(SEMS_USE_LAME)
115
+IF(SEMS_USE_MP3)
116 116
 	FIND_LIBRARY(LAME_LIBRARIES NAMES mp3lame)
117 117
 	FIND_PATH(LAME_INCLUDE_DIR lame.h)
118 118
 	IF(LAME_INCLUDE_DIR AND LAME_LIBRARIES)
... ...
@@ -124,10 +124,10 @@ IF(SEMS_USE_LAME)
124 124
 		SET(LAME_FOUND FALSE)
125 125
 		MESSAGE(FATAL_ERROR "Could NOT find lame development files")
126 126
 	ENDIF(LAME_INCLUDE_DIR AND LAME_LIBRARIES)
127
-ELSE(SEMS_USE_LAME)
127
+ELSE(SEMS_USE_MP3)
128 128
 	SET(LAME_FOUND FALSE)
129 129
 	MESSAGE(STATUS "Using lame mp3: NO (default)")
130
-ENDIF(SEMS_USE_LAME)
130
+ENDIF(SEMS_USE_MP3)
131 131
 
132 132
 IF(SEMS_USE_ILBC)
133 133
 	MESSAGE(STATUS "Using bundled iLBC library: YES (default)")
Browse code

Add condition for building iLBC support.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1743 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 31/03/2010 15:14:03
Showing 1 changed files
... ...
@@ -22,6 +22,7 @@ OPTION(SEMS_USE_SPANDSP       "Build with spandsp" OFF)
22 22
 OPTION(SEMS_USE_LIBSAMPLERATE "Build with libsamplerate" OFF)
23 23
 OPTION(SEMS_USE_ZRTP          "Build with ZRTP" OFF)
24 24
 OPTION(SEMS_USE_MP3           "Build with Lame MP3" OFF)
25
+OPTION(SEMS_USE_ILBC          "Build with bundled iLBC library" ON)
25 26
 OPTION(SEMS_USE_TTS           "Build with Text-to-speech support (requires Flite)" OFF)
26 27
 OPTION(SEMS_USE_OPENSSL       "Build with OpenSSL" OFF)
27 28
 OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
... ...
@@ -128,6 +129,12 @@ ELSE(SEMS_USE_LAME)
128 129
 	MESSAGE(STATUS "Using lame mp3: NO (default)")
129 130
 ENDIF(SEMS_USE_LAME)
130 131
 
132
+IF(SEMS_USE_ILBC)
133
+	MESSAGE(STATUS "Using bundled iLBC library: YES (default)")
134
+ELSE(SEMS_USE_ILBC)
135
+	MESSAGE(STATUS "Using bundled iLBC library: NO")
136
+ENDIF(SEMS_USE_ILBC)
137
+
131 138
 # build in support for monitoring?
132 139
 IF(SEMS_USE_MONITORING)
133 140
 	MESSAGE(STATUS "Enable monitoring: YES")
Browse code

Adjust SEMS version in CMake files

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1733 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 31/03/2010 07:47:08
Showing 1 changed files
... ...
@@ -3,8 +3,8 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
3 3
 PROJECT (SEMS)
4 4
 
5 5
 SET(SEMS_MAJOR_VERSION 1)
6
-SET(SEMS_MINOR_VERSION 1)
7
-SET(SEMS_BUILD_VERSION 1)
6
+SET(SEMS_MINOR_VERSION 3)
7
+SET(SEMS_BUILD_VERSION 0)
8 8
 SET(SEMS_EXTRA_VERSION dev)
9 9
 SET(SEMS_VERSION
10 10
     "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}-${SEMS_EXTRA_VERSION}")
Browse code

- Fixed linking against python.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1529 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 12/10/2009 18:44:59
Showing 1 changed files
... ...
@@ -180,8 +180,10 @@ ENDIF(SEMS_USE_OPENSSL)
180 180
 # Let's try to find Python development files
181 181
 FIND_PACKAGE(PythonLibs)
182 182
 IF(PYTHONLIBS_FOUND)
183
+	GET_FILENAME_COMPONENT(PYTHON_LD_PATH ${PYTHON_LIBRARIES} PATH)
183 184
 	MESSAGE(STATUS "Found Python includes:	${PYTHON_INCLUDE_PATH}/Python.h")
184 185
 	MESSAGE(STATUS "Found Python library: ${PYTHON_LIBRARIES}")
186
+	MESSAGE(STATUS "Found Python library path: ${PYTHON_LD_PATH}")
185 187
 	MESSAGE(STATUS "Using Python: YES")
186 188
 ELSE(PYTHONLIBS_FOUND)
187 189
 	MESSAGE(STATUS "Using Python: NO")
Browse code

- Rules for installation of ivr modules were added.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1524 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 11/10/2009 15:07:25
Showing 1 changed files
... ...
@@ -188,15 +188,15 @@ ELSE(PYTHONLIBS_FOUND)
188 188
 ENDIF(PYTHONLIBS_FOUND)
189 189
 
190 190
 # Let's try to find SIP (Python bindings generator) development files
191
-#FIND_PATH(SIP_INCLUDE_DIR sip.h)
192
-#IF(SIP_INCLUDE_DIR)
193
-#	SET(SIP_FOUND TRUE)
194
-#	MESSAGE(STATUS "Found SIP includes:	${SIP_INCLUDE_DIR}/sip.h")
195
-#	MESSAGE(STATUS "Using SIP: YES")
196
-#ELSE(SIP_INCLUDE_DIR)
197
-#	SET(SIP_FOUND FALSE)
198
-#	MESSAGE(STATUS "Using SIP: NO")
199
-#ENDIF(SIP_INCLUDE_DIR)
191
+FIND_PATH(SIP_INCLUDE_DIR sip.h PATHS ${PYTHON_INCLUDE_PATH})
192
+IF(SIP_INCLUDE_DIR)
193
+	SET(SIP_FOUND TRUE)
194
+	MESSAGE(STATUS "Found SIP includes:	${SIP_INCLUDE_DIR}/sip.h")
195
+	MESSAGE(STATUS "Using SIP: YES")
196
+ELSE(SIP_INCLUDE_DIR)
197
+	SET(SIP_FOUND FALSE)
198
+	MESSAGE(STATUS "Using SIP: NO")
199
+ENDIF(SIP_INCLUDE_DIR)
200 200
 
201 201
 # Let's try to find MySQL++ development files
202 202
 FIND_LIBRARY(MYSQLPP_LIBRARIES NAMES mysqlpp)
Browse code

- Reflect correct version.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1523 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 11/10/2009 10:56:28
Showing 1 changed files
... ...
@@ -4,7 +4,7 @@ PROJECT (SEMS)
4 4
 
5 5
 SET(SEMS_MAJOR_VERSION 1)
6 6
 SET(SEMS_MINOR_VERSION 1)
7
-SET(SEMS_BUILD_VERSION 0)
7
+SET(SEMS_BUILD_VERSION 1)
8 8
 SET(SEMS_EXTRA_VERSION dev)
9 9
 SET(SEMS_VERSION
10 10
     "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}-${SEMS_EXTRA_VERSION}")
Browse code

- Added installation of doc-files.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1522 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 11/10/2009 10:49:59
Showing 1 changed files
... ...
@@ -52,6 +52,11 @@ IF (NOT SEMS_LIBDIR)
52 52
 ENDIF (NOT SEMS_LIBDIR)
53 53
 MESSAGE(STATUS "SEMS libdir was set to: ${SEMS_LIBDIR}")
54 54
 
55
+IF (NOT SEMS_DOC_PREFIX)
56
+	SET(SEMS_DOC_PREFIX "/usr/share/doc")
57
+ENDIF (NOT SEMS_DOC_PREFIX)
58
+MESSAGE(STATUS "SEMS doc prefix was set to: ${SEMS_DOC_PREFIX}")
59
+
55 60
 SET(CMAKE_VERBOSE_MAKEFILE ON)
56 61
 
57 62
 # compile with spandsp DTMF detection? see soft-switch.org
Browse code

-Wno-reorder option is not valid for pure C

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1512 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 09/10/2009 14:34:09
Showing 1 changed files
... ...
@@ -244,7 +244,7 @@ INCLUDE_DIRECTORIES (${SEMS_SOURCE_DIR}/core)
244 244
 CONFIGURE_FILE( sems.h.cmake ${SEMS_SOURCE_DIR}/core/sems.h )
245 245
 
246 246
 IF(CMAKE_COMPILER_IS_GNUCC)
247
-	SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_THREAD_SAFE -D_REENTRANT -Wall -Wno-reorder -fPIC -g -O2")
247
+	SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_THREAD_SAFE -D_REENTRANT -Wall -fPIC -g -O2")
248 248
 ENDIF(CMAKE_COMPILER_IS_GNUCC)
249 249
 
250 250
 IF(CMAKE_COMPILER_IS_GNUCXX)
Browse code

- Simplified CMake files for building libraries and plugins. - Ability to override installation directories.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1509 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 08/10/2009 14:39:02
Showing 1 changed files
... ...
@@ -28,26 +28,29 @@ OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
28 28
 OPTION(SEMS_USE_IPV6          "Build with IPv6 support" OFF)
29 29
 OPTION(MAX_RTP_SESSIONS:int   "How many rtp sessions SEMS will handle simultaneously? (default 2048)" 2048)
30 30
 
31
-OPTION(SEMS_CFG_PREFIX:string  "none" /usr/local)
32
-OPTION(SEMS_AUDIO_PREFIX:string "none" /usr/local)
33
-OPTION(SEMS_EXEC_PREFIX:string "none" /usr/local)
34
-OPTION(SEMS_LIBDIR:string "none" lib)
31
+
32
+# add -lm and -lpthread to all targets
33
+SET(CMAKE_DL_LIBS ${CMAKE_DL_LIBS} m pthread)
35 34
 
36 35
 IF (NOT SEMS_CFG_PREFIX)
37 36
 	SET(SEMS_CFG_PREFIX "/usr/local")
38 37
 ENDIF (NOT SEMS_CFG_PREFIX)
38
+MESSAGE(STATUS "SEMS cfg prefix was set to: ${SEMS_CFG_PREFIX}")
39 39
 
40 40
 IF (NOT SEMS_AUDIO_PREFIX)
41
-	SET(SEMS_AUDIO_PREFIX "/usr/local")
41
+	SET(SEMS_AUDIO_PREFIX "/usr/local/lib")
42 42
 ENDIF (NOT SEMS_AUDIO_PREFIX)
43
+MESSAGE(STATUS "SEMS audio prefix was set to: ${SEMS_AUDIO_PREFIX}")
43 44
 
44 45
 IF (NOT SEMS_EXEC_PREFIX)
45 46
 	SET(SEMS_EXEC_PREFIX "/usr/local")
46 47
 ENDIF (NOT SEMS_EXEC_PREFIX)
48
+MESSAGE(STATUS "SEMS exec prefix was set to: ${SEMS_EXEC_PREFIX}")
47 49
 
48 50
 IF (NOT SEMS_LIBDIR)
49 51
 	SET(SEMS_LIBDIR "lib")
50 52
 ENDIF (NOT SEMS_LIBDIR)
53
+MESSAGE(STATUS "SEMS libdir was set to: ${SEMS_LIBDIR}")
51 54
 
52 55
 SET(CMAKE_VERBOSE_MAKEFILE ON)
53 56
 
... ...
@@ -149,10 +152,10 @@ ENDIF (GSM_INCLUDE_DIR AND GSM_LIBRARIES)
149 152
 
150 153
 # Let's try to find SPEEX library and header files
151 154
 FIND_LIBRARY(SPEEX_LIBRARIES NAMES speex)
152
-FIND_PATH(SPEEX_INCLUDE_DIR speex.h)
155
+FIND_PATH(SPEEX_INCLUDE_DIR speex/speex.h)
153 156
 IF(SPEEX_INCLUDE_DIR AND SPEEX_LIBRARIES)
154 157
 	SET(SPEEX_FOUND TRUE)
155
-	MESSAGE(STATUS "Found speex includes: ${SPEEX_INCLUDE_DIR}/speex.h")
158
+	MESSAGE(STATUS "Found speex includes: ${SPEEX_INCLUDE_DIR}/speex/speex.h")
156 159
 	MESSAGE(STATUS "Found speex library: ${SPEEX_LIBRARIES}")
157 160
 	MESSAGE(STATUS "Using speex: YES")
158 161
 ELSE(SPEEX_INCLUDE_DIR AND SPEEX_LIBRARIES)
Browse code

prepare for install target (started adding necessary variables)

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1503 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 15/09/2009 15:13:47
Showing 1 changed files
... ...
@@ -28,6 +28,27 @@ OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
28 28
 OPTION(SEMS_USE_IPV6          "Build with IPv6 support" OFF)
29 29
 OPTION(MAX_RTP_SESSIONS:int   "How many rtp sessions SEMS will handle simultaneously? (default 2048)" 2048)
30 30
 
31
+OPTION(SEMS_CFG_PREFIX:string  "none" /usr/local)
32
+OPTION(SEMS_AUDIO_PREFIX:string "none" /usr/local)
33
+OPTION(SEMS_EXEC_PREFIX:string "none" /usr/local)
34
+OPTION(SEMS_LIBDIR:string "none" lib)
35
+
36
+IF (NOT SEMS_CFG_PREFIX)
37
+	SET(SEMS_CFG_PREFIX "/usr/local")
38
+ENDIF (NOT SEMS_CFG_PREFIX)
39
+
40
+IF (NOT SEMS_AUDIO_PREFIX)
41
+	SET(SEMS_AUDIO_PREFIX "/usr/local")
42
+ENDIF (NOT SEMS_AUDIO_PREFIX)
43
+
44
+IF (NOT SEMS_EXEC_PREFIX)
45
+	SET(SEMS_EXEC_PREFIX "/usr/local")
46
+ENDIF (NOT SEMS_EXEC_PREFIX)
47
+
48
+IF (NOT SEMS_LIBDIR)
49
+	SET(SEMS_LIBDIR "lib")
50
+ENDIF (NOT SEMS_LIBDIR)
51
+
31 52
 SET(CMAKE_VERBOSE_MAKEFILE ON)
32 53
 
33 54
 # compile with spandsp DTMF detection? see soft-switch.org
Browse code

Use ADD_DEFINITIONS directive instead of naive checks for compiler

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1499 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 15/09/2009 13:53:01
Showing 1 changed files
... ...
@@ -72,10 +72,10 @@ ENDIF(SEMS_USE_LIBSAMPLERATE)
72 72
 
73 73
 # ZRTP support? (see zfoneproject.com)
74 74
 IF(SEMS_USE_ZRTP)
75
+	# TODO
75 76
 	SET(ZRTP_FOUND TRUE)
76 77
 	MESSAGE(STATUS "Using libzrtp: YES")
77
-	SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DWITH_ZRTP -DBUILD_ZRTP_MUTEXES -DBUILD_DEFAULT_CACHE -DBUILD_DEFAULT_TIMER -DUNIX -DBUILD_ZRTP_MUTEXES")
78
-	SET(CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -DWITH_ZRTP -DBUILD_ZRTP_MUTEXES -DBUILD_DEFAULT_CACHE -DBUILD_DEFAULT_TIMER -DUNIX -DBUILD_ZRTP_MUTEXES")
78
+	ADD_DEFINITIONS(-DWITH_ZRTP -DBUILD_ZRTP_MUTEXES -DBUILD_DEFAULT_CACHE -DBUILD_DEFAULT_TIMER -DUNIX -DBUILD_ZRTP_MUTEXES)
79 79
 ELSE(SEMS_USE_ZRTP)
80 80
 	SET(ZRTP_FOUND FALSE)
81 81
 	MESSAGE(STATUS "Using libzrtp: NO (default)")
... ...
@@ -102,8 +102,7 @@ ENDIF(SEMS_USE_LAME)
102 102
 # build in support for monitoring?
103 103
 IF(SEMS_USE_MONITORING)
104 104
 	MESSAGE(STATUS "Enable monitoring: YES")
105
-	SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DUSE_MONITORING")
106
-	SET(CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -DUSE_MONITORING")
105
+	ADD_DEFINITIONS(-DUSE_MONITORING)
107 106
 ELSE(SEMS_USE_MONITORING)
108 107
 	MESSAGE(STATUS "Enable monitoring: NO (default)")
109 108
 ENDIF(SEMS_USE_MONITORING)
Browse code

set CMAKE_SHARED_LIBRARY_PREFIX globally

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1495 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 15/09/2009 11:52:02
Showing 1 changed files
... ...
@@ -231,6 +231,7 @@ ENDIF(CMAKE_COMPILER_IS_GNUCXX)
231 231
 SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_DEBUG")
232 232
 SET(CMAKE_C_FLAGS_DEBUG   "${CMAKE_C_FLAGS_DEBUG}   -D_DEBUG")
233 233
 
234
+SET(CMAKE_SHARED_LIBRARY_PREFIX "")
234 235
 
235 236
 ADD_SUBDIRECTORY (core)
236 237
 ADD_SUBDIRECTORY (apps)
Browse code

cosmetic change in CMakeLists.txt

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1384 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 15/05/2009 14:10:37
Showing 1 changed files
... ...
@@ -26,7 +26,7 @@ OPTION(SEMS_USE_TTS           "Build with Text-to-speech support (requires Flite
26 26
 OPTION(SEMS_USE_OPENSSL       "Build with OpenSSL" OFF)
27 27
 OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
28 28
 OPTION(SEMS_USE_IPV6          "Build with IPv6 support" OFF)
29
-OPTION(MAX_RTP_SESSIONS:int "How many rtp sessions sSEMS will handle simultaneously? (default 2048)" 2048)
29
+OPTION(MAX_RTP_SESSIONS:int   "How many rtp sessions SEMS will handle simultaneously? (default 2048)" 2048)
30 30
 
31 31
 SET(CMAKE_VERBOSE_MAKEFILE ON)
32 32
 
Browse code

Added option to control maximum simultaneous number of rtp-sessions

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1383 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 14/05/2009 13:50:41
Showing 1 changed files
... ...
@@ -26,6 +26,7 @@ OPTION(SEMS_USE_TTS           "Build with Text-to-speech support (requires Flite
26 26
 OPTION(SEMS_USE_OPENSSL       "Build with OpenSSL" OFF)
27 27
 OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
28 28
 OPTION(SEMS_USE_IPV6          "Build with IPv6 support" OFF)
29
+OPTION(MAX_RTP_SESSIONS:int "How many rtp sessions sSEMS will handle simultaneously? (default 2048)" 2048)
29 30
 
30 31
 SET(CMAKE_VERBOSE_MAKEFILE ON)
31 32
 
Browse code

- Removed obsoleted option (support for OpenSER) - Moved some cflags to proper places

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1382 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 14/05/2009 13:15:17
Showing 1 changed files
... ...
@@ -25,7 +25,6 @@ OPTION(SEMS_USE_MP3           "Build with Lame MP3" OFF)
25 25
 OPTION(SEMS_USE_TTS           "Build with Text-to-speech support (requires Flite)" OFF)
26 26
 OPTION(SEMS_USE_OPENSSL       "Build with OpenSSL" OFF)
27 27
 OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
28
-OPTION(SEMS_USE_OPENSER       "Build with OpenSER support" OFF)
29 28
 OPTION(SEMS_USE_IPV6          "Build with IPv6 support" OFF)
30 29
 
31 30
 SET(CMAKE_VERBOSE_MAKEFILE ON)
... ...
@@ -108,18 +107,8 @@ ELSE(SEMS_USE_MONITORING)
108 107
 	MESSAGE(STATUS "Enable monitoring: NO (default)")
109 108
 ENDIF(SEMS_USE_MONITORING)
110 109
 
111
-IF(SEMS_USE_OPENSER)
112
-	MESSAGE(STATUS "Enable OpenSER support: YES")
113
-	SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DOpenSER")
114
-	SET(CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -DOpenSER")
115
-ELSE(SEMS_USE_OPENSER)
116
-	MESSAGE(STATUS "Enable OpenSER support: NO (default)")
117
-ENDIF(SEMS_USE_OPENSER)
118
-
119 110
 IF(SEMS_USE_IPV6)
120 111
 	MESSAGE(STATUS "Enable IPv6 support: YES")
121
-	SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DSUPPORT_IPV6")
122
-	SET(CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -DSUPPORT_IPV6")
123 112
 ELSE(SEMS_USE_IPV6)
124 113
 	MESSAGE(STATUS "Enable IPv6 support: NO (default)")
125 114
 ENDIF(SEMS_USE_IPV6)
Browse code

Some cleanups. Since not, core module will be linked against samplerate and misdn (if enabled)

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1381 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 13/05/2009 11:26:55
Showing 1 changed files
... ...
@@ -41,8 +41,6 @@ IF(SEMS_USE_SPANDSP)
41 41
 		SET(SPANDSP_FOUND TRUE)
42 42
 		MESSAGE(STATUS "Found spandsp includes:	${SPANDSP_INCLUDE_DIR}/spandsp.h")
43 43
 		MESSAGE(STATUS "Found spandsp library: ${SPANDSP_LIBRARIES}")
44
-		SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DUSE_SPANDSP -D__STDC_LIMIT_MACROS")
45
-		SET(CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -DUSE_SPANDSP -D__STDC_LIMIT_MACROS")
46 44
 		MESSAGE(STATUS "Using spandsp: YES")
47 45
 	ELSE(SPANDSP_INCLUDE_DIR AND SPANDSP_LIBRARIES)
48 46
 		SET(SPANDSP_FOUND FALSE)
... ...
@@ -62,8 +60,6 @@ IF(SEMS_USE_LIBSAMPLERATE)
62 60
 		SET(LIBSAMPLERATE_FOUND TRUE)
63 61
 		MESSAGE(STATUS "Found libsamplerate includes: ${LIBSAMPLERATE_INCLUDE_DIR}/samplerate.h")
64 62
 		MESSAGE(STATUS "Found libsamplerate library: ${LIBSAMPLERATE_LIBRARIES}")
65
-		SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DUSE_LIBSAMPLERATE")
66
-		SET(CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -DUSE_LIBSAMPLERATE")
67 63
 		MESSAGE(STATUS "Using libsamplerate: YES")
68 64
 	ELSE(LIBSAMPLERATE_INCLUDE_DIR AND LIBSAMPLERATE_LIBRARIES)
69 65
 		SET(LIBSAMPLERATE_FOUND FALSE)
Browse code

added warning about CMake and rewriting makefiles

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1380 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 12/05/2009 09:56:54
Showing 1 changed files
... ...
@@ -9,6 +9,15 @@ SET(SEMS_EXTRA_VERSION dev)
9 9
 SET(SEMS_VERSION
10 10
     "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}-${SEMS_EXTRA_VERSION}")
11 11
 
12
+IF(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR AND NOT MSVC_IDE)
13
+	message(FATAL_ERROR "In-source builds are not allowed.
14
+CMake would overwrite all makefiles distributed with SEMS.
15
+Please create a directory and run cmake from there, passing the path
16
+to this source directory as the last argument.
17
+This process created the file `CMakeCache.txt' and the directory `CMakeFiles'.
18
+Please delete them.")
19
+ENDIF(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR AND NOT MSVC_IDE)
20
+
12 21
 OPTION(SEMS_USE_SPANDSP       "Build with spandsp" OFF)
13 22
 OPTION(SEMS_USE_LIBSAMPLERATE "Build with libsamplerate" OFF)
14 23
 OPTION(SEMS_USE_ZRTP          "Build with ZRTP" OFF)
Browse code

initial commit of cmake files

git-svn-id: http://svn.berlios.de/svnroot/repos/sems/trunk@1373 8eb893ce-cfd4-0310-b710-fb5ebe64c474

Peter Lemenkov authored on 08/05/2009 08:10:05
Showing 1 changed files
... ...
@@ -12,41 +12,225 @@ SET(SEMS_VERSION
12 12
 OPTION(SEMS_USE_SPANDSP       "Build with spandsp" OFF)
13 13
 OPTION(SEMS_USE_LIBSAMPLERATE "Build with libsamplerate" OFF)
14 14
 OPTION(SEMS_USE_ZRTP          "Build with ZRTP" OFF)
15
+OPTION(SEMS_USE_MP3           "Build with Lame MP3" OFF)
16
+OPTION(SEMS_USE_TTS           "Build with Text-to-speech support (requires Flite)" OFF)
17
+OPTION(SEMS_USE_OPENSSL       "Build with OpenSSL" OFF)
15 18
 OPTION(SEMS_USE_MONITORING    "Build with monitoring support" OFF)
19
+OPTION(SEMS_USE_OPENSER       "Build with OpenSER support" OFF)
20
+OPTION(SEMS_USE_IPV6          "Build with IPv6 support" OFF)
16 21
 
22
+SET(CMAKE_VERBOSE_MAKEFILE ON)
23
+
24
+# compile with spandsp DTMF detection? see soft-switch.org
25
+#   this needs a fairly new version of spandsp - tested with 0.0.4pre11
26
+#   will not work with spandsp 0.0.2 .
27
+#   (which means that current debian and gentoo packages don't work)
17 28
 IF(SEMS_USE_SPANDSP)
18
-  SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DUSE_SPANDSP -D__STDC_LIMIT_MACROS")
19
-  SET(CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -DUSE_SPANDSP -D__STDC_LIMIT_MACROS")
29
+	FIND_LIBRARY(SPANDSP_LIBRARIES NAMES spandsp)
30
+	FIND_PATH(SPANDSP_INCLUDE_DIR spandsp.h)
31
+	IF(SPANDSP_INCLUDE_DIR AND SPANDSP_LIBRARIES)
32
+		SET(SPANDSP_FOUND TRUE)
33
+		MESSAGE(STATUS "Found spandsp includes:	${SPANDSP_INCLUDE_DIR}/spandsp.h")
34
+		MESSAGE(STATUS "Found spandsp library: ${SPANDSP_LIBRARIES}")
35
+		SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DUSE_SPANDSP -D__STDC_LIMIT_MACROS")
36
+		SET(CMAKE_C_FLAGS   "${CMAKE_C_FLAGS}   -DUSE_SPANDSP -D__STDC_LIMIT_MACROS")
37
+		MESSAGE(STATUS "Using spandsp: YES")
38
+	ELSE(SPANDSP_INCLUDE_DIR AND SPANDSP_LIBRARIES)
39
+		SET(SPANDSP_FOUND FALSE)
40
+		MESSAGE(FATAL_ERROR "Could NOT find spandsp development files")
41
+	ENDIF(SPANDSP_INCLUDE_DIR AND SPANDSP_LIBRARIES)
42
+ELSE(SEMS_USE_SPANDSP)
43