Skip to content
Permalink
Browse files

Merge branch 'master' of https://github.com/BearWare/TeamTalk5

  • Loading branch information...
bear101 committed Mar 11, 2019
2 parents 411902a + 699528a commit 9caa4b45b25ebc968fb1248320f4dfd1d4be24fd
Showing with 75 additions and 48 deletions.
  1. +22 −5 CMakeLists.txt
  2. +52 −43 Library/TeamTalkLib/CMakeLists.txt
  3. +1 −0 Library/TeamTalkLib/build/ttclient.cmake
@@ -40,11 +40,28 @@ if (MSVC)
endif()

if (BUILD_TEAMTALK_CORE)
add_dependencies (TeamTalk5-jni TeamTalk5DLL)
add_dependencies (ttserverlog TeamTalk5DLL)

if (BUILD_TEAMTALK5DLL)
if (BUILD_TEAMTALK_LIBRARY_JNI)
add_dependencies (TeamTalk5-jni TeamTalk5DLL)
endif()
if (BUILD_TEAMTALK_CLIENT_LOG_EXAMPLE)
add_dependencies (ttserverlog TeamTalk5DLL)
endif()
endif()

if (BUILD_TEAMTALK5PRODLL)
if (BUILD_TEAMTALKPRO_LIBRARY_JNI)
add_dependencies (TeamTalk5Pro-jni TeamTalk5ProDLL)
endif()

if (BUILD_TEAMTALKPRO_SERVER_EXAMPLE)
add_dependencies (TeamTalk5ProServer TeamTalk5ProDLL)
endif()

add_dependencies (TeamTalk5Pro-jni TeamTalk5ProDLL)
add_dependencies (TeamTalk5ProServer TeamTalk5ProDLL)
add_dependencies (ttproserverlog TeamTalk5ProDLL)
if (BUILD_TEAMTALKPRO_CLIENT_LOG_EXAMPLE)
add_dependencies (ttproserverlog TeamTalk5ProDLL)
endif()
endif()

endif()
@@ -7,7 +7,9 @@ set (TEAMTALKLIB_ROOT ${CMAKE_CURRENT_SOURCE_DIR})
option (BUILD_TEAMTALK_STATIC "Build TeamTalk using static libraries" ON)

if (BUILD_TEAMTALK_STATIC)
set (TTLIBS_ROOT $ENV{TTLIBS_ROOT})
if (NOT ${TTLIBS_ROOT})
set (TTLIBS_ROOT $ENV{TTLIBS_ROOT})
endif()
file (TO_CMAKE_PATH ${TTLIBS_ROOT} TTLIBS_ROOT)
endif()

@@ -92,7 +94,7 @@ if (BUILD_TEAMTALK5DLL)

if (MSVS_UNITTEST)
set_target_properties (TeamTalk5DLL PROPERTIES LINK_FLAGS "/LIBPATH:$(VCInstallDir)UnitTest/lib")
set_target_properties (TeamTalk5DLL PROPERTIES COMPILE_FLAGS "/I$(VCInstallDir)UnitTest/include")
set_target_properties (TeamTalk5DLL PROPERTIES COMPILE_FLAGS "/I$(VCInstallDir)UnitTest/include")
endif()

endif()
@@ -123,7 +125,7 @@ if (BUILD_TEAMTALK5PRODLL)

if (MSVS_UNITTEST)
set_target_properties (TeamTalk5ProDLL PROPERTIES LINK_FLAGS "/LIBPATH:$(VCInstallDir)UnitTest/lib")
set_target_properties (TeamTalk5ProDLL PROPERTIES COMPILE_FLAGS "/I$(VCInstallDir)UnitTest/include")
set_target_properties (TeamTalk5ProDLL PROPERTIES COMPILE_FLAGS "/I$(VCInstallDir)UnitTest/include")
endif()

endif()
@@ -177,56 +179,63 @@ if (BUILD_TT5PROSRV)
endif()

if (MSVC)

##########
# tt5svc #
##########
add_executable ( tt5svc
${TTSRV_SOURCES} ${TTSRV_HEADERS} )

target_include_directories ( tt5svc PUBLIC
${TTSRV_INCLUDE_DIR})
##############
# tt5svc.exe #
##############
option (BUILD_TT5SVC "Build TeamTalk service" ON)

if (BUILD_TT5SVC)
add_executable ( tt5svc
${TTSRV_SOURCES} ${TTSRV_HEADERS} )

target_compile_options ( tt5svc PUBLIC
${TTSRV_COMPILE_FLAGS} ${COMPILE_FLAGS}
-DBUILD_NT_SERVICE)
target_include_directories ( tt5svc PUBLIC
${TTSRV_INCLUDE_DIR})

target_link_libraries ( tt5svc
${TTSRV_LINK_FLAGS}
${LINK_LIBS} )
target_compile_options ( tt5svc PUBLIC
${TTSRV_COMPILE_FLAGS} ${COMPILE_FLAGS}
-DBUILD_NT_SERVICE)

add_custom_command(
TARGET tt5svc
POST_BUILD
COMMAND mt
ARGS -manifest tt5svc.exe.manifest "-outputresource:$(TargetPath);#1"
WORKING_DIRECTORY ${TEAMTALKLIB_ROOT}/build)
target_link_libraries ( tt5svc
${TTSRV_LINK_FLAGS}
${LINK_LIBS} )

set_output_dir(tt5svc ${TEAMTALK_ROOT}/Server)
add_custom_command(
TARGET tt5svc
POST_BUILD
COMMAND mt
ARGS -manifest tt5svc.exe.manifest "-outputresource:$(TargetPath);#1"
WORKING_DIRECTORY ${TEAMTALKLIB_ROOT}/build)

set_output_dir(tt5svc ${TEAMTALK_ROOT}/Server)
endif()

#############
# tt5prosvc #
#############
add_executable ( tt5prosvc
${TTSRV_SOURCES} ${TTSRV_HEADERS} )
#################
# tt5prosvc.exe #
#################
option (BUILD_TT5PROSVC "Build TeamTalk Professional service" ON)

target_include_directories ( tt5prosvc PUBLIC
${TTSRVPRO_INCLUDE_DIR})
if (BUILD_TT5PROSVC)
add_executable ( tt5prosvc
${TTSRV_SOURCES} ${TTSRV_HEADERS} )

target_compile_options ( tt5prosvc PUBLIC
${TTSRVPRO_COMPILE_FLAGS} ${COMPILE_FLAGS}
-DBUILD_NT_SERVICE)
target_include_directories ( tt5prosvc PUBLIC
${TTSRVPRO_INCLUDE_DIR})

target_link_libraries ( tt5prosvc
${TTSRVPRO_LINK_FLAGS}
${LINK_LIBS} )
target_compile_options ( tt5prosvc PUBLIC
${TTSRVPRO_COMPILE_FLAGS} ${COMPILE_FLAGS}
-DBUILD_NT_SERVICE)

add_custom_command (TARGET tt5prosvc
POST_BUILD
COMMAND mt
ARGS -manifest tt5svc.exe.manifest "-outputresource:$(TargetPath);#1"
WORKING_DIRECTORY ${TEAMTALKLIB_ROOT}/build)
target_link_libraries ( tt5prosvc
${TTSRVPRO_LINK_FLAGS}
${LINK_LIBS} )

set_output_dir (tt5prosvc ${TEAMTALK_ROOT}/Server)
add_custom_command (TARGET tt5prosvc
POST_BUILD
COMMAND mt
ARGS -manifest tt5svc.exe.manifest "-outputresource:$(TargetPath);#1"
WORKING_DIRECTORY ${TEAMTALKLIB_ROOT}/build)

set_output_dir (tt5prosvc ${TEAMTALK_ROOT}/Server)
endif()
endif()
@@ -118,4 +118,5 @@ if (WIN32)
${TEAMTALKLIB_ROOT}/win32/Mixer.cpp
${TEAMTALKLIB_ROOT}/win32/WinFirewall.cpp )

list (APPEND TTCLIENT_LINK_FLAGS winmm)
endif()

0 comments on commit 9caa4b4

Please sign in to comment.
You can’t perform that action at this time.