diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 00000000..006c3adc --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,12 @@ +project (SEMS) + +set(SEMS_VERSION 1.1.0-pre) +# todo: get build arch +set(ARCH 32) +set(OS 1) + +set(CMAKE_VERBOSE_MAKEFILE ON) + + +add_subdirectory (core) + diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt new file mode 100644 index 00000000..8f4cc7e6 --- /dev/null +++ b/core/CMakeLists.txt @@ -0,0 +1,60 @@ + +set (sems_SRCS + AmAdvancedAudio.cpp + AmApi.cpp + AmArg.cpp + AmAudio.cpp + AmAudioFile.cpp + AmAudioMixIn.cpp + AmB2ABSession.cpp + AmB2BSession.cpp + AmBufferedAudio.cpp + AmCachedAudioFile.cpp + AmCallWatcher.cpp + AmConferenceChannel.cpp + AmConferenceStatus.cpp + AmConfig.cpp + AmConfigReader.cpp + AmDtmfDetector.cpp + AmEvent.cpp + AmEventDispatcher.cpp + AmEventQueue.cpp + AmIcmpWatcher.cpp + AmJitterBuffer.cpp + AmMediaProcessor.cpp + AmMultiPartyMixer.cpp + AmPlaylist.cpp + AmPlayoutBuffer.cpp + AmPlugIn.cpp + AmPrecodedFile.cpp + AmPromptCollection.cpp + AmRingTone.cpp + AmRtpAudio.cpp + AmRtpPacket.cpp + AmRtpReceiver.cpp + AmRtpStream.cpp + AmSdp.cpp + AmServer.cpp + AmSession.cpp + AmSessionContainer.cpp + AmSipDialog.cpp + AmSipDispatcher.cpp + AmSipMsg.cpp + AmThread.cpp + AmUAC.cpp + AmUtils.cpp + AmZRTP.cpp + LowcFE.cpp + log.cpp + sems.cpp +) + +include_directories (${SEMS_SOURCE_DIR}/core/ampi) +include_directories (${SEMS_SOURCE_DIR}/core/amci) + +configure_file( config.h.cmake ${SEMS_SOURCE_DIR}/core/config.h ) + +add_executable (sems ${sems_SRCS}) +target_link_libraries(sems ${CMAKE_DL_LIBS} pthread stdc++ m) + +add_subdirectory (plug-in) diff --git a/core/config.h b/core/config.h new file mode 100644 index 00000000..07aeb914 --- /dev/null +++ b/core/config.h @@ -0,0 +1,8 @@ +#ifndef CONFIG_H +#define CONFIG_H + +#define SEMS_VERSION "1.1.0-pre" +#define OS "Linux" +#define ARCH "32" + +#endif // CONFIG_H diff --git a/core/config.h.cmake b/core/config.h.cmake new file mode 100644 index 00000000..02469ccc --- /dev/null +++ b/core/config.h.cmake @@ -0,0 +1,8 @@ +#ifndef CONFIG_H +#define CONFIG_H + +#cmakedefine SEMS_VERSION "@SEMS_VERSION@" +#cmakedefine OS "@CMAKE_SYSTEM_NAME@" +#cmakedefine ARCH "@ARCH@" + +#endif // CONFIG_H \ No newline at end of file diff --git a/core/plug-in/CMakeLists.txt b/core/plug-in/CMakeLists.txt new file mode 100644 index 00000000..f419ae7c --- /dev/null +++ b/core/plug-in/CMakeLists.txt @@ -0,0 +1 @@ +add_subdirectory (wav) diff --git a/core/plug-in/wav/CMakeLists.txt b/core/plug-in/wav/CMakeLists.txt new file mode 100644 index 00000000..c08706a4 --- /dev/null +++ b/core/plug-in/wav/CMakeLists.txt @@ -0,0 +1,11 @@ +set (wav_SRCS + g711.c + wav.c + wav_hdr.c +) + +add_library(wav SHARED ${wav_SRCS}) +set_target_properties(wav PROPERTIES OUTPUT_NAME "wav") +set_target_properties(wav PROPERTIES PREFIX "") +target_link_libraries(wav ${CMAKE_DL_LIBS} pthread stdc++ m) + diff --git a/core/sems.h b/core/sems.h index 1b3a5269..051d529f 100644 --- a/core/sems.h +++ b/core/sems.h @@ -28,6 +28,10 @@ #ifndef _ans_machine_h_ #define _ans_machine_h_ +#ifndef SEMS_VERSION +#include "config.h" +#endif + #define CONFIG_FILE "/usr/local/etc/sems/sems.conf" #define MOD_CFG_PATH "/usr/local/etc/sems/etc" #define SER_FIFO "/tmp/ser_fifo"