You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ignite.apache.org by "isapego (via GitHub)" <gi...@apache.org> on 2023/03/17 10:58:05 UTC

[GitHub] [ignite-3] isapego commented on a diff in pull request #1805: IGNITE-19054 Use cmake conan wrapper for automatic conan configuration

isapego commented on code in PR #1805:
URL: https://github.com/apache/ignite-3/pull/1805#discussion_r1140082637


##########
modules/platforms/cpp/CMakeLists.txt:
##########
@@ -24,18 +24,61 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON)
 set(CMAKE_PROJECT_VERSION ${PROJECT_VERSION})
 
 set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
+list(APPEND CMAKE_MODULE_PATH ${CMAKE_BINARY_DIR})
+list(APPEND CMAKE_PREFIX_PATH ${CMAKE_BINARY_DIR})
 
-if(EXISTS ${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
-    message(STATUS "Conan detected. Enabling...")
-    include(${CMAKE_BINARY_DIR}/conan_paths.cmake)
-    include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
-    conan_basic_setup()
+include(conan)
+
+get_property(is_multi_config GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG)
+
+# Install required libraries.
+if (is_multi_config)
+    # These settings are for multi-config generators like Visual Studio.
+    message(STATUS "Using a multi-config generator")
+
+    conan_cmake_configure(REQUIRES msgpack-c/4.0.0 gtest/1.12.1
+                          GENERATORS cmake_find_package_multi)

Review Comment:
   Let's move a list of libraries to a separate variable.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org