Skip to content

Commit fa45f16

Browse files
committed
Added MinGW CI job
1 parent b317753 commit fa45f16

File tree

2 files changed

+42
-3
lines changed

2 files changed

+42
-3
lines changed

.github/workflows/ci-workflow.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,3 +70,42 @@ jobs:
7070
with:
7171
name: premake-windows-${{ matrix.platform }}
7272
path: bin\${{ matrix.config }}\
73+
mingw:
74+
runs-on: windows-2022
75+
strategy:
76+
matrix:
77+
config: [debug, release]
78+
msystem: [mingw32, mingw64]
79+
include:
80+
- platform: x86
81+
msystem: mingw32
82+
- platform: x64
83+
msystem: mingw64
84+
defaults:
85+
run:
86+
shell: msys2 {0}
87+
steps:
88+
- name: Checkout
89+
uses: actions/checkout@v2
90+
- name: 'Setup MSYS2'
91+
uses: msys2/setup-msys2@v2
92+
with:
93+
msystem: ${{ matrix.msystem }}
94+
update: true
95+
install: >-
96+
git
97+
make
98+
pacboy: >-
99+
toolchain:p
100+
- name: Build
101+
run: make -f Bootstrap.mak mingw PLATFORM=${{ matrix.platform }} CONFIG=${{ matrix.config }}
102+
- name: Test
103+
run: bin/${{ matrix.config }}/premake5.exe test --test-all
104+
- name: Docs check
105+
run: bin/${{ matrix.config }}/premake5.exe docs-check
106+
- name: Upload Artifacts
107+
if: matrix.config == 'release'
108+
uses: actions/upload-artifact@v2
109+
with:
110+
name: premake-${{ matrix.msystem }}-${{ matrix.platform }}
111+
path: bin\${{ matrix.config }}\

Bootstrap.mak

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,14 +81,14 @@ windows-clean:
8181
$(SILENT) if exist .\build rmdir /s /q .\build
8282
$(SILENT) if exist .\obj rmdir /s /q .\obj
8383

84-
mingw-clean: windows-clean
84+
mingw-clean: nix-clean
8585

8686
mingw: mingw-clean
87-
if not exist build\bootstrap (mkdir build\bootstrap)
87+
mkdir -p build/bootstrap
8888
$(CC) -o build/bootstrap/premake_bootstrap -DPREMAKE_NO_BUILTIN_SCRIPTS -I"$(LUA_DIR)" -I"$(LUASHIM_DIR)" $(SRC) -lole32 -lversion
8989
./build/bootstrap/premake_bootstrap embed
9090
./build/bootstrap/premake_bootstrap --arch=$(PLATFORM) --os=windows --to=build/bootstrap --cc=mingw gmake2
91-
$(MAKE) -C build/bootstrap config=$(CONFIG)_$(PLATFORM:x86=win32)
91+
$(MAKE) -C build/bootstrap -j`getconf _NPROCESSORS_ONLN` config=$(CONFIG)_$(PLATFORM:x86=win32)
9292

9393
macosx: osx
9494

0 commit comments

Comments
 (0)