summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMataes <mataes2007@gmail.com>2017-11-30 08:38:37 +0300
committerGitHub <noreply@github.com>2017-11-30 08:38:37 +0300
commitc3e40028c06d76a4fd20255c6dd39bcce3f7b229 (patch)
treeb28e593dfbe75d625761636c39e0ec0b1dd44d8e
parent0a95d1c9e2791898c03eab04a06932ec65f3a934 (diff)
parentb1103b6eb24f654e2e2666b0c86a6206920fd23a (diff)
Merge pull request #1046 from protomors/cmake-update
Cmake updates
-rw-r--r--CMakeLists.txt3
-rw-r--r--cmake/core.cmake3
-rw-r--r--cmake/icons.cmake3
-rw-r--r--cmake/lib.cmake3
-rw-r--r--cmake/plugin.cmake3
-rw-r--r--libs/CMakeLists.txt3
-rw-r--r--plugins/Clist_modern/CMakeLists.txt1
-rw-r--r--plugins/TopToolBar/CMakeLists.txt3
-rw-r--r--protocols/CMakeLists.txt5
-rw-r--r--protocols/IRCG/CMakeLists.txt1
-rw-r--r--protocols/IcqOscarJ/CMakeLists.txt1
-rw-r--r--protocols/JabberG/CMakeLists.txt2
-rw-r--r--protocols/MSN/CMakeLists.txt2
-rw-r--r--protocols/Steam/CMakeLists.txt1
-rw-r--r--src/core/stdclist/CMakeLists.txt3
-rw-r--r--src/core/stdfile/CMakeLists.txt3
-rw-r--r--src/core/stdidle/CMakeLists.txt3
-rw-r--r--src/core/stdssl/CMakeLists.txt2
-rw-r--r--src/core/stduserinfo/CMakeLists.txt3
-rw-r--r--src/mir_app/CMakeLists.txt5
-rw-r--r--src/mir_core/CMakeLists.txt2
21 files changed, 28 insertions, 27 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5328c8ddf4..e76b31a297 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,6 +2,8 @@ cmake_minimum_required (VERSION 2.8)
project (Miranda)
+find_package(OpenSSL)
+
set_directory_properties(PROPERTIES COMPILE_DEFINITIONS "_UNICODE;UNICODE;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_WARNINGS")
if(CMAKE_CL_64)
link_directories(${CMAKE_SOURCE_DIR}/libs/win64)
@@ -9,7 +11,6 @@ else()
link_directories(${CMAKE_SOURCE_DIR}/libs/win32)
endif()
include_directories(${CMAKE_SOURCE_DIR}/include ${CMAKE_SOURCE_DIR}/include/msapi ${CMAKE_SOURCE_DIR}/plugins/ExternalAPI)
-set(COMMON_LIBS winmm.lib Wtsapi32.lib netapi32.lib pdh.lib shlwapi.lib Strmiids.lib gdiplus.lib dbghelp.lib Setupapi.lib msimg32.lib comctl32.lib ws2_32.lib UxTheme.lib)
add_subdirectory(libs)
add_subdirectory(src)
diff --git a/cmake/core.cmake b/cmake/core.cmake
index 5fc7c37302..afb345d4a8 100644
--- a/cmake/core.cmake
+++ b/cmake/core.cmake
@@ -12,5 +12,4 @@ endif()
set_target_properties(${TARGET} PROPERTIES
LINK_FLAGS "/SUBSYSTEM:WINDOWS"
RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/$<CONFIG>/Core"
-)
-target_link_libraries(${TARGET} ${COMMON_LIBS}) \ No newline at end of file
+) \ No newline at end of file
diff --git a/cmake/icons.cmake b/cmake/icons.cmake
index c03630ef49..0096748919 100644
--- a/cmake/icons.cmake
+++ b/cmake/icons.cmake
@@ -3,5 +3,4 @@ add_library(${TARGET} SHARED ${SOURCES})
set_target_properties(${TARGET} PROPERTIES
LINK_FLAGS "/SUBSYSTEM:WINDOWS /NOENTRY"
RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/$<CONFIG>/Icons"
-)
-target_link_libraries(${TARGET} ${COMMON_LIBS}) \ No newline at end of file
+) \ No newline at end of file
diff --git a/cmake/lib.cmake b/cmake/lib.cmake
index 64ceb02bd5..33e940a663 100644
--- a/cmake/lib.cmake
+++ b/cmake/lib.cmake
@@ -11,5 +11,4 @@ set_target_properties(${TARGET} PROPERTIES
LINK_FLAGS "/SUBSYSTEM:WINDOWS"
SUFFIX ".mir"
RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/$<CONFIG>/Libs"
-)
-target_link_libraries(${TARGET} ${COMMON_LIBS}) \ No newline at end of file
+) \ No newline at end of file
diff --git a/cmake/plugin.cmake b/cmake/plugin.cmake
index d3986c87c3..ed830572d6 100644
--- a/cmake/plugin.cmake
+++ b/cmake/plugin.cmake
@@ -10,5 +10,4 @@ endif()
set_target_properties(${TARGET} PROPERTIES
LINK_FLAGS "/SUBSYSTEM:WINDOWS"
RUNTIME_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/$<CONFIG>/Plugins"
-)
-target_link_libraries(${TARGET} ${COMMON_LIBS}) \ No newline at end of file
+) \ No newline at end of file
diff --git a/libs/CMakeLists.txt b/libs/CMakeLists.txt
index 67fdb72838..5c360a5ef0 100644
--- a/libs/CMakeLists.txt
+++ b/libs/CMakeLists.txt
@@ -1,4 +1,3 @@
add_subdirectory(zlib)
add_subdirectory(libjson)
-add_subdirectory(libaxolotl)
-add_subdirectory(libevent) \ No newline at end of file
+add_subdirectory(libaxolotl) \ No newline at end of file
diff --git a/plugins/Clist_modern/CMakeLists.txt b/plugins/Clist_modern/CMakeLists.txt
index 9b2017d2f8..4952fce0bc 100644
--- a/plugins/Clist_modern/CMakeLists.txt
+++ b/plugins/Clist_modern/CMakeLists.txt
@@ -1,4 +1,5 @@
file(GLOB SOURCES "src/*.h" "src/*.cpp" "res/*.rc")
set(TARGET Clist_modern)
include(${CMAKE_SOURCE_DIR}/cmake/plugin.cmake)
+target_link_libraries(${TARGET} comctl32.lib UxTheme.lib)
add_subdirectory(icons_pack) \ No newline at end of file
diff --git a/plugins/TopToolBar/CMakeLists.txt b/plugins/TopToolBar/CMakeLists.txt
index d9fe0fba80..f2f3987bf6 100644
--- a/plugins/TopToolBar/CMakeLists.txt
+++ b/plugins/TopToolBar/CMakeLists.txt
@@ -1,3 +1,4 @@
file(GLOB SOURCES "src/*.h" "src/*.cpp" "res/*.rc")
set(TARGET TopToolBar)
-include(${CMAKE_SOURCE_DIR}/cmake/plugin.cmake) \ No newline at end of file
+include(${CMAKE_SOURCE_DIR}/cmake/plugin.cmake)
+target_link_libraries(${TARGET} comctl32.lib) \ No newline at end of file
diff --git a/protocols/CMakeLists.txt b/protocols/CMakeLists.txt
index e3c6bfff44..d9360f7a01 100644
--- a/protocols/CMakeLists.txt
+++ b/protocols/CMakeLists.txt
@@ -14,11 +14,8 @@ add_subdirectory(MSN)
#add_subdirectory(Omegle)
#add_subdirectory(Sametime)
add_subdirectory(SkypeWeb)
-#add_subdirectory(Slack)
add_subdirectory(Steam)
-#add_subdirectory(Telegram)
#add_subdirectory(Tlen)
#add_subdirectory(Tox)
add_subdirectory(Twitter)
-add_subdirectory(VKontakte)
-#add_subdirectory(WhatsApp) \ No newline at end of file
+add_subdirectory(VKontakte) \ No newline at end of file
diff --git a/protocols/IRCG/CMakeLists.txt b/protocols/IRCG/CMakeLists.txt
index a281099459..9f37dca7f3 100644
--- a/protocols/IRCG/CMakeLists.txt
+++ b/protocols/IRCG/CMakeLists.txt
@@ -1,4 +1,5 @@
file(GLOB SOURCES "src/*.h" "src/*.cpp" "res/*.rc")
set(TARGET IRC)
include(${CMAKE_SOURCE_DIR}/cmake/plugin.cmake)
+target_link_libraries(${TARGET} ws2_32.lib)
add_subdirectory(proto_irc) \ No newline at end of file
diff --git a/protocols/IcqOscarJ/CMakeLists.txt b/protocols/IcqOscarJ/CMakeLists.txt
index f5c241229b..c5feb2c951 100644
--- a/protocols/IcqOscarJ/CMakeLists.txt
+++ b/protocols/IcqOscarJ/CMakeLists.txt
@@ -1,5 +1,6 @@
file(GLOB SOURCES "src/*.h" "src/*.cpp" "res/*.rc")
set(TARGET ICQ)
include(${CMAKE_SOURCE_DIR}/cmake/plugin.cmake)
+target_link_libraries(${TARGET} comctl32.lib ws2_32.lib)
add_subdirectory(proto_icq)
add_subdirectory(icq_xstatus) \ No newline at end of file
diff --git a/protocols/JabberG/CMakeLists.txt b/protocols/JabberG/CMakeLists.txt
index 257a4cd8ae..65f5bb3a66 100644
--- a/protocols/JabberG/CMakeLists.txt
+++ b/protocols/JabberG/CMakeLists.txt
@@ -2,6 +2,6 @@ file(GLOB SOURCES "src/*.h" "src/*.cpp" "res/*.rc")
set(TARGET Jabber)
include_directories(${CMAKE_SOURCE_DIR}/libs/libaxolotl/src)
include(${CMAKE_SOURCE_DIR}/cmake/plugin.cmake)
-target_link_libraries(${TARGET} Zlib libaxolotl libeay32.lib ssleay32.lib)
+target_link_libraries(${TARGET} Zlib libaxolotl ${OPENSSL_LIBRARIES} comctl32.lib UxTheme.lib ws2_32.lib)
add_subdirectory(jabber_xstatus)
add_subdirectory(proto_jabber) \ No newline at end of file
diff --git a/protocols/MSN/CMakeLists.txt b/protocols/MSN/CMakeLists.txt
index a3984234ef..58e247810b 100644
--- a/protocols/MSN/CMakeLists.txt
+++ b/protocols/MSN/CMakeLists.txt
@@ -1,5 +1,5 @@
file(GLOB SOURCES "src/*.h" "src/skylogin/*.h" "src/*.cpp" "src/*.c" "src/skylogin/*.c" "res/*.rc")
set(TARGET MSN)
include(${CMAKE_SOURCE_DIR}/cmake/plugin.cmake)
-target_link_libraries(${TARGET} libeay32.lib)
+target_link_libraries(${TARGET} libjson ${OPENSSL_LIBRARIES} comctl32.lib)
add_subdirectory(proto_msn) \ No newline at end of file
diff --git a/protocols/Steam/CMakeLists.txt b/protocols/Steam/CMakeLists.txt
index 4f76cb5bf9..9dacd1a586 100644
--- a/protocols/Steam/CMakeLists.txt
+++ b/protocols/Steam/CMakeLists.txt
@@ -1,4 +1,5 @@
file(GLOB SOURCES "src/*.h" "src/api/*.h" "src/*.cpp" "res/*.rc")
set(TARGET Steam)
include(${CMAKE_SOURCE_DIR}/cmake/plugin.cmake)
+target_link_libraries(${TARGET} libjson comctl32.lib)
add_subdirectory(proto_steam) \ No newline at end of file
diff --git a/src/core/stdclist/CMakeLists.txt b/src/core/stdclist/CMakeLists.txt
index 4477d53c3a..9c93e7d364 100644
--- a/src/core/stdclist/CMakeLists.txt
+++ b/src/core/stdclist/CMakeLists.txt
@@ -1,2 +1,3 @@
set(TARGET StdClist)
-include(${CMAKE_SOURCE_DIR}/cmake/core.cmake) \ No newline at end of file
+include(${CMAKE_SOURCE_DIR}/cmake/core.cmake)
+target_link_libraries(${TARGET} comctl32.lib UxTheme.lib Shlwapi.lib) \ No newline at end of file
diff --git a/src/core/stdfile/CMakeLists.txt b/src/core/stdfile/CMakeLists.txt
index a91f49e32a..3454bf4121 100644
--- a/src/core/stdfile/CMakeLists.txt
+++ b/src/core/stdfile/CMakeLists.txt
@@ -1,2 +1,3 @@
set(TARGET StdFile)
-include(${CMAKE_SOURCE_DIR}/cmake/core.cmake) \ No newline at end of file
+include(${CMAKE_SOURCE_DIR}/cmake/core.cmake)
+target_link_libraries(${TARGET} Shlwapi.lib) \ No newline at end of file
diff --git a/src/core/stdidle/CMakeLists.txt b/src/core/stdidle/CMakeLists.txt
index 67735cfc07..e11c1176b5 100644
--- a/src/core/stdidle/CMakeLists.txt
+++ b/src/core/stdidle/CMakeLists.txt
@@ -1,2 +1,3 @@
set(TARGET StdIdle)
-include(${CMAKE_SOURCE_DIR}/cmake/core.cmake) \ No newline at end of file
+include(${CMAKE_SOURCE_DIR}/cmake/core.cmake)
+target_link_libraries(${TARGET} Wtsapi32.lib) \ No newline at end of file
diff --git a/src/core/stdssl/CMakeLists.txt b/src/core/stdssl/CMakeLists.txt
index ecc952031a..6b2c0a91d0 100644
--- a/src/core/stdssl/CMakeLists.txt
+++ b/src/core/stdssl/CMakeLists.txt
@@ -1,3 +1,3 @@
set(TARGET StdSSL)
include(${CMAKE_SOURCE_DIR}/cmake/core.cmake)
-target_link_libraries(${TARGET} secur32.lib crypt32.lib) \ No newline at end of file
+target_link_libraries(${TARGET} ws2_32.lib secur32.lib crypt32.lib) \ No newline at end of file
diff --git a/src/core/stduserinfo/CMakeLists.txt b/src/core/stduserinfo/CMakeLists.txt
index 42a47311b7..7bdbd5c48b 100644
--- a/src/core/stduserinfo/CMakeLists.txt
+++ b/src/core/stduserinfo/CMakeLists.txt
@@ -1,2 +1,3 @@
set(TARGET StdUserInfo)
-include(${CMAKE_SOURCE_DIR}/cmake/core.cmake) \ No newline at end of file
+include(${CMAKE_SOURCE_DIR}/cmake/core.cmake)
+target_link_libraries(${TARGET} UxTheme.lib ws2_32.lib) \ No newline at end of file
diff --git a/src/mir_app/CMakeLists.txt b/src/mir_app/CMakeLists.txt
index fa73635191..aee657a982 100644
--- a/src/mir_app/CMakeLists.txt
+++ b/src/mir_app/CMakeLists.txt
@@ -6,6 +6,5 @@ else()
endif()
set(TARGET mir_app)
include(${CMAKE_SOURCE_DIR}/cmake/lib.cmake)
-
-set_target_properties(${TARGET} PROPERTIES COMPILE_DEFINITIONS "MIR_APP_EXPORTS")
-target_link_libraries(${TARGET} Zlib) \ No newline at end of file
+target_link_libraries(${TARGET} Zlib UxTheme.lib ws2_32.lib)
+set_target_properties(${TARGET} PROPERTIES COMPILE_DEFINITIONS "MIR_APP_EXPORTS") \ No newline at end of file
diff --git a/src/mir_core/CMakeLists.txt b/src/mir_core/CMakeLists.txt
index d9ad3b5ba2..8c39e0e4d5 100644
--- a/src/mir_core/CMakeLists.txt
+++ b/src/mir_core/CMakeLists.txt
@@ -6,6 +6,6 @@ else()
endif()
set(TARGET mir_core)
include(${CMAKE_SOURCE_DIR}/cmake/lib.cmake)
-
+target_link_libraries(${TARGET} comctl32.lib)
set_target_properties(${TARGET} PROPERTIES COMPILE_DEFINITIONS "MIR_CORE_EXPORTS")
add_custom_command(TARGET ${TARGET} PRE_BUILD COMMAND "${CMAKE_SOURCE_DIR}/build/make_ver.bat") \ No newline at end of file