ba58279
From: Peter Lemenkov <lemenkov@gmail.com>
ba58279
Date: Wed, 17 Jun 2015 13:46:04 +0300
ba58279
Subject: [PATCH] Update configs
ba58279
ba58279
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
ba58279
ba58279
diff --git a/CMakeLists.txt b/CMakeLists.txt
ba58279
index d098fc4..71cacc5 100644
ba58279
--- a/CMakeLists.txt
ba58279
+++ b/CMakeLists.txt
ba58279
@@ -25,9 +25,14 @@ ELSE(EXISTS ${CMAKE_SOURCE_DIR}/.git)
ba58279
 	    "${SEMS_MAJOR_VERSION}.${SEMS_MINOR_VERSION}.${SEMS_BUILD_VERSION}")
ba58279
 ENDIF(EXISTS ${CMAKE_SOURCE_DIR}/.git)
ba58279
 
ba58279
-MESSAGE(STATUS "Configuring ${CMAKE_PROJECT_NAME} v. ${SEMS_VERSION}")
ba58279
+ADD_DEFINITIONS(-DSEMS_VERSION=\\\"${SEMS_VERSION}\\\")
ba58279
+ADD_DEFINITIONS(-DARCH=\\\"${CMAKE_SYSTEM_PROCESSOR}\\\")
ba58279
+ADD_DEFINITIONS(-DOS=\\\"${CMAKE_SYSTEM_NAME}\\\")
ba58279
+
ba58279
+ADD_DEFINITIONS(-DSYSTEM_SAMPLECLOCK_RATE=32000LL)
ba58279
+ADD_DEFINITIONS(-DSEMS_APP_NAME=\\\"sems\\\")
ba58279
 
ba58279
-SET(SEMS_APP_NAME "sems")
ba58279
+MESSAGE(STATUS "Configuring ${CMAKE_PROJECT_NAME} v. ${SEMS_VERSION}")
ba58279
 
ba58279
 OPTION(SEMS_USE_SPANDSP       "Build with spandsp" OFF)
ba58279
 OPTION(SEMS_USE_LIBSAMPLERATE "Build with libsamplerate" OFF)
ba58279
@@ -281,6 +286,15 @@ ADD_DEFINITIONS(-DLOG_BUFFER_LEN=2048)
ba58279
 
ba58279
 #ADD_DEFINITIONS(-DDEBUG_PLAYOUTBUF)
ba58279
 
ba58279
+# Propagate all unparsed SIP headers into AmSipReply. Disabled by default
ba58279
+# because only special applications might need this and it brings higher memory
ba58279
+# demands and affects performance.
ba58279
+#ADD_DEFINITIONS(-DPROPAGATE_UNPARSED_REPLY_HEADERS)
ba58279
+
ba58279
+IF(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
ba58279
+	ADD_DEFINITIONS(-DPROPAGATE_COREDUMP_SETTINGS)
ba58279
+ENDIF(${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
ba58279
+
ba58279
 SET(CMAKE_SHARED_LIBRARY_PREFIX "")
ba58279
 
ba58279
 ADD_SUBDIRECTORY (core)
ba58279
diff --git a/apps/CMakeLists.txt b/apps/CMakeLists.txt
ba58279
index ae4c46e..14dd8b5 100644
ba58279
--- a/apps/CMakeLists.txt
ba58279
+++ b/apps/CMakeLists.txt
ba58279
@@ -16,6 +16,7 @@ IF(OPENSSL_FOUND)
ba58279
 ENDIF(OPENSSL_FOUND)
ba58279
 ADD_SUBDIRECTORY(dsm)
ba58279
 ADD_SUBDIRECTORY(early_announce)
ba58279
+ADD_SUBDIRECTORY(early_dbprompt)
ba58279
 #ADD_SUBDIRECTORY(examples)
ba58279
 IF(MISDN_FOUND)
ba58279
 #	ADD_SUBDIRECTORY(gateway)
ba58279
@@ -29,6 +30,7 @@ ENDIF(LIBEV_FOUND)
ba58279
 IF(PYTHONLIBS_FOUND)
ba58279
 	ADD_SUBDIRECTORY(mailbox)
ba58279
 ENDIF(PYTHONLIBS_FOUND)
ba58279
+ADD_SUBDIRECTORY(mobile_push)
ba58279
 ADD_SUBDIRECTORY(monitoring)
ba58279
 IF(LAME_FOUND)
ba58279
 	ADD_SUBDIRECTORY(mp3)
ba58279
diff --git a/apps/dsm/etc/dsm.conf.cmake b/apps/dsm/etc/dsm.conf.cmake
ba58279
index caad8bc..98a0a0a 100644
ba58279
--- a/apps/dsm/etc/dsm.conf.cmake
ba58279
+++ b/apps/dsm/etc/dsm.conf.cmake
ba58279
@@ -127,8 +127,8 @@ load_prompts=${SEMS_CFG_PREFIX}/etc/sems/etc/dsm_in_prompts.conf,${SEMS_CFG_PREF
ba58279
 
ba58279
 # conf_dir=<path>
ba58279
 #
ba58279
-# <path> is scanned for *.conf files. Every .conf
ba58279
-# file is loaded, and in the .conf file, the following
ba58279
+# <path> is scanned for *.conf files configuring application bundles ("app bundles").
ba58279
+# Every .conf file is loaded as app bundle, and in the .conf file, the following
ba58279
 # DSM config parameters are processed:
ba58279
 #   diag_path=
ba58279
 #   load_diags=
ba58279
diff --git a/apps/dsm/mods/CMakeLists.txt b/apps/dsm/mods/CMakeLists.txt
ba58279
index 91369c9..6d4d3da 100644
ba58279
--- a/apps/dsm/mods/CMakeLists.txt
ba58279
+++ b/apps/dsm/mods/CMakeLists.txt
ba58279
@@ -1,6 +1,8 @@
ba58279
 #ADD_SUBDIRECTORY (mod_aws)
ba58279
 ADD_SUBDIRECTORY (mod_conference)
ba58279
+#ADD_SUBDIRECTORY (mod_curl)
ba58279
 ADD_SUBDIRECTORY (mod_dlg)
ba58279
+ADD_SUBDIRECTORY (mod_groups)
ba58279
 IF(SEMS_USE_MONITORING)
ba58279
 	ADD_SUBDIRECTORY (mod_monitoring)
ba58279
 ENDIF(SEMS_USE_MONITORING)
ba58279
@@ -8,7 +10,13 @@ IF(MYSQLPP_FOUND)
ba58279
 	ADD_SUBDIRECTORY (mod_mysql)
ba58279
 ENDIF(MYSQLPP_FOUND)
ba58279
 ADD_SUBDIRECTORY (mod_py)
ba58279
+#ADD_SUBDIRECTORY (mod_redis)
ba58279
+ADD_SUBDIRECTORY (mod_regex)
ba58279
+#ADD_SUBDIRECTORY (mod_sbc)
ba58279
+ADD_SUBDIRECTORY (mod_subscription)
ba58279
 ADD_SUBDIRECTORY (mod_sys)
ba58279
 ADD_SUBDIRECTORY (mod_uri)
ba58279
 ADD_SUBDIRECTORY (mod_utils)
ba58279
+#ADD_SUBDIRECTORY (mod_xml)
ba58279
+#ADD_SUBDIRECTORY (mod_zrtp)
ba58279
 
ba58279
diff --git a/apps/dsm/mods/mod_sbc/CMakeLists.txt b/apps/dsm/mods/mod_sbc/CMakeLists.txt
ba58279
new file mode 100644
ba58279
index 0000000..9cb76f1
ba58279
--- /dev/null
ba58279
+++ b/apps/dsm/mods/mod_sbc/CMakeLists.txt
ba58279
@@ -0,0 +1,7 @@
ba58279
+set (mod_sbc_SRCS
ba58279
+ModSbc.cpp
ba58279
+)
ba58279
+
ba58279
+SET(sems_dsm_module_name mod_sbc)
ba58279
+INCLUDE(${CMAKE_SOURCE_DIR}/cmake/dsm.lib.rules.txt)
ba58279
+
ba58279
diff --git a/apps/dsm/mods/mod_subscription/CMakeLists.txt b/apps/dsm/mods/mod_subscription/CMakeLists.txt
ba58279
new file mode 100644
ba58279
index 0000000..713339e
ba58279
--- /dev/null
ba58279
+++ b/apps/dsm/mods/mod_subscription/CMakeLists.txt
ba58279
@@ -0,0 +1,7 @@
ba58279
+set (mod_subscription_SRCS
ba58279
+ModSubscription.cpp
ba58279
+)
ba58279
+
ba58279
+SET(sems_dsm_module_name mod_subscription)
ba58279
+INCLUDE(${CMAKE_SOURCE_DIR}/cmake/dsm.lib.rules.txt)
ba58279
+
ba58279
diff --git a/apps/early_dbprompt/CMakeLists.txt b/apps/early_dbprompt/CMakeLists.txt
ba58279
new file mode 100644
ba58279
index 0000000..08c30b8
ba58279
--- /dev/null
ba58279
+++ b/apps/early_dbprompt/CMakeLists.txt
ba58279
@@ -0,0 +1,5 @@
ba58279
+
ba58279
+SET(sems_dsm_script_names
ba58279
+	early_dbprompt.dsm
ba58279
+)
ba58279
+INCLUDE(${CMAKE_SOURCE_DIR}/cmake/dsm.script.rules.txt)
ba58279
diff --git a/apps/mobile_push/CMakeLists.txt b/apps/mobile_push/CMakeLists.txt
ba58279
new file mode 100644
ba58279
index 0000000..fefbda7
ba58279
--- /dev/null
ba58279
+++ b/apps/mobile_push/CMakeLists.txt
ba58279
@@ -0,0 +1,5 @@
ba58279
+
ba58279
+SET(sems_dsm_script_names
ba58279
+	mobile_push.dsm
ba58279
+)
ba58279
+INCLUDE(${CMAKE_SOURCE_DIR}/cmake/dsm.script.rules.txt)
ba58279
diff --git a/apps/monitoring/etc/monitoring.conf.cmake b/apps/monitoring/etc/monitoring.conf.cmake
ba58279
index 1f66783..b61c1ca 100644
ba58279
--- a/apps/monitoring/etc/monitoring.conf.cmake
ba58279
+++ b/apps/monitoring/etc/monitoring.conf.cmake
ba58279
@@ -12,3 +12,9 @@ run_garbage_collector = yes
ba58279
 # Default: 10
ba58279
 #
ba58279
 #garbage_collector_interval = 20
ba58279
+
ba58279
+# retain_samples_s=10
ba58279
+# 
ba58279
+# retain "sample" type values for n seconds
ba58279
+#
ba58279
+#retain_samples_s=20
ba58279
diff --git a/apps/sbc/etc/sbc.conf.cmake b/apps/sbc/etc/sbc.conf.cmake
ba58279
index e5dab80..033df47 100644
ba58279
--- a/apps/sbc/etc/sbc.conf.cmake
ba58279
+++ b/apps/sbc/etc/sbc.conf.cmake
ba58279
@@ -31,6 +31,13 @@ active_profile=transparent
ba58279
 # e.g. load_cc_plugins=cc_pcalls;cc_ctl
ba58279
 #load_cc_plugins=cc_pcalls;cc_ctl
ba58279
 
ba58279
+# handle OPTIONS messages in the core? (with limits etc)
ba58279
+# Default: no
ba58279
+#core_options_handling=yes
ba58279
+
ba58279
+# How many threads to use for processing out-of-dialog messages, default: 1
ba58279
+# out_of_dialog_threads=4
ba58279
+
ba58279
 ## RFC4028 Session Timer
ba58279
 # default configuration - can be overridden by call profiles
ba58279
 
ba58279
diff --git a/apps/sbc/etc/transparent.sbcprofile.conf.cmake b/apps/sbc/etc/transparent.sbcprofile.conf.cmake
ba58279
index b768620..c2692ae 100644
ba58279
--- a/apps/sbc/etc/transparent.sbcprofile.conf.cmake
ba58279
+++ b/apps/sbc/etc/transparent.sbcprofile.conf.cmake
ba58279
@@ -19,11 +19,23 @@
ba58279
 #force_outbound_proxy=yes
ba58279
 # destination IP[:port] for outgoing requests
ba58279
 #next_hop=192.168.5.106:5060
ba58279
-# set RURI as calculated next_hop
ba58279
+# set RURI to (calculated) next_hop
ba58279
 #patch_ruri_next_hop=yes
ba58279
+# update next_hop from remote destination? (e.g. from SRV)
ba58279
+#next_hop_fixed=yes
ba58279
 # outbound interface to use (interface ID)
ba58279
 #outbound_interface=extern
ba58279
 
ba58279
+# registration cache: use local registration cache
ba58279
+# enable_reg_caching=yes
ba58279
+#   register upstream every 3600 sec
ba58279
+#  min_reg_expires=3600
ba58279
+#   and make UA re-register every 60 sec
ba58279
+#  max_ua_expires=60
ba58279
+
ba58279
+# SIP NAT handling: recommended if dealing with far end NATs
ba58279
+#dlg_nat_handling=yes
ba58279
+
ba58279
 ## RTP relay
ba58279
 # enable RTP relaying (bridging):
ba58279
 #enable_rtprelay=yes
ba58279
@@ -56,10 +68,17 @@
ba58279
 ## append extra headers
ba58279
 #append_headers="P-Source-IP: $si\r\nP-Source-Port: $sp\r\n"
ba58279
 
ba58279
+## subscription-less NOTIFY pass through
ba58279
+#allow_subless_notify=no
ba58279
+
ba58279
 ## reply translations
ba58279
 # translate some 6xx class replies to 4xx class:
ba58279
 #reply_translations="603=>488 Not acceptable here|600=>406 Not Acceptable"
ba58279
 
ba58279
+## fix replaces for call transfers
ba58279
+# fix_replaces_inv=yes
ba58279
+# fix_replaces_ref=yes
ba58279
+
ba58279
 ## authentication:
ba58279
 #enable_auth=yes
ba58279
 #auth_user=$P(u)
ba58279
@@ -70,6 +89,12 @@
ba58279
 #auth_aleg_user=$P(au)
ba58279
 #auth_aleg_pwd=$P(ap)
ba58279
 
ba58279
+## UAS auth for B leg
ba58279
+#uas_auth_bleg_enabled=yes
ba58279
+#uas_auth_bleg_realm=$P(sr)
ba58279
+#uas_auth_bleg_user=$P(su)
ba58279
+#uas_auth_bleg_pwd=$P(sp)
ba58279
+
ba58279
 ## call timer
ba58279
 #enable_call_timer=yes
ba58279
 #call_timer=60
ba58279
@@ -83,9 +108,8 @@
ba58279
 
ba58279
 ## session timer:
ba58279
 #enable_session_timer=yes
ba58279
-# if session_expires is not configured here,
ba58279
-# the values from sbc.conf are used, or the
ba58279
-# default values
ba58279
+# if any of the session timer parameters below are not defined here,
ba58279
+# the values from sbc.conf are used, or the default values
ba58279
 #session_expires=120
ba58279
 #minimum_timer=90
ba58279
 #session_refresh_method=UPDATE_FALLBACK_INVITE
ba58279
diff --git a/apps/webconference/etc/webconference.conf.cmake b/apps/webconference/etc/webconference.conf.cmake
ba58279
index 69c0e9f..1566504 100644
ba58279
--- a/apps/webconference/etc/webconference.conf.cmake
ba58279
+++ b/apps/webconference/etc/webconference.conf.cmake
ba58279
@@ -29,6 +29,13 @@ star_finishes_pin=yes
ba58279
 # the conference room, without asking for the PIN. 
ba58279
 # 
ba58279
 direct_room_re=000777.*
ba58279
+
ba58279
+# room_pin_split=n  - split PIN/room mode, if set split pin in room 
ba58279
+#                     and pin at position n, makes sense together with private
ba58279
+#                     rooms mode
ba58279
+#
ba58279
+#room_pin_split=4
ba58279
+
ba58279
 #
ba58279
 # direct_room_strip specifies the number of digits to strip 
ba58279
 # from the user part of the request uri to get the conference
ba58279
@@ -36,6 +43,12 @@ direct_room_re=000777.*
ba58279
 # e.g. direct_room_strip=5, called 000777123 => room 123
ba58279
 direct_room_strip=6
ba58279
 
ba58279
+# lonely_user_timer - a caller that is that many seconds in a room alone will be kicked 
ba58279
+#   
ba58279
+# Default: disabled (0)
ba58279
+#
ba58279
+#lonely_user_timer=120
ba58279
+
ba58279
 #
ba58279
 # master_password sets optionally a master password which can be used to
ba58279
 # retreive a room's password with the getRoomPassword function
ba58279
@@ -140,6 +153,9 @@ stats_dir=/var/log/sems-webconference/
ba58279
 # or, get participant ID from header:
ba58279
 #participant_id_header=x-participantid
ba58279
 
ba58279
+# Loop the first_participant_prompt? [yes|no]
ba58279
+# default: no
ba58279
+#loop_first_participant_prompt=yes
ba58279
 
ba58279
 ###############################################################
ba58279
 # RFC4028 Session Timer
ba58279
diff --git a/core/plug-in/CMakeLists.txt b/core/plug-in/CMakeLists.txt
ba58279
index 1ef710d..0be6e53 100644
ba58279
--- a/core/plug-in/CMakeLists.txt
ba58279
+++ b/core/plug-in/CMakeLists.txt
ba58279
@@ -14,6 +14,7 @@ IF(SEMS_USE_ILBC)
ba58279
 ENDIF(SEMS_USE_ILBC)
ba58279
 #ADD_SUBDIRECTORY (isac)
ba58279
 ADD_SUBDIRECTORY (l16)
ba58279
+#ADD_SUBDIRECTORY (opus)
ba58279
 ADD_SUBDIRECTORY (session_timer)
ba58279
 #ADD_SUBDIRECTORY (silk)
ba58279
 IF(SPEEX_FOUND)
ba58279
diff --git a/core/sems.h.cmake b/core/sems.h.cmake
ba58279
index 1c2cccd..7adc87f 100644
ba58279
--- a/core/sems.h.cmake
ba58279
+++ b/core/sems.h.cmake
ba58279
@@ -28,12 +28,6 @@
ba58279
 #ifndef _ans_machine_h_
ba58279
 #define _ans_machine_h_
ba58279
 
ba58279
-#define SEMS_VERSION "${SEMS_VERSION}"
ba58279
-#define OS "${CMAKE_SYSTEM_NAME}"
ba58279
-#define ARCH "${CMAKE_SYSTEM_PROCESSOR}"
ba58279
-
ba58279
-#define SEMS_APP_NAME "${SEMS_APP_NAME}"
ba58279
-
ba58279
 #define CONFIG_FILE         "${SEMS_CFG_PREFIX}/etc/sems/sems.conf"
ba58279
 #define MOD_CFG_PATH        "${SEMS_CFG_PREFIX}/etc/sems/etc/"
ba58279
 #define ANNOUNCE_PATH       "${SEMS_AUDIO_PREFIX}/sems/audio"