-
Notifications
You must be signed in to change notification settings - Fork 260
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add a new windows workflow based on msys2 (#1316)
- Loading branch information
Showing
1 changed file
with
75 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
name: Fluidsynth Windows | ||
|
||
on: | ||
pull_request: | ||
push: | ||
paths-ignore: | ||
- '.azure/**' | ||
- '.circleci/**' | ||
- '.github/workflows/sonarcloud.yml' | ||
- '.cirrus.yml' | ||
- 'README.md' | ||
|
||
env: | ||
BUILD_TYPE: RelWithDebInfo | ||
INSTALL_LOCATION: fluidsynth_install | ||
|
||
jobs: | ||
build: | ||
runs-on: windows-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: | ||
- { icon: '⬛', sys: mingw32 } | ||
- { icon: '🟦', sys: mingw64 } | ||
- { icon: '🟨', sys: ucrt64 } | ||
- { icon: '🟧', sys: clang64 } | ||
name: 🚧${{ matrix.icon }} ${{ matrix.sys }} | ||
defaults: | ||
run: | ||
shell: msys2 {0} | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: '${{ matrix.icon }} Setup MSYS2' | ||
uses: msys2/setup-msys2@v2 | ||
with: | ||
release: false | ||
msystem: ${{matrix.sys}} | ||
install: >- | ||
make | ||
libreadline | ||
pacboy: >- | ||
toolchain:p | ||
cmake:p | ||
ninja:p | ||
glib2:p | ||
libsndfile:p | ||
- name: '${{ matrix.icon }} Configure CMake' | ||
run: cmake -B build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_INSTALL_PREFIX=${{env.INSTALL_LOCATION}} | ||
|
||
- name: '${{ matrix.icon }} Build' | ||
run: cmake --build build --config ${{env.BUILD_TYPE}} | ||
|
||
#- name: '${{ matrix.icon }} Test' | ||
# run: cmake --build build --target check | ||
|
||
- name: '${{ matrix.icon }} Demo' | ||
run: cmake --build build --target demo | ||
|
||
- name: '${{ matrix.icon }} Install' | ||
run: cmake --install build && ls -la $INSTALL_LOCATION | ||
|
||
- name: '${{ matrix.icon }} Create Archive' | ||
run: tar cvf ${{env.INSTALL_LOCATION}}.tar ${{env.INSTALL_LOCATION}} | ||
|
||
- name: '${{ matrix.icon }} Upload Artifacts' | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: ${{env.INSTALL_LOCATION}}-${{matrix.sys}} | ||
path: ${{env.INSTALL_LOCATION}}.tar | ||
retention-days: 90 | ||
overwrite: true |