36
36
sudo apt-get update -y
37
37
38
38
- name : Install CMake
39
- uses : lukka/get-cmake@v3.24 .3
39
+ uses : lukka/get-cmake@v3.29 .3
40
40
with :
41
- cmakeVersion : 3.16.9
41
+ cmakeVersion : 3.24
42
42
43
43
- name : Install compiler
44
44
id : install_cc
@@ -49,10 +49,43 @@ jobs:
49
49
- name : Install linker
50
50
uses : rui314/setup-mold@v1
51
51
52
- - uses : actions/checkout@v3
52
+ - name : Configure conan
53
+ run : |
54
+ pip3 install conan==2.3.0
55
+
56
+ # conan profile update is deprecated (https://github.com/conan-io/conan/issues/13205)
57
+ # and they don't want you to use detect because it is unstable
58
+
59
+ conan profile detect # Force creation of conan directory structure, will be overwritten
60
+
61
+ echo '{% set compiler, version, c_exe = detect_api.detect_default_compiler() %}' > ~/.conan2/profiles/default
62
+ echo '[settings]' >> ~/.conan2/profiles/default
63
+ echo 'os={{ detect_api.detect_os() }}' >> ~/.conan2/profiles/default
64
+ echo 'arch={{ detect_api.detect_arch() }}' >> ~/.conan2/profiles/default
65
+ echo 'build_type=Release' >> ~/.conan2/profiles/default
66
+ echo 'compiler={{ compiler }}' >> ~/.conan2/profiles/default
67
+ echo 'compiler.version={{ detect_api.default_compiler_version(compiler, version) }}' >> ~/.conan2/profiles/default
68
+ echo 'compiler.libcxx=libstdc++11' >> ~/.conan2/profiles/default
69
+
70
+ conan remote add -f dice-group https://conan.dice-research.org/artifactory/api/conan/tentris
71
+
72
+ - name : Cache conan data
73
+ id : cache-conan
74
+
75
+ with :
76
+ path : ~/.conan2/p
77
+ key : ${{ matrix.config.os }}-${{ matrix.config.compiler }}
78
+
79
+
80
+
81
+ - name : Get dependency provider
82
+ run : |
83
+ sudo apt-get install -y wget
84
+
85
+ wget https://github.com/conan-io/cmake-conan/raw/develop2/conan_provider.cmake -O conan_provider.cmake
53
86
54
87
- name : Configure CMake
55
- run : cmake -DCMAKE_BUILD_TYPE=Debug -DBUILD_TESTING=On -DBUILD_EXAMPLES=On -G Ninja -B build .
88
+ run : cmake -DCMAKE_BUILD_TYPE=Debug -DBUILD_TESTING=On -DBUILD_EXAMPLES=On -DCMAKE_PROJECT_TOP_LEVEL_INCLUDES=conan_provider.cmake - G Ninja -B build .
56
89
env :
57
90
CC : ${{ steps.install_cc.outputs.cc }}
58
91
CXX : ${{ steps.install_cc.outputs.cxx }}
0 commit comments