File tree Expand file tree Collapse file tree 2 files changed +54
-0
lines changed
Expand file tree Collapse file tree 2 files changed +54
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CMake
2+
3+ on :
4+ push :
5+ branches :
6+ - develop
7+ pull_request :
8+ branches :
9+ - develop
10+
11+ env :
12+ BUILD_TYPE : RelWithDebInfo
13+ # Conan cache environment variables
14+ CONAN_SYSREQUIRES_MODE : enabled
15+ CONAN_USER_HOME : " ${{ github.workspace }}/conan-cache"
16+ CONAN_USER_HOME_SHORT : " ${{ github.workspace }}/conan-cache/short"
17+
18+ jobs :
19+ build :
20+ strategy :
21+ fail-fast : false
22+ matrix :
23+ os : ['ubuntu-latest', 'windows-latest', 'macos-latest']
24+ runs-on : ${{ matrix.os }}
25+
26+ steps :
27+ - uses : actions/checkout@v2
28+
29+ - name : Cache
30+ uses : actions/cache@v2
31+ env :
32+ cache-name : cache-conan-modules
33+ with :
34+ path : |
35+ ${{ env.CONAN_USER_HOME }}
36+ ~/.cache/pip
37+ key : ${{ runner.os }}-${{ env.BUILD_TYPE }}-${{ hashFiles('CMakeLists.txt') }}-${{ hashFiles('cmake/Conan.cmake') }}
38+
39+ - name : Get Conan
40+ uses :
turtlebrowser/[email protected] 41+
42+ - name : Configure CMake
43+ run : cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
44+
45+ - name : Build
46+ run : cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
47+
48+ - name : Test
49+ working-directory : ${{github.workspace}}/build
50+ run : ctest -C ${{env.BUILD_TYPE}}
Original file line number Diff line number Diff line change @@ -10,4 +10,8 @@ if(WIN32)
1010 target_compile_definitions (rest PRIVATE _WIN32_WINNT=0x0601)
1111endif ()
1212
13+ set (THREADS_PREFER_PTHREAD_FLAG ON )
14+ find_package (Threads REQUIRED)
15+ target_link_libraries (rest PRIVATE Threads::Threads)
16+
1317target_link_libraries (rest PUBLIC controller)
You can’t perform that action at this time.
0 commit comments