Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimofey <t.danshin@corp.mail.ru>2016-11-03 18:34:24 +0300
committerTimofey <t.danshin@corp.mail.ru>2016-11-09 14:20:06 +0300
commit14a9cea834027fcd1c0131b13f61c0f42f6439b9 (patch)
treea13d3ed28ccbe37e58c21119e7348e8c5ee72707 /platform
parent2ec8f5f71fee1f199a702c179eb5d29b1f5806ef (diff)
Added project declarations to subprojects
Replaced set with append
Diffstat (limited to 'platform')
-rw-r--r--platform/CMakeLists.txt27
-rw-r--r--platform/platform_tests/CMakeLists.txt25
-rw-r--r--platform/platform_tests_support/CMakeLists.txt4
3 files changed, 34 insertions, 22 deletions
diff --git a/platform/CMakeLists.txt b/platform/CMakeLists.txt
index 75d0a96df7..ce3ef3e86b 100644
--- a/platform/CMakeLists.txt
+++ b/platform/CMakeLists.txt
@@ -1,3 +1,5 @@
+project(platform)
+
include_directories(${OMIM_ROOT}/3party/jansson/src ${OMIM_ROOT}/platform)
set(
@@ -42,11 +44,9 @@ set(
socket.hpp
)
-
if(${PLATFORM_IPHONE})
- set(
+ append(
SRC
- ${SRC}
http_thread_apple.h
http_thread_apple.mm
http_client_apple.mm
@@ -57,17 +57,15 @@ if(${PLATFORM_IPHONE})
socket_apple.mm
)
elseif(${PLATFORM_ANDROID})
- set(
+ append(
SRC
- ${SRC}
platform_android.cpp
platform_unix_impl.cpp
platform_unix_impl.hpp
)
else() # neither iPhone nor Android
- set(
+ append(
SRC
- ${SRC}
location_service.cpp
location_service.hpp
marketing_service_dummy.cpp
@@ -77,9 +75,8 @@ else() # neither iPhone nor Android
)
if (${PLATFORM_WIN})
- set(
+ append(
SRC
- ${SRC}
http_client_curl.cpp
http_thread_qt.cpp
http_thread_qt.hpp
@@ -88,9 +85,8 @@ else() # neither iPhone nor Android
wifi_info_windows.cpp
)
elseif(${PLATFORM_MAC})
- set(
+ append(
SRC
- ${SRC}
apple_location_service.mm
http_client_apple.mm
http_thread_apple.h
@@ -102,9 +98,8 @@ else() # neither iPhone nor Android
socket_apple.mm
)
elseif(${PLATFORM_LINUX})
- set(
+ append(
SRC
- ${SRC}
http_client_curl.cpp
http_thread_qt.cpp
http_thread_qt.hpp
@@ -116,14 +111,12 @@ else() # neither iPhone nor Android
endif()
endif()
-
-
add_subdirectory(platform_tests_support)
-add_library(platform ${SRC})
+add_library(${PROJECT_NAME} ${SRC})
if (APPLE)
- target_compile_options(platform PUBLIC "-fobjc-arc")
+ target_compile_options(${PROJECT_NAME} PUBLIC "-fobjc-arc")
endif()
omim_add_test_subdirectory(platform_tests)
diff --git a/platform/platform_tests/CMakeLists.txt b/platform/platform_tests/CMakeLists.txt
index 21cb5686d6..ae6e11d933 100644
--- a/platform/platform_tests/CMakeLists.txt
+++ b/platform/platform_tests/CMakeLists.txt
@@ -1,3 +1,5 @@
+project(platform_tests)
+
add_definitions(-DOMIM_UNIT_TEST_WITH_QT_EVENT_LOOP)
include_directories(${APL_SYSCON})
@@ -15,12 +17,24 @@ set(
platform_test.cpp
)
-omim_add_test(platform_tests ${SRC})
-omim_link_libraries(platform_tests platform_tests_support platform coding base jansson minizip tomcrypt ${LIBZ})
+omim_add_test(${PROJECT_NAME} ${SRC})
+omim_link_libraries(
+ ${PROJECT_NAME}
+ platform_tests_support
+ platform
+ coding
+ base
+ jansson
+ minizip
+ tomcrypt
+ ${LIBZ}
+)
if (PLATFORM_MAC)
- omim_link_libraries(platform_tests ${Qt5Widgets_LIBRARIES}
+ omim_link_libraries(
+ ${PROJECT_NAME}
+ ${Qt5Widgets_LIBRARIES}
"-framework Cocoa"
"-framework IOKit"
"-framework QuartzCore"
@@ -29,5 +43,8 @@ if (PLATFORM_MAC)
endif()
if (PLATFORM_WIN OR PLATFORM_LINUX)
- omim_link_libraries(platform_tests ${Qt5Network_LIBRARIES})
+ omim_link_libraries(
+ ${PROJECT_NAME}
+ ${Qt5Widgets_LIBRARIES}
+ )
endif()
diff --git a/platform/platform_tests_support/CMakeLists.txt b/platform/platform_tests_support/CMakeLists.txt
index 3b5dbc2791..e0af0ba0c9 100644
--- a/platform/platform_tests_support/CMakeLists.txt
+++ b/platform/platform_tests_support/CMakeLists.txt
@@ -1,3 +1,5 @@
+project(platform_tests_support)
+
set(
SRC
scoped_dir.cpp
@@ -12,4 +14,4 @@ set(
writable_dir_changer.hpp
)
-add_library(platform_tests_support ${SRC})
+add_library(${PROJECT_NAME} ${SRC})