aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorGravatar Chris Xiong <chirs241097@gmail.com> 2020-11-14 03:01:29 +0800
committerGravatar Chris Xiong <chirs241097@gmail.com> 2020-11-14 03:01:29 +0800
commit8ea9ca158e8a113f38c22fbfa93ad99277b51d26 (patch)
tree6be63091c6fe895bd75f3a98f20702ca38da4479 /.github
parent529bfd4d8a40981dabb248022a99f1307b11b81b (diff)
downloadQMidiPlayer-8ea9ca158e8a113f38c22fbfa93ad99277b51d26.tar.xz
Add Windows CI courtesy of @BLumia.
Squashed commit of the following: commit f4f3bb2de34de497502e5fcc85a2404634f20620 Author: Gary Wang <wzc782970009@gmail.com> Date: Fri Nov 13 22:06:19 2020 +0800 Update windows-msys2.yml commit 7f461cf24aaaf4ee7379157327a406f409adcdef Author: Gary Wang <wzc782970009@gmail.com> Date: Fri Nov 13 21:37:07 2020 +0800 Update windows-msys2.yml commit 2636ea029927c40e4e72168f7669314ced1bc624 Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 23:00:43 2020 +0800 Update windows-msys2.yml commit 5fae2b1de295f614864d4403d9104ce6f01b951a Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 22:29:08 2020 +0800 Update windows-msys2.yml commit 748e4c4e5118120f1393a75b912d9dfc78ea9b50 Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 19:39:52 2020 +0800 Update windows-msys2.yml commit 1b4b048d80b2573c7ae19ae3695e3f56e43be3e9 Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 14:16:55 2020 +0800 Update windows-msys2.yml commit fc39ea6088522c7604e4e3cd9f4be1facc7460b3 Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 13:50:30 2020 +0800 Update windows-msys2.yml commit 91af4cc3213d11002a8e7b500a66e5af8a8d0f86 Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 13:43:05 2020 +0800 Update windows-msys2.yml commit 3fd1ad4a18a31e307f332a272d6e12ad31957234 Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 13:20:32 2020 +0800 Update windows-msys2.yml commit d093a45e98502180b746933e1b429e9c302a9d6b Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 12:54:56 2020 +0800 Update windows-msys2.yml commit 896a9c60f5a81ee1411e8b92dc80fc63abe5810b Author: Gary Wang <wzc782970009@gmail.com> Date: Thu Nov 12 00:00:05 2020 +0800 Update windows-msys2.yml commit 5d8381bd3e1ad03bd1d5efc3795e89de4c52545c Author: Gary Wang <wzc782970009@gmail.com> Date: Wed Nov 11 23:34:33 2020 +0800 Update windows-msys2.yml commit 42182bd553f666a1aba023a847505fd4e52062d0 Author: Gary Wang <wzc782970009@gmail.com> Date: Wed Nov 11 23:26:54 2020 +0800 Update windows-msys2.yml commit 704d2b0f385a1ae62238e8a118b8cdebfab800ea Author: Gary Wang <wzc782970009@gmail.com> Date: Wed Nov 11 23:14:51 2020 +0800 Update windows-msys2.yml commit 4e19b40ff8aaacbecf6825fc39092454f213ff98 Author: Gary Wang <wzc782970009@gmail.com> Date: Wed Nov 11 23:01:34 2020 +0800 Create windows-msys2.yml
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/windows-msys2.yml128
1 files changed, 128 insertions, 0 deletions
diff --git a/.github/workflows/windows-msys2.yml b/.github/workflows/windows-msys2.yml
new file mode 100644
index 0000000..f2e5285
--- /dev/null
+++ b/.github/workflows/windows-msys2.yml
@@ -0,0 +1,128 @@
+name: Windows MSYS2 Build
+on: [push, pull_request]
+
+jobs:
+ build:
+ runs-on: windows-latest
+ defaults:
+ run:
+ shell: msys2 {0}
+ steps:
+ - uses: actions/checkout@v2
+ with:
+ submodules: true
+ - uses: msys2/setup-msys2@v2
+ with:
+ msystem: MINGW64
+ update: true
+ install: >-
+ git mingw-w64-x86_64-toolchain mingw-w64-x86_64-ninja mingw-w64-x86_64-cmake tree
+ mingw-w64-x86_64-qt5
+ mingw-w64-x86_64-glfw mingw-w64-x86_64-glew mingw-w64-x86_64-freetype mingw-w64-x86_64-devil mingw-w64-x86_64-freeglut mingw-w64-x86_64-zlib
+ - name: Build fluidsynth-sans-glib
+ id: build-fluidsynth-sans-glib
+ continue-on-error: true
+ run: |
+ # no longer need mingw-w64-x86_64-fluidsynth and libglib-2.0-0.dll then.
+ mkdir dept_workspace && cd dept_workspace
+ git clone --depth=1 https://github.com/chirs241097/fluidsynth-sans-glib.git
+ cd fluidsynth-sans-glib && mkdir build && cd build
+ cmake .. -G Ninja -DCMAKE_INSTALL_PREFIX=$MINGW_PREFIX
+ cmake --build . --target install
+ cd ../../../
+ - name: Install mingw-w64-x86_64-fluidsynth if needed
+ if: steps.build-fluidsynth-sans-glib.outcome == 'failure'
+ run: |
+ pacman --noconfirm -S mingw-w64-x86_64-fluidsynth
+ - name: Build rtmidi
+ run: |
+ # mkdir dept_workspace
+ cd dept_workspace
+ git clone --depth=1 https://github.com/thestk/rtmidi.git
+ cd rtmidi && mkdir build && cd build
+ cmake .. -G Ninja -DCMAKE_INSTALL_PREFIX=$MINGW_PREFIX
+ cmake --build . --target install
+ cd ../../../
+ - name: Build qmidiplayer
+ run: |
+ mkdir build && cd build
+ cmake .. -G Ninja
+ cmake --build .
+ tree
+ cd ..
+ - name: package qmidiplayer
+ run: |
+ mkdir package_workspace && cd package_workspace
+ cp ../build/qmidiplayer-desktop/qmidiplayer.exe ./
+ windeployqt --no-quick-import --no-translations --no-opengl-sw --no-angle --no-system-d3d-compiler ./qmidiplayer.exe
+ # direct depts
+ cp $MINGW_PREFIX/bin/libfluidsynth-2.dll ./
+ cp $MINGW_PREFIX/bin/librtmidi.dll ./
+ cp $MINGW_PREFIX/bin/libportaudio-2.dll ./
+ # standalone visualization renderer
+ cp ../build/visualization/renderer/qmpvisrender.exe ./
+ # copy plugins
+ mkdir plugins
+ cp ../build/midifmt-plugin/libmidifmt-plugin.dll ./plugins/
+ cp ../build/simple-visualization/libsimple-visualization.dll ./plugins/
+ cp ../build/visualization/libvisualization.dll ./plugins/
+ cp ../build/sample-plugin/libsampleplugin.dll ./plugins/
+ # visualization plugin depts
+ cp $MINGW_PREFIX/bin/glfw3.dll ./
+ cp $MINGW_PREFIX/bin/glew32.dll ./
+ cp $MINGW_PREFIX/bin/zlib1.dll ./
+ cp $MINGW_PREFIX/bin/libfreetype-6.dll ./
+ cp $MINGW_PREFIX/bin/libIL.dll ./
+ cp $MINGW_PREFIX/bin/libHalf-2_5.dll ./
+ cp $MINGW_PREFIX/bin/libIlmImf-2_5.dll ./
+ cp $MINGW_PREFIX/bin/libjasper-4.dll ./
+ cp $MINGW_PREFIX/bin/libjpeg-8.dll ./
+ cp $MINGW_PREFIX/bin/liblcms2-2.dll ./
+ cp $MINGW_PREFIX/bin/libsquish.dll ./
+ cp $MINGW_PREFIX/bin/libtiff-5.dll ./
+ cp $MINGW_PREFIX/bin/libIex-2_5.dll ./
+ cp $MINGW_PREFIX/bin/libIlmThread-2_5.dll ./
+ cp $MINGW_PREFIX/bin/libImath-2_5.dll ./
+ cp $MINGW_PREFIX/bin/libgomp-1.dll ./
+ cp $MINGW_PREFIX/bin/liblzma-5.dll ./
+ # some other dlls
+ cp $MINGW_PREFIX/bin/libgcc_s_seh-1.dll ./
+ cp $MINGW_PREFIX/bin/libwinpthread-1.dll ./
+ cp $MINGW_PREFIX/bin/libstdc++-6.dll ./
+ cp $MINGW_PREFIX/bin/libintl-8.dll ./
+ cp $MINGW_PREFIX/bin/libpng16-16.dll ./
+ cp $MINGW_PREFIX/bin/libsndfile-1.dll ./
+ cp $MINGW_PREFIX/bin/libreadline8.dll ./
+ cp $MINGW_PREFIX/bin/libpcre2-16-0.dll ./
+ cp $MINGW_PREFIX/bin/libpcre-1.dll ./
+ cp $MINGW_PREFIX/bin/libharfbuzz-0.dll ./
+ cp $MINGW_PREFIX/bin/libdouble-conversion.dll ./
+ cp $MINGW_PREFIX/bin/libicuuc67.dll ./
+ cp $MINGW_PREFIX/bin/libicudt67.dll ./
+ cp $MINGW_PREFIX/bin/libicuin67.dll ./
+ cp $MINGW_PREFIX/bin/libzstd.dll ./
+ cp $MINGW_PREFIX/bin/libFLAC-8.dll ./
+ cp $MINGW_PREFIX/bin/libogg-0.dll ./
+ cp $MINGW_PREFIX/bin/libtermcap-0.dll ./
+ cp $MINGW_PREFIX/bin/libopus-0.dll ./
+ cp $MINGW_PREFIX/bin/libvorbis-0.dll ./
+ cp $MINGW_PREFIX/bin/libvorbis-0.dll ./
+ cp $MINGW_PREFIX/bin/libvorbisenc-2.dll ./
+ cp $MINGW_PREFIX/bin/libgraphite2.dll ./
+ cp $MINGW_PREFIX/bin/libiconv-2.dll ./
+ cp $MINGW_PREFIX/bin/libbz2-1.dll ./
+ cp $MINGW_PREFIX/bin/libbrotlidec.dll ./
+ cp $MINGW_PREFIX/bin/libbrotlicommon.dll ./
+ # license file
+ cp ../COPYING ./
+ # done
+ cd ../
+ - name: install libglib-2.0-0.dll if needed
+ if: steps.build-fluidsynth-sans-glib.outcome == 'failure'
+ run: |
+ cd package_workspace
+ cp $MINGW_PREFIX/bin/libglib-2.0-0.dll ./
+ - uses: actions/upload-artifact@v2
+ with:
+ name: msys2-mingw-w64-x86_64-windows
+ path: package_workspace/*