diff options
author | Raphaël Zumer <rzumer@tebako.net> | 2019-12-12 15:44:34 -0500 |
---|---|---|
committer | Raphaël Zumer <rzumer@tebako.net> | 2019-12-12 21:35:19 -0500 |
commit | 546e7ded96f88d92b6c7654b1bf73eee7e272d8a (patch) | |
tree | f71f8415d4caa096e6a50755fa77d9a51ce46089 | |
parent | 469ff2d932f21efbf2f4693625e130f2c62a7421 (diff) |
Add Windows CI configuration
-rw-r--r-- | .github/workflows/build-windows.yml | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml new file mode 100644 index 0000000..1b91df3 --- /dev/null +++ b/.github/workflows/build-windows.yml @@ -0,0 +1,34 @@ +name: CMake Build (Windows x86-64) + +on: [push, pull_request] + +env: + BUILD_TYPE: Release + +jobs: + build: + + runs-on: windows-latest + + steps: + - uses: actions/checkout@v1 + - name: Install MSYS2 + working-directory: ${{runner.workspace}} + run: | # Fetch MSYS2 build from XQEmu. Official distribution causes a CI failure due to permission errors. + Invoke-WebRequest -Uri "https://github.com/xqemu/ci-environment-msys2/releases/latest/download/msys64.7z" -OutFile "msys64.7z" + 7z x -y msys64.7z "-oC:\tools\" + C:\tools\msys64\usr\bin\bash.exe -lc "pacman -Syuq --noconfirm" + - name: Install dependencies + run: C:\tools\msys64\usr\bin\bash.exe -lc "pacman -Sq --noconfirm git make mingw-w64-x86_64-{cmake,mesa,SDL2,toolchain}" + - name: Create build environment + run: | + New-Item -ItemType directory -Path ${{runner.workspace}}\melonDS\build + Copy-Item -Path ${{runner.workspace}}\melonDS -Destination C:\tools\msys64\home\runneradmin -Recurse + - name: Configure + run: | + C:\tools\msys64\usr\bin\bash.exe -lc "export PATH=`"/mingw64/bin:`$PATH`" \ + && cd melonDS/build && cmake .. -G 'MSYS Makefiles' -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}" + - name: Make + run: | + C:\tools\msys64\usr\bin\bash.exe -lc "export PATH=`"/mingw64/bin:`$PATH`" \ + && cd melonDS/build && make -j$(nproc --all)" |