Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/.github/workflows/package-manager-builds.yaml
blob: 1c5bb2cc6f11af506c5ab9275a3841ed999c8448 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Package Manager Builds

on: [push, pull_request]

permissions:
  contents: read

jobs:
  conan_builds:
    name: Conan on ${{ matrix.os }}
    runs-on: ${{matrix.os}}
    strategy:
      fail-fast: false
      matrix:
        # Conan's detected MSVC runtime targets the VS 2022 (v143) toolset.
        os: [macos-15, windows-2022]

    steps:
    - uses: actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
      with:
        persist-credentials: false

    - name: Install conan
      run: python -m pip install --requirement requirements-conan.txt

    - name: Detect a Clang-based Conan profile
      run: conan profile detect --force
      env:
        CC: ${{ runner.os == 'Windows' && 'clang-cl' || 'clang' }}
        CXX: ${{ runner.os == 'Windows' && 'clang-cl' || 'clang++' }}

    - name: Run conan package create on macOS
      if: runner.os == 'macOS'
      run: conan create . -tf .conan/test_package
      env:
        CC: clang
        CXX: clang++

    - name: Run conan package create with Visual Studio ClangCL
      if: runner.os == 'Windows'
      # The VS 2022 image ships the v144 CRT. Conan's generic clang profile
      # otherwise picks v143 and MinGW Makefiles, which cannot link that CRT.
      run: conan create . -tf .conan/test_package -s compiler.runtime_version=v144 -c "tools.cmake.cmaketoolchain:generator=Visual Studio 17 2022"
      env:
        CC: clang-cl
        CXX: clang-cl