3 # build on c/cpp changes or workflow changes
15 - '.github/workflows/**.yml'
28 - '.github/workflows/**.yml'
33 # This is our minor gcc compiler
37 - uses: actions/checkout@v2
40 source ./util/ci/common.sh
41 install_linux_deps g++-6
52 ./bin/minetest --run-unittests
54 # This is the current gcc compiler (available in bionic)
58 - uses: actions/checkout@v2
61 source ./util/ci/common.sh
62 install_linux_deps g++-8
73 ./bin/minetest --run-unittests
75 # This is our minor clang compiler
79 - uses: actions/checkout@v2
82 source ./util/ci/common.sh
83 install_linux_deps clang-3.9 gdb
94 ./bin/minetest --run-unittests
96 - name: Integration test + devtest
98 ./util/test_multiplayer.sh
100 # This is the current clang version
102 runs-on: ubuntu-18.04
104 - uses: actions/checkout@v2
107 source ./util/ci/common.sh
108 install_linux_deps clang-9 valgrind libluajit-5.1-dev
116 CMAKE_FLAGS: "-DREQUIRE_LUAJIT=1"
120 ./bin/minetest --run-unittests
124 valgrind --leak-check=full --leak-check-heuristics=all --undef-value-errors=no --error-exitcode=9 ./bin/minetest --run-unittests
126 # Build with prometheus-cpp (server-only)
128 name: "clang_9 (PROMETHEUS=1)"
129 runs-on: ubuntu-18.04
131 - uses: actions/checkout@v2
134 source ./util/ci/common.sh
135 install_linux_deps --old-irr clang-9
137 - name: Build prometheus-cpp
139 ./util/ci/build_prometheus_cpp.sh
147 CMAKE_FLAGS: "-DENABLE_PROMETHEUS=1 -DBUILD_CLIENT=0"
151 ./bin/minetestserver --run-unittests
155 runs-on: ubuntu-18.04
157 - uses: actions/checkout@v2
158 - name: Build docker image
160 docker build . -t minetest:latest
161 docker run --rm minetest:latest /usr/local/bin/minetestserver --version
164 name: "MinGW cross-compiler (32-bit)"
165 runs-on: ubuntu-18.04
167 - uses: actions/checkout@v2
168 - name: Install compiler
170 sudo apt-get update -q && sudo apt-get install gettext -qyy
171 wget http://minetest.kitsunemimi.pw/mingw-w64-i686_9.2.0_ubuntu18.04.tar.xz -O mingw.tar.xz
172 sudo tar -xaf mingw.tar.xz -C /usr
176 EXISTING_MINETEST_DIR=$PWD ./util/buildbot/buildwin32.sh winbuild
182 name: "MinGW cross-compiler (64-bit)"
183 runs-on: ubuntu-18.04
185 - uses: actions/checkout@v2
186 - name: Install compiler
188 sudo apt-get update -q && sudo apt-get install gettext -qyy
189 wget http://minetest.kitsunemimi.pw/mingw-w64-x86_64_9.2.0_ubuntu18.04.tar.xz -O mingw.tar.xz
190 sudo tar -xaf mingw.tar.xz -C /usr
194 EXISTING_MINETEST_DIR=$PWD ./util/buildbot/buildwin64.sh winbuild
200 name: VS 2019 ${{ matrix.config.arch }}-${{ matrix.type }}
201 runs-on: windows-2019
202 #### Disabled due to Irrlicht switch
204 #### Disabled due to Irrlicht switch
206 VCPKG_VERSION: 0bf3923f9fab4001c00f0f429682a0853b5749e0
208 vcpkg_packages: irrlicht zlib zstd curl[winssl] openal-soft libvorbis libogg sqlite3 freetype luajit
215 generator: "-G'Visual Studio 16 2019' -A Win32",
216 vcpkg_triplet: x86-windows
220 generator: "-G'Visual Studio 16 2019' -A x64",
221 vcpkg_triplet: x64-windows
224 # type: [portable, installer]
225 # The installer type is working, but disabled, to save runner jobs.
226 # Enable it, when working on the installer.
230 uses: actions/checkout@v2
232 - name: Restore from cache and run vcpkg
233 uses: lukka/run-vcpkg@v5
235 vcpkgArguments: ${{env.vcpkg_packages}}
236 vcpkgDirectory: '${{ github.workspace }}\vcpkg'
237 appendedCacheKey: ${{ matrix.config.vcpkg_triplet }}
238 vcpkgGitCommitId: ${{ env.VCPKG_VERSION }}
239 vcpkgTriplet: ${{ matrix.config.vcpkg_triplet }}
243 cmake ${{matrix.config.generator}} `
244 -DCMAKE_TOOLCHAIN_FILE="${{ github.workspace }}\vcpkg\scripts\buildsystems\vcpkg.cmake" `
245 -DCMAKE_BUILD_TYPE=Release `
246 -DENABLE_POSTGRESQL=OFF `
247 -DRUN_IN_PLACE=${{ contains(matrix.type, 'portable') }} .
250 run: cmake --build . --config Release
254 If ($env:TYPE -eq "installer")
256 cpack -G WIX -B "$env:GITHUB_WORKSPACE\Package"
258 ElseIf($env:TYPE -eq "portable")
260 cpack -G ZIP -B "$env:GITHUB_WORKSPACE\Package"
263 TYPE: ${{matrix.type}}
265 - name: Package Clean
266 run: rm -r $env:GITHUB_WORKSPACE\Package\_CPack_Packages
268 - uses: actions/upload-artifact@v1
270 name: msvc-${{ matrix.config.arch }}-${{ matrix.type }}