shithub: rgbds

Download patch

ref: 04e7af2675b7287ace31a625f62e5d34695f60d4
parent: 4f13a336b9610c5a58bc1a63a04220a89d07253b
parent: 03508119e5e4c7e8dbc124ac34b5bb757e729309
author: Eldred Habert <[email protected]>
date: Fri Oct 2 19:30:26 EDT 2020

Merge pull request #579 from ISSOtm/cmake-ci

Enable CMake in CI

--- a/.github/workflows/testing.yml
+++ b/.github/workflows/testing.yml
@@ -9,10 +9,12 @@
       matrix:
         os: [ubuntu-20.04, ubuntu-18.04, ubuntu-16.04, macos-10.15]
         cc: [gcc, clang]
+        buildsys: [make, cmake]
         include:
           - os: ubuntu-18.04
             cc: gcc
             target: develop
+            cmakevars: -DDEVELOP=ON
       fail-fast: false
     runs-on: ${{ matrix.os }}
     steps:
@@ -21,12 +23,18 @@
         shell: bash
         run: |
           ./.github/actions/install_deps.sh ${{ matrix.os }}
-      - name: Build
+      - name: Build & install using Make
         run: |
           make ${{ matrix.target }} -j Q= CC=${{ matrix.cc }}
-      - name: Install
-        run: |
           sudo make install -j Q=
+        if: matrix.buildsys == 'make'
+      - name: Build & install using CMake
+        run: |
+          cmake -S . -B build -DCMAKE_VERBOSE_MAKEFILE=ON ${{ matrix.cmakevars }}
+          cmake --build build
+          cp build/src/rgb{asm,link,fix,gfx} .
+          sudo cmake --install build
+        if: matrix.buildsys == 'cmake'
       - name: Package binaries
         run: |
           mkdir bins
@@ -34,7 +42,7 @@
       - name: Upload binaries
         uses: actions/upload-artifact@v1
         with:
-          name: rgbds-canary-${{ matrix.os }}-${{ matrix.cc }}
+          name: rgbds-canary-${{ matrix.os }}-${{ matrix.cc }}-${{ matrix.buildsys }}
           path: bins
       - name: Test
         shell: bash