blob: e95d80aac63a02d0f3ce34e8d62e4abd3f163448 (
plain)
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
|
project(platform)
include_directories(${OMIM_ROOT}/3party/jansson/src ${OMIM_ROOT}/platform)
set(CMAKE_AUTOMOC ON)
set(
SRC
battery_tracker.cpp
battery_tracker.hpp
chunks_download_strategy.cpp
chunks_download_strategy.hpp
constants.hpp
country_defines.cpp
country_defines.hpp
country_file.cpp
country_file.hpp
file_logging.cpp
file_logging.hpp
get_text_by_id.cpp
get_text_by_id.hpp
gui_thread.hpp
http_client.cpp
http_client.hpp
http_request.cpp
http_request.hpp
http_thread_callback.hpp
http_uploader.hpp
http_user_agent.cpp
http_user_agent.hpp
local_country_file.cpp
local_country_file.hpp
local_country_file_utils.cpp
local_country_file_utils.hpp
localization.hpp
location.hpp
marketing_service.cpp
marketing_service.hpp
measurement_utils.cpp
measurement_utils.hpp
mwm_traits.cpp
mwm_traits.hpp
mwm_version.cpp
mwm_version.hpp
platform.cpp
platform.hpp
preferred_languages.cpp
preferred_languages.hpp
remote_file.cpp
remote_file.hpp
secure_storage.hpp
servers_list.cpp
servers_list.hpp
settings.cpp
settings.hpp
socket.hpp
string_storage_base.cpp
string_storage_base.hpp
)
if(${PLATFORM_IPHONE})
append(
SRC
gui_thread_apple.mm
http_thread_apple.h
http_thread_apple.mm
http_client_apple.mm
http_uploader_apple.mm
http_user_agent_ios.mm
localization.mm
marketing_service_ios.mm
network_policy_ios.h
network_policy_ios.mm
platform_ios.mm
platform_unix_impl.cpp
platform_unix_impl.hpp
secure_storage_ios.mm
socket_apple.mm
)
elseif(${PLATFORM_ANDROID})
append(
SRC
platform_android.cpp
platform_unix_impl.cpp
platform_unix_impl.hpp
)
else() # neither iPhone nor Android
append(
SRC
http_user_agent_dummy.cpp
localization_dummy.cpp
location_service.cpp
location_service.hpp
marketing_service_dummy.cpp
network_policy_dummy.cpp
platform_qt.cpp
wifi_info.hpp
wifi_location_service.cpp
)
if (${PLATFORM_WIN})
append(
SRC
http_client_curl.cpp
http_user_agent_dummy.cpp
http_thread_qt.cpp
http_thread_qt.hpp
http_uploader_dummy.cpp
marketing_service_dummy.cpp
platform_win.cpp
secure_storage_dummy.cpp
wifi_info_windows.cpp
)
elseif(${PLATFORM_MAC})
append(
SRC
apple_location_service.mm
gui_thread_apple.mm
http_client_apple.mm
http_thread_apple.h
http_thread_apple.mm
http_uploader_apple.mm
http_user_agent_dummy.cpp
marketing_service_dummy.cpp
platform_mac.mm
platform_unix_impl.cpp
platform_unix_impl.hpp
secure_storage_qt.cpp
socket_apple.mm
http_session_manager.mm
)
elseif(${PLATFORM_LINUX})
append(
SRC
gui_thread_linux.cpp
http_client_curl.cpp
http_thread_qt.cpp
http_thread_qt.hpp
http_uploader_dummy.cpp
http_user_agent_dummy.cpp
marketing_service_dummy.cpp
platform_linux.cpp
platform_unix_impl.cpp
platform_unix_impl.hpp
secure_storage_qt.cpp
)
endif()
endif()
add_subdirectory(platform_tests_support)
omim_add_library(${PROJECT_NAME} ${SRC})
if (APPLE)
target_compile_options(${PROJECT_NAME} PUBLIC "-fobjc-arc")
endif()
if (PLATFORM_LINUX)
link_qt5_network(${PROJECT_NAME})
endif()
omim_add_test_subdirectory(platform_tests)
|