Skip to content

Commit a02c145

Browse files
authored
Merge pull request #6 from WeiJiLab/embbed_conan_cmake
add conan.cmake to source control, avoid download
2 parents 0e87497 + 661c342 commit a02c145

File tree

3 files changed

+914
-9
lines changed

3 files changed

+914
-9
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ graph_info.json
1212
CMakeCache.txt
1313
CMakeFiles
1414
Testing
15-
*.cmake
15+
build/*.cmake
1616
Makefile
1717
cmake-build-*
1818

CMakeLists.txt

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,14 @@
11
cmake_minimum_required(VERSION 3.19)
22
project(developer_joyofenergy_cpp)
33

4-
list(APPEND CMAKE_MODULE_PATH ${CMAKE_BINARY_DIR})
4+
list(APPEND CMAKE_MODULE_PATH
5+
${CMAKE_BINARY_DIR}
6+
${CMAKE_SOURCE_DIR}/cmake_module)
57
list(APPEND CMAKE_PREFIX_PATH ${CMAKE_BINARY_DIR})
68

79
set(CMAKE_CXX_STANDARD 17)
810

9-
if(NOT EXISTS "${CMAKE_BINARY_DIR}/conan.cmake")
10-
message(STATUS "Downloading conan.cmake from https://github.com/conan-io/cmake-conan")
11-
file(DOWNLOAD "https://raw.githubusercontent.com/conan-io/cmake-conan/0.17.0/conan.cmake"
12-
"${CMAKE_BINARY_DIR}/conan.cmake")
13-
endif()
14-
15-
include(${CMAKE_BINARY_DIR}/conan.cmake)
11+
include(conan)
1612

1713
conan_cmake_configure(REQUIRES boost/1.76.0
1814
REQUIRES gtest/1.11.0

0 commit comments

Comments
 (0)