From 3961ca7a42016200e0c808f20c2319835b163db8 Mon Sep 17 00:00:00 2001 From: Edgar Date: Fri, 10 Mar 2023 10:40:27 +0100 Subject: [PATCH] :bug: Fixed CI build --- .github/workflows/main.yml | 32 ++++++++++------------- .github/workflows/sonarcloud.yml | 12 ++++----- .gitignore | 1 + tools/conan-profiles/vs-19-debug | 11 +++----- tools/conan-profiles/vs-19-debug-ninja | 8 +++--- tools/conan-profiles/vs-19-release | 11 +++----- tools/conan-profiles/vs-19-release-ninja | 8 +++--- tools/conan-profiles/vs-19-relwithdebinfo | 5 +--- tools/conan-profiles/vs-22-debug | 13 ++++----- tools/conan-profiles/vs-22-debug-ninja | 8 +++--- tools/conan-profiles/vs-22-release | 13 ++++----- tools/conan-profiles/vs-22-release-ninja | 8 +++--- tools/conan-profiles/vs-22-relwithdebinfo | 11 +++----- 13 files changed, 59 insertions(+), 82 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ac3622a..9c0d317 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -18,7 +18,7 @@ jobs: uses: actions/cache@v3.2.6 with: key: conan-win-${{ hashFiles('conanfile.txt') }} - path: ~/.conan/ + path: ~/.conan2/ - name: Install dependencies run: choco install conan ninja -y @@ -28,16 +28,15 @@ jobs: - name: Build run: | - conan config set storage.download_cache="$env:TMP" conan install . -b missing -pr:b=tools/conan-profiles/vs-22-release-ninja -pr=tools/conan-profiles/vs-22-release-ninja - cmake . -GNinja -DCMAKE_BUILD_TYPE=Release -DBUILD_TEST=ON -DCMAKE_TOOLCHAIN_FILE="conan_toolchain.cmake" -DCMAKE_POLICY_DEFAULT_CMP0091=NEW + cmake --preset conan-release -DBUILD_TEST=ON ninja - name: Test run: ctest -j2 --output-on-failure - name: Clean Conan pkgs - run: conan remove "*" -fsb + run: conan cache clean "*" -sbd build-gcc: name: Linux @@ -51,22 +50,20 @@ jobs: uses: actions/cache@v3.2.6 with: key: conan-linux-${{ hashFiles('conanfile.txt') }} - path: ~/.conan/ + path: ~/.conan2/ - name: Install dependencies run: | sudo apt-get update curl "https://raw.githubusercontent.com/AnotherFoxGuy/ci-scripts/main/install-cmake.sh" | sudo bash - curl "https://raw.githubusercontent.com/AnotherFoxGuy/ci-scripts/main/install-conan.sh" | sudo bash + curl "https://raw.githubusercontent.com/AnotherFoxGuy/ci-scripts/main/install-conan2.0.sh" | sudo bash sudo apt-get -y install ninja-build - name: Configure run: | - conan profile new --detect --force default - conan profile update conf.tools.cmake.cmaketoolchain:generator="Ninja" default - conan profile update settings.compiler.libcxx=libstdc++11 default - conan install . -s build_type=Release -b missing -pr:b=default - cmake . -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE="conan_toolchain.cmake" -DBUILD_TEST=ON + conan profile detect --force + conan install . -s build_type=Release -b missing -pr:b=default -c tools.cmake.cmaketoolchain:generator="Ninja" + cmake --preset conan-release -DBUILD_TEST=ON - name: Build run: | @@ -76,7 +73,7 @@ jobs: run: ctest -j2 --output-on-failure - name: Clean Conan pkgs - run: conan remove "*" -fsb + run: conan cache clean "*" -sbd build-appleclang: name: MacOS @@ -88,17 +85,16 @@ jobs: uses: actions/cache@v3.2.6 with: key: conan-mac-${{ hashFiles('conanfile.txt') }} - path: ~/.conan/ + path: ~/.conan2/ - name: Install dependencies run: brew install conan ninja - name: Build run: | - conan profile new --detect --force default - conan profile update conf.tools.cmake.cmaketoolchain:generator="Ninja" default - conan install . -s build_type=Release -b missing -pr:b=default - cmake . -GNinja -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE="conan_toolchain.cmake" -DBUILD_TEST=ON + conan profile detect --force + conan install . -s build_type=Release -b missing -pr:b=default -c tools.cmake.cmaketoolchain:generator="Ninja" + cmake --preset conan-release -DBUILD_TEST=ON ninja shell: bash @@ -107,4 +103,4 @@ jobs: shell: bash - name: Clean Conan pkgs - run: conan remove "*" -fsb \ No newline at end of file + run: conan cache clean "*" -sbd \ No newline at end of file diff --git a/.github/workflows/sonarcloud.yml b/.github/workflows/sonarcloud.yml index 664c290..5f1875a 100644 --- a/.github/workflows/sonarcloud.yml +++ b/.github/workflows/sonarcloud.yml @@ -45,20 +45,18 @@ jobs: uses: actions/cache@v3.2.6 with: key: conan-linux-${{ hashFiles('conanfile.txt') }} - path: ~/.conan/ + path: ~/.conan2/ - name: Install dependencies run: | curl "https://raw.githubusercontent.com/AnotherFoxGuy/ci-scripts/main/install-cmake.sh" | sudo bash - curl "https://raw.githubusercontent.com/AnotherFoxGuy/ci-scripts/main/install-conan.sh" | sudo bash + curl "https://raw.githubusercontent.com/AnotherFoxGuy/ci-scripts/main/install-conan2.0.sh" | sudo bash - name: Configure run: | - conan profile new --detect --force default - conan profile update conf.tools.cmake.cmaketoolchain:generator="Ninja" default - conan profile update settings.compiler.libcxx=libstdc++11 default + conan profile detect --force conan install . -s build_type=Release -b missing -pr:b=default - cmake . -DCMAKE_BUILD_TYPE=Release -DBUILD_TEST=ON -DENABLE_COVERAGE=ON -DCMAKE_TOOLCHAIN_FILE="conan_toolchain.cmake" + cmake --preset conan-release -DBUILD_TEST=ON -DENABLE_COVERAGE=ON - name: Run build-wrapper run: build-wrapper-linux-x86-64 --out-dir bw-output make -j4 @@ -77,4 +75,4 @@ jobs: run: ./run-sonar-scanner - name: Clean Conan pkgs - run: conan remove "*" -fsb \ No newline at end of file + run: conan cache clean "*" -sbd \ No newline at end of file diff --git a/.gitignore b/.gitignore index 07e1347..d9f971b 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,4 @@ docs/ build/ _build/ *.html +CMakeUserPresets.json diff --git a/tools/conan-profiles/vs-19-debug b/tools/conan-profiles/vs-19-debug index 3c74e3c..e2c293d 100644 --- a/tools/conan-profiles/vs-19-debug +++ b/tools/conan-profiles/vs-19-debug @@ -1,11 +1,8 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=16 +compiler=msvc +compiler.version=192 +compiler.runtime=dynamic +compiler.runtime_type=Debug build_type=Debug -[options] -[build_requires] -[env] diff --git a/tools/conan-profiles/vs-19-debug-ninja b/tools/conan-profiles/vs-19-debug-ninja index d058446..f3cdbf4 100644 --- a/tools/conan-profiles/vs-19-debug-ninja +++ b/tools/conan-profiles/vs-19-debug-ninja @@ -1,10 +1,10 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=16 +compiler=msvc +compiler.version=192 +compiler.runtime=dynamic +compiler.runtime_type=Debug build_type=Debug [conf] tools.cmake.cmaketoolchain:generator=Ninja \ No newline at end of file diff --git a/tools/conan-profiles/vs-19-release b/tools/conan-profiles/vs-19-release index 86b9f59..724f12a 100644 --- a/tools/conan-profiles/vs-19-release +++ b/tools/conan-profiles/vs-19-release @@ -1,11 +1,8 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=16 +compiler=msvc +compiler.version=192 +compiler.runtime=dynamic +compiler.runtime_type=Release build_type=Release -[options] -[build_requires] -[env] diff --git a/tools/conan-profiles/vs-19-release-ninja b/tools/conan-profiles/vs-19-release-ninja index b41104e..24be6d9 100644 --- a/tools/conan-profiles/vs-19-release-ninja +++ b/tools/conan-profiles/vs-19-release-ninja @@ -1,10 +1,10 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=16 +compiler=msvc +compiler.version=192 +compiler.runtime=dynamic +compiler.runtime_type=Release build_type=Release [conf] tools.cmake.cmaketoolchain:generator=Ninja \ No newline at end of file diff --git a/tools/conan-profiles/vs-19-relwithdebinfo b/tools/conan-profiles/vs-19-relwithdebinfo index cdb847a..4749266 100644 --- a/tools/conan-profiles/vs-19-relwithdebinfo +++ b/tools/conan-profiles/vs-19-relwithdebinfo @@ -5,7 +5,4 @@ arch=x86_64 arch_build=x86_64 compiler=Visual Studio compiler.version=16 -build_type=RelWithDebInfo -[options] -[build_requires] -[env] +build_type=RelWithDebInfo \ No newline at end of file diff --git a/tools/conan-profiles/vs-22-debug b/tools/conan-profiles/vs-22-debug index efa469c..30a6d9b 100644 --- a/tools/conan-profiles/vs-22-debug +++ b/tools/conan-profiles/vs-22-debug @@ -1,11 +1,8 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=17 -build_type=Debug -[options] -[build_requires] -[env] +compiler=msvc +compiler.version=193 +compiler.runtime=dynamic +compiler.runtime_type=Debug +build_type=Debug \ No newline at end of file diff --git a/tools/conan-profiles/vs-22-debug-ninja b/tools/conan-profiles/vs-22-debug-ninja index 56d4f28..5bd5d0e 100644 --- a/tools/conan-profiles/vs-22-debug-ninja +++ b/tools/conan-profiles/vs-22-debug-ninja @@ -1,10 +1,10 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=17 +compiler=msvc +compiler.version=193 +compiler.runtime=dynamic +compiler.runtime_type=Debug build_type=Debug [conf] tools.cmake.cmaketoolchain:generator=Ninja \ No newline at end of file diff --git a/tools/conan-profiles/vs-22-release b/tools/conan-profiles/vs-22-release index ea09b29..488df69 100644 --- a/tools/conan-profiles/vs-22-release +++ b/tools/conan-profiles/vs-22-release @@ -1,11 +1,8 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=17 -build_type=Release -[options] -[build_requires] -[env] +compiler=msvc +compiler.version=193 +compiler.runtime=dynamic +compiler.runtime_type=Release +build_type=Release \ No newline at end of file diff --git a/tools/conan-profiles/vs-22-release-ninja b/tools/conan-profiles/vs-22-release-ninja index e79ea48..0e917e1 100644 --- a/tools/conan-profiles/vs-22-release-ninja +++ b/tools/conan-profiles/vs-22-release-ninja @@ -1,10 +1,10 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=17 +compiler=msvc +compiler.version=193 +compiler.runtime=dynamic +compiler.runtime_type=Release build_type=Release [conf] tools.cmake.cmaketoolchain:generator=Ninja \ No newline at end of file diff --git a/tools/conan-profiles/vs-22-relwithdebinfo b/tools/conan-profiles/vs-22-relwithdebinfo index 18b14d0..4c63b3f 100644 --- a/tools/conan-profiles/vs-22-relwithdebinfo +++ b/tools/conan-profiles/vs-22-relwithdebinfo @@ -1,11 +1,8 @@ [settings] os=Windows -os_build=Windows arch=x86_64 -arch_build=x86_64 -compiler=Visual Studio -compiler.version=17 +compiler=msvc +compiler.version=193 +compiler.runtime=dynamic +compiler.runtime_type=RelWithDebInfo build_type=RelWithDebInfo -[options] -[build_requires] -[env]