|
| 1 | +name: SSR for Windows, using MSYS2 |
| 2 | +on: [push, pull_request] |
| 3 | +jobs: |
| 4 | + build-win: |
| 5 | + runs-on: windows-latest |
| 6 | + defaults: |
| 7 | + run: |
| 8 | + shell: msys2 {0} |
| 9 | + env: |
| 10 | + MSYS: winsymlinks:native |
| 11 | + steps: |
| 12 | + - name: Install MSYS2 |
| 13 | + uses: msys2/setup-msys2@v2 |
| 14 | + with: |
| 15 | + msystem: UCRT64 |
| 16 | + install: >- |
| 17 | + git |
| 18 | + pacboy: >- |
| 19 | + asio:p |
| 20 | + autotools:p |
| 21 | + fftw:p |
| 22 | + fmt:p |
| 23 | + jack2:p |
| 24 | + libsndfile:p |
| 25 | + libmysofa:p |
| 26 | + libxml2:p |
| 27 | + mesa:p |
| 28 | + nsis:p |
| 29 | + qt5-base:p |
| 30 | + vrpn:p |
| 31 | + yarn:p |
| 32 | + - name: checkout websocketpp |
| 33 | + uses: actions/checkout@v3 |
| 34 | + with: |
| 35 | + repository: zaphoyd/websocketpp |
| 36 | + path: websocketpp |
| 37 | + - name: Get SSR source code |
| 38 | + uses: actions/checkout@v3 |
| 39 | + with: |
| 40 | + submodules: true |
| 41 | + # This is required to be able to fetch tags, |
| 42 | + # see https://github.com/actions/checkout/issues/290: |
| 43 | + fetch-depth: 0 |
| 44 | + path: ssr |
| 45 | + - name: autogen |
| 46 | + working-directory: ssr |
| 47 | + run: | |
| 48 | + ./autogen.sh |
| 49 | + - name: fetch Git tags |
| 50 | + working-directory: ssr |
| 51 | + run: | |
| 52 | + # Fetch tags for obtaining the version number, |
| 53 | + # see https://github.com/actions/checkout/issues/290: |
| 54 | + git fetch --tags --force |
| 55 | + - name: configure |
| 56 | + working-directory: ssr |
| 57 | + run: | |
| 58 | + CONFIGURE_OPTIONS=( |
| 59 | + --enable-browser-gui |
| 60 | + --enable-fudi-interface |
| 61 | + --enable-gui |
| 62 | + --enable-ip-interface |
| 63 | + #--enable-polhemus |
| 64 | + #--enable-razor |
| 65 | + --enable-sofa |
| 66 | + #--enable-vrpn |
| 67 | + --enable-websocket-interface |
| 68 | + --enable-windows-installer |
| 69 | + --disable-ecasound |
| 70 | + --disable-intersense |
| 71 | + CPPFLAGS="-I/ucrt64/include -I`pwd`/../websocketpp -D_WEBSOCKETPP_CPP11_THREAD_" |
| 72 | + # TODO: move this to configure.ac: |
| 73 | + CFLAGS=-mwin32 |
| 74 | + LDFLAGS=-L/ucrt64/lib |
| 75 | + # TODO: move this to configure.ac: |
| 76 | + LIBS="-lws2_32 -lwsock32 -lglu32 -lopengl32" |
| 77 | + ) |
| 78 | + ./configure --disable-dependency-tracking "${CONFIGURE_OPTIONS[@]}" |
| 79 | + - name: upload config.log |
| 80 | + if: failure() |
| 81 | + uses: actions/upload-artifact@v3 |
| 82 | + with: |
| 83 | + name: config.log |
| 84 | + path: ssr/config.log |
| 85 | + - name: make |
| 86 | + working-directory: ssr |
| 87 | + run: | |
| 88 | + make |
| 89 | + - name: make nsis |
| 90 | + working-directory: ssr |
| 91 | + run: | |
| 92 | + make nsis |
| 93 | + - name: upload installer |
| 94 | + uses: actions/upload-artifact@v3 |
| 95 | + with: |
| 96 | + # TODO: upload the actual installer |
| 97 | + name: ssr-installer |
| 98 | + path: ssr/windows-installer |
0 commit comments