Bump dependencies and improve workflows (#64) #25
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | name: Binaries | |
| on: [ push ] | |
| jobs: | |
| linux: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Conan Client | |
| uses: conan-io/setup-conan@v1 | |
| with: | |
| version: '2.21.0' | |
| cache_packages: true # automatically cache Conan packages | |
| - name: Install dependencies | |
| run: sudo apt update && sudo apt install --yes build-essential cmake ninja-build | |
| - name: Install Conan dependencies | |
| run: conan install . --build=missing -s compiler=gcc -s compiler.version=10 -s compiler.cppstd=20 -s build_type=Release | |
| - name: Configure project | |
| run: cmake -S . -B build -G Ninja -DWITH_BINARY=ON -DWITH_CONAN=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake | |
| - name: Build executable | |
| run: | | |
| cmake --build build --target caracal-bin | |
| mv build/caracal build/caracal-linux-amd64 | |
| - uses: actions/upload-artifact@v4.6.2 | |
| with: | |
| name: caracal-linux-amd64-${{ runner.os }} | |
| path: build/caracal-linux-amd64 | |
| macos: | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Conan Client | |
| uses: conan-io/setup-conan@v1 | |
| with: | |
| version: '2.21.0' | |
| cache_packages: true | |
| - name: Install dependencies | |
| run: brew install cmake ninja | |
| - name: Install Conan dependencies | |
| run: conan install . --build=missing -s compiler=apple-clang -s compiler.version=17 -s compiler.cppstd=20 -s build_type=Release | |
| - name: Configure project | |
| run: cmake -S . -B build -G Ninja -DWITH_BINARY=ON -DWITH_CONAN=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake | |
| - name: Build executable | |
| run: | | |
| cmake --build build --target caracal-bin | |
| mv build/caracal build/caracal-macos-amd64 | |
| - uses: actions/upload-artifact@v4.6.2 | |
| with: | |
| name: caracal-macos-amd64-${{ runner.os }} | |
| path: build/caracal-macos-amd64 | |
| release: | |
| needs: [ linux, macos ] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/download-artifact@v4.1.7 | |
| - uses: softprops/action-gh-release@v1 | |
| if: startsWith(github.ref, 'refs/tags/') | |
| with: | |
| files: artifact/* |