File tree Expand file tree Collapse file tree 2 files changed +66
-27
lines changed
Expand file tree Collapse file tree 2 files changed +66
-27
lines changed Original file line number Diff line number Diff line change 1+ name : Setup godot-cpp
2+ description : Setup build dependencies for godot-cpp.
3+
4+ inputs :
5+ platform :
6+ required : true
7+ description : Target platform.
8+ em-version :
9+ default : 3.1.62
10+ description : Emscripten version.
11+ windows-compiler :
12+ required : true
13+ description : The compiler toolchain to use on Windows ('mingw' or 'msvc').
14+ type : choice
15+ options :
16+ - mingw
17+ - msvc
18+ default : mingw
19+ mingw-version :
20+ default : 12.2.0
21+ description : MinGW version.
22+ ndk-version :
23+ default : r23c
24+ description : Android NDK version.
25+ scons-version :
26+ default : 4.4.0
27+ description : SCons version.
28+
29+ runs :
30+ using : composite
31+ steps :
32+ - name : Setup Python (for SCons)
33+ uses : actions/setup-python@v5
34+ with :
35+ python-version : 3.x
36+
37+ - name : Setup Android dependencies
38+ if : inputs.platform == 'android'
39+ uses : nttld/setup-ndk@v1
40+ with :
41+ ndk-version : ${{ inputs.ndk-version }}
42+ link-to-sdk : true
43+
44+ - name : Setup Web dependencies
45+ if : inputs.platform == 'web'
46+ uses : mymindstorm/setup-emsdk@v14
47+ with :
48+ version : ${{ inputs.em-version }}
49+ no-cache : true
50+
51+ - name : Setup MinGW for Windows/MinGW build
52+ if : inputs.platform == 'windows' && inputs.windows-compiler == 'mingw'
53+ uses : egor-tensin/setup-mingw@v2
54+ with :
55+ version : ${{ inputs.mingw-version }}
56+
57+ - name : Setup SCons
58+ shell : bash
59+ run : |
60+ python -c "import sys; print(sys.version)"
61+ python -m pip install scons==${{ inputs.scons-version }}
62+ scons --version
Original file line number Diff line number Diff line change @@ -105,34 +105,11 @@ jobs:
105105 cache-name : ${{ matrix.cache-name }}
106106 continue-on-error : true
107107
108- - name : Set up Python (for SCons)
109- uses : actions/setup-python@v5
108+ - name : Setup godot-cpp
109+ uses : ./.github/ actions/setup-godot-cpp
110110 with :
111- python-version : 3.x
112-
113- - name : Android dependencies
114- if : matrix.platform == 'android'
115- uses : nttld/setup-ndk@v1
116- with :
117- ndk-version : r23c
118- link-to-sdk : true
119-
120- - name : Web dependencies
121- if : matrix.platform == 'web'
122- uses : mymindstorm/setup-emsdk@v14
123- with :
124- version : ${{ env.EM_VERSION }}
125- no-cache : true
126-
127- - name : Setup MinGW for Windows/MinGW build
128- if : matrix.platform == 'windows' && matrix.flags == 'use_mingw=yes'
129- uses : egor-tensin/setup-mingw@v2
130- with :
131- version : 12.2.0
132-
133- - name : Install scons
134- run : |
135- python -m pip install scons==4.0.0
111+ platform : ${{ matrix.platform }}
112+ windows-compiler : ${{ contains(matrix.flags, 'use_mingw=yes') && 'mingw' || 'msvc' }}
136113
137114 - name : Generate godot-cpp sources only
138115 run : |
You can’t perform that action at this time.
0 commit comments