Skip to content

ci: Adjust for cmake #37

ci: Adjust for cmake

ci: Adjust for cmake #37

name: C/C++ CI and Release
on:
push:
workflow_dispatch: # Allow manual runs if needed
jobs:
build-and-release:
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.os == 'macos-latest' }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- os: ubuntu-latest
- os: windows-latest
extension: .exe
- os: macos-latest
steps:
- uses: actions/checkout@v4
# Set up MSYS2 environment and install MinGW on Windows
- name: Set up MSYS2 with MinGW
id: msys2
if: ${{ matrix.os == 'windows-latest' }}
uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: mingw-w64-x86_64-gcc
# Build step - uses appropriate compiler and args based on OS
- name: Build Project
run: |
mkdir build
cd build
cmake ..
make
- uses: actions/upload-artifact@v4
with:
name: Executable (${{ matrix.os }})
path: build/XanaduCLI${{ matrix.extension }}