diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 10508bc71..506cc9bbb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -72,6 +72,67 @@ jobs: name: c3-windows-${{ matrix.build_type }} path: build\${{ matrix.build_type }}\c3c.exe + build-msvc-2019: + runs-on: windows-2019 + strategy: + # Don't abort runners if a single one fails + fail-fast: true + matrix: + build_type: [ Release, Debug ] + + defaults: + run: + shell: cmd + steps: + - uses: actions/checkout@v4 + + - name: CMake + run: | + cmake -B build -G "Visual Studio 16 2019" -A x64 -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} + cmake --build build --config ${{ matrix.build_type }} + + - name: Compile and run some examples + run: | + cd resources + ..\build\${{ matrix.build_type }}\c3c.exe compile-run examples\hello_world_many.c3 + ..\build\${{ matrix.build_type }}\c3c.exe compile-run examples\time.c3 + ..\build\${{ matrix.build_type }}\c3c.exe compile-run examples\fannkuch-redux.c3 + ..\build\${{ matrix.build_type }}\c3c.exe compile-run examples\contextfree\boolerr.c3 + ..\build\${{ matrix.build_type }}\c3c.exe compile-run examples\ls.c3 + ..\build\${{ matrix.build_type }}\c3c.exe compile-run examples\load_world.c3 + ..\build\${{ matrix.build_type }}\c3c.exe compile-run examples\process.c3 + ..\build\${{ matrix.build_type }}\c3c.exe compile --test -g -O0 --threads 1 --target macos-x64 examples\constants.c3 + + - name: Build testproject + run: | + cd resources/testproject + ..\..\build\${{ matrix.build_type }}\c3c.exe --debug-log run hello_world_win32 + + - name: Build testproject lib + run: | + cd resources/testproject + ..\..\build\${{ matrix.build_type }}\c3c.exe --debug-log build hello_world_win32_lib + + - name: Vendor-fetch + run: | + build\${{ matrix.build_type }}\c3c.exe vendor-fetch raylib + + - name: run compiler tests + run: | + cd test + python3.exe src/tester.py ..\build\${{ matrix.build_type }}\c3c.exe test_suite/ + + - name: Compile run unit tests + run: | + cd test + ..\build\${{ matrix.build_type }}\c3c.exe compile-test unit -O1 + + - name: upload artifacts + uses: actions/upload-artifact@v3 + with: + name: c3-windows-${{ matrix.build_type }} + path: build\${{ matrix.build_type }}\c3c.exe + build-msys2-mingw: runs-on: windows-latest strategy: