forked from BearWare/TeamTalk5
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
86 lines (75 loc) · 2.43 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# Relative paths are not supported pre-2.8.1, target_link_libraries seems to require 3.0.2
cmake_minimum_required(VERSION 3.5)
project (TeamTalk5SDK)
# To build TeamTalk libraries, clients and servers including all their
# dependencies follow the instructions below for each platform
#
# Windows 32-bit
# --------------
# Open "x86 Native Tools Command Prompt for VS 2019" and change to
# directory of TeamTalk5 checkout, e.g. C:\TeamTalk5
#
# Now configure an output directory, here teamtalk-win32, for
# TeamTalk5 repository in C:\TeamTalk5:
#
# $ cmake -S C:/TeamTalk5 -B teamtalk-win32 -A Win32
#
# Afterwards build configured projects:
#
# $ cmake --build teamtalk-win32
#
# A Visual Studio 2019 solution file will also be available in output
# directory teamtalk-win32.
#
# Windows 64-bit
# --------------
# Open "x64 Native Tools Command Prompt for VS 2019" and change to
# directory of TeamTalk5 checkout, e.g. C:\TeamTalk5
#
# Now configure an output directory, here teamtalk-win64, for
# TeamTalk5 repository in C:\TeamTalk5:
#
# $ cmake -S C:/TeamTalk5 -B teamtalk-win64 -A x64
#
# Afterwards build configured projects:
#
# $ cmake --build teamtalk-win64
#
# A Visual Studio 2019 solution file will also be available in output
# directory teamtalk-win64.
option (BUILD_TEAMTALK_CORE "Build TeamTalk core library" ON)
option (BUILD_TEAMTALK_LIBRARIES "Build TeamTalk libraries" ON)
option (BUILD_TEAMTALK_CLIENTS "Build TeamTalk client examples" ON)
option (BUILD_TEAMTALK_SERVERS "Build TeamTalk server examples" ON)
option (BUILD_TEAMTALK_DOCUMENTATION "Build TeamTalk documentation" ON)
set (TEAMTALK_ROOT ${CMAKE_CURRENT_LIST_DIR})
if (BUILD_TEAMTALK_CORE)
add_subdirectory (Library/TeamTalkLib)
endif()
if (MSVC)
include(CheckLanguage)
check_language(CSharp)
endif()
if (BUILD_TEAMTALK_LIBRARIES)
add_subdirectory (Library/TeamTalkJNI)
if (CMAKE_CSharp_COMPILER)
add_subdirectory (Library/TeamTalk.NET)
else()
message(WARNING "No C# compiler detected. Skipping .NET libraries")
endif()
endif()
if (BUILD_TEAMTALK_CLIENTS)
add_subdirectory (Client)
endif()
if (BUILD_TEAMTALK_SERVERS)
add_subdirectory (Server/TeamTalkServer)
if (CMAKE_CSharp_COMPILER)
add_subdirectory (Server/TeamTalkServer.NET)
else()
message(WARNING "No C# compiler detected. Skipping .NET Servers")
endif()
endif()
if (BUILD_TEAMTALK_DOCUMENTATION)
add_subdirectory (Documentation/TeamTalk)
add_subdirectory (Documentation/TeamTalkSDK)
endif()