2019-10-28 20:53:45 +01:00
|
|
|
name: CI
|
2022-03-09 21:29:45 +01:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
paths-ignore:
|
|
|
|
- '.editorconfig'
|
|
|
|
- '.gitattributes'
|
|
|
|
- '.github/*_TEMPLATE/**'
|
|
|
|
- '.github/workflows/localisation.yml'
|
|
|
|
- '.gitignore'
|
|
|
|
- '.vscode/**'
|
|
|
|
pull_request:
|
|
|
|
paths-ignore:
|
|
|
|
- '.editorconfig'
|
|
|
|
- '.gitattributes'
|
|
|
|
- '.github/*_TEMPLATE/**'
|
|
|
|
- '.github/workflows/localisation.yml'
|
|
|
|
- '.gitignore'
|
|
|
|
- '.vscode/**'
|
2021-04-15 11:32:14 +02:00
|
|
|
defaults:
|
|
|
|
run:
|
|
|
|
shell: bash
|
2020-01-09 10:53:13 +01:00
|
|
|
env:
|
2020-01-19 15:04:59 +01:00
|
|
|
OPENRCT2_BUILD_SERVER: GitHub
|
2020-01-09 10:53:13 +01:00
|
|
|
OPENRCT2_ORG_TOKEN: ${{ secrets.OPENRCT2_ORG_TOKEN }}
|
2020-03-25 23:36:09 +01:00
|
|
|
BACKTRACE_IO_TOKEN: ${{ secrets.BACKTRACE_IO_TOKEN }}
|
Release v0.4.3
- Feature: [#17782] The Flying Coaster now has access to boosters and can draw outside loops.
- Feature: [#17997] The Log Flume can now draw steep pieces down (if vehicle allows it).
- Feature: [#18312, objects#220, OpenSFX#13] New sound effects for the Hybrid and Single Rail roller coasters.
- Feature: [#18675] [Plugin] Plugins can refer to g2 image icons by name.
- Feature: [objects#173] Add alpine coaster vehicle.
- Feature: [objects#221] Add two extra jungle walls.
- Feature: [objects#225] Add log cabin roofs.
- Feature: [OpenMusic#14, OpenMusic#15, OpenMusic#18] Added Galaxy, Acid and Dodgems ride music styles.
- Improved: [#18013, #18016, #18018, #18019, #18514, objects#224] Added colour presets to Spiral Slide, Dodgems, Boat Hire, Flying Saucers, and Car Ride.
- Improved: [#18024] Clearer error messages when loading incompatible .park files.
- Improved: [#18192] Tycoon Park has been added to the Extras tab.
- Improved: [#18214] Competition scenarios have received their own section.
- Improved: [#18250] Added modern style file and folder pickers on Windows.
- Improved: [#18332] Allow Inverted Roller Coaster to draw boosters.
- Improved: [#18350] Changed ride vehicle list to have less padding.
- Improved: [#18422] Allow adding images to music objects.
- Improved: [#18428] [Plugin] Add widget description interfaces to documentation.
- Improved: [#18487] Mini Helicopters track can now draw spinning tunnels.
- Improved: [#18591] Order RollerCoaster Tycoon 2 scenarios by difficulty.
- Improved: [#18607] A new tab for all UCES Scenarios, if it’s installed.
- Improved: [#18621] OpenGL performance.
- Change: [#17677] Open campaign window from finished campaign news.
- Change: [#17998] Show cursor when using inverted mouse dragging.
- Change: [#18230] Make the large flat to steep pieces available on the corkscrew roller coaster without cheats.
- Change: [#18381] Convert custom invisible paths to the built-in ones.
- Change: [OpenSFX#11, OpenMusic#19] First implementation of official replacement asset packs for sound effects & music.
- Fix: [#1491] Clearance of the Cash Machine is too low (original bug).
- Fix: [#1519] “See-through rides” doesn't affect all rides (original bug).
- Fix: [#6341] “Unlock vehicle limits” does not allow setting fewer vehicles than the vehicle type requires.
- Fix: [#14312] Research ride type message incorrect.
- Fix: [#14425] Ride ratings do not skip unallocated ride ids.
- Fix: [#15969] Guests heading for ride use vanilla behaviour
- Fix: [#17067] Random Staff Patrol Area clicks.
- Fix: [#17316] Sides of River Rapids’ corners overlay other parts of the track.
- Fix: [#17657] When switching from buying land rights to buying construction rights, grid disables and won't re-enable afterwards.
- Fix: [#17763] Missing validation on invalid characters in file name.
- Fix: [#17853] Invention name tears while being dragged.
- Fix: [#18064] Unable to dismiss notification messages.
- Fix: [#18070] Underground entrance/exit shows through terrain walls (original bug).
- Fix: [#18094] Underground shops & facilities don't show when adjacent to non-underground path (original bug).
- Fix: [#18122] Ghosts count towards “Great scenery!” guest thought.
- Fix: [#18134] Underground on-ride photo section partially clips through adjacent terrain edge.
- Fix: [#18244] Invention DragWindow's starting position is inconsistent.
- Fix: [#18245] Guests stopping dead in their tracks at railway crossings.
- Fix: [#18257] Guests ‘waiting’ on extended railway crossings.
- Fix: [#18354] Overwrite alert does not show when save name has different casing on Windows.
- Fix: [#18379] Tunnel entrances for underground Mini Golf Hole E are not rendered correctly.
- Fix: [#18442] About window background is clickable.
- Fix: [#18449] [Plugin] Change type of listview widgets from 'scroll_view' to 'listview'.
- Fix: [#18453] Slow walking guests don't get across level crossings in time.
- Fix: [#18469] Land rights window buttons incorrectly disabled and markers remain visible indefinitely.
- Fix: [#18459] ‘Highlight path issues’ hides fences for paths with additions.
- Fix: [#18552] Trains clipping through helixes.
- Fix: [#18576] Cannot open parks with certain types of corrupt tile elements.
- Fix: [#18606] JSON objects do not take priority over the DAT files they supersede.
- Fix: [#18620] [Plugin] Crash when reading widget properties from windows that have both static and tab widgets.
- Fix: [#18653] Negative ratings multipliers do not appear in Vehicle tab.
- Fix: [#18696] Construction rights cannot be viewed after all are purchased.
- Fix: [#18720] Upwards helix is enabled for the Alpine Coaster, even when cheats are off.
- Fix: [#18755] Ferris Wheel and Circus ghosts not coloured correctly.
- Fix: [#18802] Game could crash when determining if a mechanic is heading to fix the ride blocking the path.
2022-12-14 13:22:08 +01:00
|
|
|
OPENRCT2_VERSION: 0.4.3
|
2022-11-04 08:21:23 +01:00
|
|
|
|
|
|
|
# https://docs.github.com/en/actions/using-jobs/using-concurrency#example-using-a-fallback-value
|
|
|
|
concurrency:
|
|
|
|
group: ${{ github.head_ref || github.run_id }}
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
2019-10-28 20:53:45 +01:00
|
|
|
jobs:
|
2020-05-02 02:04:06 +02:00
|
|
|
lint-commit:
|
|
|
|
name: Lint Commit Message
|
2020-09-09 18:03:45 +02:00
|
|
|
if: github.event_name == 'pull_request'
|
2020-05-02 02:04:06 +02:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2020-05-02 02:04:06 +02:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
- name: Lint Commit Messages
|
2021-04-15 12:45:22 +02:00
|
|
|
uses: wagoid/commitlint-github-action@v3
|
2020-05-02 02:04:06 +02:00
|
|
|
with:
|
|
|
|
configFile: .commitlint.json
|
2019-10-31 01:03:05 +01:00
|
|
|
check-code-formatting:
|
|
|
|
name: Check code formatting
|
|
|
|
runs-on: ubuntu-latest
|
2022-03-09 21:19:40 +01:00
|
|
|
container: openrct2/openrct2-build:4-format
|
2022-03-09 21:23:37 +01:00
|
|
|
defaults:
|
|
|
|
run:
|
|
|
|
shell: sh
|
2019-10-31 01:03:05 +01:00
|
|
|
steps:
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2019-10-31 01:03:05 +01:00
|
|
|
- name: Run clang-format
|
2020-01-24 12:46:12 +01:00
|
|
|
run: scripts/check-code-formatting
|
2020-01-16 14:17:17 +01:00
|
|
|
windows:
|
|
|
|
name: Windows
|
|
|
|
runs-on: windows-latest
|
2021-04-15 12:00:59 +02:00
|
|
|
needs: check-code-formatting
|
2020-01-16 14:17:17 +01:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2022-05-07 23:49:38 +02:00
|
|
|
platform: [win32, x64]
|
2020-01-16 14:17:17 +01:00
|
|
|
env:
|
|
|
|
CONFIGURATION: Release
|
|
|
|
PLATFORM: ${{ matrix.platform }}
|
|
|
|
steps:
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2022-04-20 21:37:52 +02:00
|
|
|
- name: Git describe for shallow checkout
|
|
|
|
id: ghd
|
|
|
|
uses: proudust/gh-describe@v1
|
|
|
|
- name: Update GA environment
|
|
|
|
run: echo "OPENRCT2_DESCRIBE=${{ steps.ghd.outputs.describe }}" >> $GITHUB_ENV
|
2022-04-01 11:02:48 +02:00
|
|
|
- name: Install MSVC problem matcher
|
|
|
|
uses: ammaraskar/msvc-problem-matcher@master
|
2020-01-19 15:04:59 +01:00
|
|
|
- name: Build OpenRCT2
|
|
|
|
run: . scripts/setenv && build
|
|
|
|
- name: Build artifacts
|
2020-01-16 14:17:17 +01:00
|
|
|
run: |
|
2020-01-19 15:04:59 +01:00
|
|
|
. scripts/setenv -q
|
|
|
|
build-portable
|
|
|
|
build-symbols
|
|
|
|
build-installer -i
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Upload artifacts (CI)
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/upload-artifact@v3
|
2020-01-16 14:17:17 +01:00
|
|
|
with:
|
2021-04-15 11:46:59 +02:00
|
|
|
name: OpenRCT2-${{ runner.os }}-${{ matrix.platform }}
|
|
|
|
path: artifacts
|
|
|
|
if-no-files-found: error
|
2020-01-19 15:04:59 +01:00
|
|
|
- name: Run Tests
|
2022-03-26 20:15:14 +01:00
|
|
|
if: matrix.platform != 'arm64'
|
2020-01-19 15:04:59 +01:00
|
|
|
run: . scripts/setenv -q && run-tests
|
2020-01-16 14:17:17 +01:00
|
|
|
- name: Upload artifacts (openrct2.org)
|
|
|
|
run: |
|
2020-01-19 15:04:59 +01:00
|
|
|
. scripts/setenv -q
|
|
|
|
if [[ "$OPENRCT2_PUSH" == "true" ]]; then
|
2022-03-09 21:53:23 +01:00
|
|
|
upload-build artifacts/openrct2-portable-*.zip "windows-portable-$PLATFORM" $OPENRCT2_VERSION $OPENRCT2_SHA1 $OPENRCT2_BRANCH
|
|
|
|
upload-build artifacts/openrct2-installer-*.exe "windows-installer-$PLATFORM" $OPENRCT2_VERSION $OPENRCT2_SHA1 $OPENRCT2_BRANCH
|
|
|
|
upload-build artifacts/openrct2-symbols-*.zip "windows-symbols-$PLATFORM" $OPENRCT2_VERSION $OPENRCT2_SHA1 $OPENRCT2_BRANCH
|
|
|
|
upload-backtrace-symbols artifacts/openrct2-symbols-*.zip
|
2020-01-19 15:04:59 +01:00
|
|
|
else
|
|
|
|
echo 'Not going to push build'
|
2020-01-16 14:17:17 +01:00
|
|
|
fi
|
2020-01-10 00:26:33 +01:00
|
|
|
windows-mingw:
|
2021-04-15 12:43:39 +02:00
|
|
|
name: Windows (${{ matrix.platform_name }}) using mingw
|
2020-09-27 20:30:13 +02:00
|
|
|
runs-on: ubuntu-latest
|
2021-04-15 12:00:59 +02:00
|
|
|
needs: check-code-formatting
|
2022-04-01 07:42:50 +02:00
|
|
|
container: openrct2/openrct2-build:8-mingw
|
2021-04-15 12:43:39 +02:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2022-05-21 00:05:29 +02:00
|
|
|
platform: [win32]
|
2021-04-15 12:43:39 +02:00
|
|
|
include:
|
|
|
|
- platform: win32
|
|
|
|
platform_name: win32
|
|
|
|
cache_key: windows-mingw
|
2022-05-21 00:05:29 +02:00
|
|
|
build_flags: -DBUILD_SHARED_LIBS=ON -DENABLE_SCRIPTING=ON
|
2020-09-27 20:30:13 +02:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-02-09 12:58:23 +01:00
|
|
|
- name: ccache
|
|
|
|
uses: hendrikmuhs/ccache-action@v1
|
2021-02-09 20:25:41 +01:00
|
|
|
with:
|
2021-04-15 12:43:39 +02:00
|
|
|
key: ${{ matrix.cache_key }}
|
2022-04-01 11:02:48 +02:00
|
|
|
- name: Install GCC problem matcher
|
|
|
|
uses: ammaraskar/gcc-problem-matcher@master
|
2020-09-27 20:30:13 +02:00
|
|
|
- name: Build OpenRCT2
|
|
|
|
run: |
|
|
|
|
sudo su
|
2022-03-09 21:56:33 +01:00
|
|
|
cmake -B bin -G Ninja -DCMAKE_TOOLCHAIN_FILE=../CMakeLists_mingw.txt -DCMAKE_BUILD_TYPE=Release -DDISABLE_IPO=on -DFORCE32=on ${{ matrix.build_flags }}
|
|
|
|
cd bin
|
2020-09-27 20:30:13 +02:00
|
|
|
ninja -k0
|
|
|
|
- name: Upload artifacts (CI)
|
2021-04-15 12:43:39 +02:00
|
|
|
if: matrix.platform == 'NT5.1'
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/upload-artifact@v3
|
2020-09-27 20:30:13 +02:00
|
|
|
with:
|
2022-03-09 21:56:33 +01:00
|
|
|
name: OpenRCT2-Windows-${{ matrix.platform }}
|
2020-09-27 20:30:13 +02:00
|
|
|
path: bin/openrct2.exe
|
2021-04-15 11:46:59 +02:00
|
|
|
if-no-files-found: error
|
2021-01-03 05:15:40 +01:00
|
|
|
macos-cmake:
|
2021-09-16 04:33:14 +02:00
|
|
|
name: macOS (${{ matrix.arch }}) using CMake
|
2021-01-03 05:15:40 +01:00
|
|
|
runs-on: macos-latest
|
2021-04-15 12:00:59 +02:00
|
|
|
needs: check-code-formatting
|
2021-09-13 01:33:34 +02:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2021-09-16 04:33:14 +02:00
|
|
|
arch: [x64, arm64]
|
2021-09-13 01:33:34 +02:00
|
|
|
include:
|
2021-09-16 04:33:14 +02:00
|
|
|
- arch: x64
|
2021-09-13 01:33:34 +02:00
|
|
|
cache_key: macos-x64
|
2021-09-16 04:33:14 +02:00
|
|
|
# Note: only build/run tests on the native architecture of the CI agent
|
2022-03-09 21:21:59 +01:00
|
|
|
# GitHub macos-latest agents are currently all Intel
|
2021-09-13 01:33:34 +02:00
|
|
|
build_flags: -DARCH="x86_64" -DWITH_TESTS=on
|
|
|
|
run_tests: true
|
|
|
|
- arch: arm64
|
|
|
|
cache_key: macos-arm64
|
|
|
|
build_flags: -DARCH="arm64"
|
|
|
|
run_tests: false
|
2021-01-03 05:15:40 +01:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-02-10 22:35:04 +01:00
|
|
|
- name: ccache
|
|
|
|
uses: hendrikmuhs/ccache-action@v1
|
|
|
|
with:
|
2021-09-13 01:33:34 +02:00
|
|
|
key: ${{ matrix.cache_key }}
|
2022-04-01 11:02:48 +02:00
|
|
|
- name: Install GCC problem matcher
|
|
|
|
uses: ammaraskar/gcc-problem-matcher@master
|
2021-01-03 05:15:40 +01:00
|
|
|
- name: Build OpenRCT2
|
2021-01-10 08:49:04 +01:00
|
|
|
run: |
|
2021-04-15 12:45:05 +02:00
|
|
|
HOMEBREW_NO_ANALYTICS=1 brew install ninja
|
2021-09-13 01:33:34 +02:00
|
|
|
. scripts/setenv -q && build -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=on ${{ matrix.build_flags }}
|
2021-01-03 05:15:40 +01:00
|
|
|
- name: Run Tests
|
2021-09-13 01:33:34 +02:00
|
|
|
if: ${{matrix.run_tests}}
|
2021-01-03 05:15:40 +01:00
|
|
|
run: . scripts/setenv -q && run-tests
|
2021-01-10 08:49:04 +01:00
|
|
|
- name: Build artifacts
|
2021-03-14 05:45:58 +01:00
|
|
|
run: |
|
|
|
|
. scripts/setenv
|
|
|
|
mkdir -p artifacts
|
|
|
|
mv bin/OpenRCT2.app artifacts
|
|
|
|
echo -e "\033[0;36mCompressing OpenRCT2.app...\033[0m"
|
|
|
|
cd artifacts
|
2021-03-21 23:42:19 +01:00
|
|
|
zip -rqy openrct2-macos.zip OpenRCT2.app
|
2021-03-14 05:45:58 +01:00
|
|
|
- name: Upload artifacts (CI)
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/upload-artifact@v3
|
2021-03-14 05:45:58 +01:00
|
|
|
with:
|
2021-09-13 01:33:34 +02:00
|
|
|
name: OpenRCT2-${{ runner.os }}-${{ matrix.arch }}-cmake
|
|
|
|
path: artifacts/openrct2-macos.zip
|
|
|
|
if-no-files-found: error
|
|
|
|
macos-universal:
|
|
|
|
name: macOS universal app bundle
|
|
|
|
runs-on: macos-latest
|
|
|
|
needs: macos-cmake
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-09-13 01:33:34 +02:00
|
|
|
- name: download x64 app bundle
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/download-artifact@v3
|
2021-09-13 01:33:34 +02:00
|
|
|
with:
|
2021-09-16 04:33:14 +02:00
|
|
|
name: OpenRCT2-${{ runner.os }}-x64-cmake
|
2021-09-13 01:33:34 +02:00
|
|
|
path: macos_universal/x64
|
|
|
|
- name: download arm64 app bundle
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/download-artifact@v3
|
2021-09-13 01:33:34 +02:00
|
|
|
with:
|
|
|
|
name: OpenRCT2-${{ runner.os }}-arm64-cmake
|
|
|
|
path: macos_universal/arm64
|
|
|
|
- name: Make Universal app bundle
|
|
|
|
run: |
|
|
|
|
. scripts/setenv
|
|
|
|
cd macos_universal
|
|
|
|
unzip x64/openrct2-macos.zip -d x64
|
|
|
|
unzip arm64/openrct2-macos.zip -d arm64
|
|
|
|
create-macos-universal
|
|
|
|
- name: Create artifact
|
|
|
|
run: |
|
|
|
|
. scripts/setenv
|
|
|
|
mkdir -p artifacts
|
|
|
|
mv macos_universal/OpenRCT2-universal.app artifacts/OpenRCT2.app
|
|
|
|
echo -e "\033[0;36mCompressing OpenRCT2.app...\033[0m"
|
|
|
|
cd artifacts
|
|
|
|
zip -rqy openrct2-macos.zip OpenRCT2.app
|
|
|
|
- name: Upload artifacts (CI)
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/upload-artifact@v3
|
2021-09-13 01:33:34 +02:00
|
|
|
with:
|
|
|
|
name: OpenRCT2-${{ runner.os }}-universal
|
2021-03-21 23:42:19 +01:00
|
|
|
path: artifacts/openrct2-macos.zip
|
2021-04-15 11:46:59 +02:00
|
|
|
if-no-files-found: error
|
2021-10-10 07:25:36 +02:00
|
|
|
- name: Upload artifacts (openrct2.org)
|
|
|
|
run: |
|
|
|
|
. scripts/setenv
|
|
|
|
if [[ "$OPENRCT2_PUSH" == "true" ]]; then
|
2022-03-09 21:53:23 +01:00
|
|
|
upload-build artifacts/openrct2-macos.zip macos $OPENRCT2_VERSION $OPENRCT2_SHA1 $OPENRCT2_BRANCH
|
2021-10-10 07:25:36 +02:00
|
|
|
else
|
2022-03-09 21:53:23 +01:00
|
|
|
echo 'Not going to push build'
|
2021-10-10 07:25:36 +02:00
|
|
|
fi
|
2020-01-24 12:46:12 +01:00
|
|
|
linux-portable:
|
2022-01-06 00:09:24 +01:00
|
|
|
name: Linux (${{ matrix.platform }}, ${{ matrix.distro }}, portable)
|
2019-10-28 20:53:45 +01:00
|
|
|
runs-on: ubuntu-latest
|
2021-04-15 12:00:59 +02:00
|
|
|
needs: check-code-formatting
|
2022-03-09 21:19:40 +01:00
|
|
|
container: ${{ matrix.image }}
|
2021-04-15 12:43:39 +02:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
include:
|
|
|
|
- platform: x86_64
|
2022-01-06 00:09:24 +01:00
|
|
|
distro: bionic
|
2022-01-07 23:04:52 +01:00
|
|
|
image: openrct2/openrct2-build:4-bionic
|
2022-05-19 20:43:28 +02:00
|
|
|
build_flags: -DCMAKE_POSITION_INDEPENDENT_CODE=on -DCMAKE_CXX_FLAGS="-g -gz" -DWITH_TESTS=off -DDISABLE_FLAC=ON -DDISABLE_VORBIS=ON
|
2022-01-06 00:09:24 +01:00
|
|
|
- platform: x86_64
|
|
|
|
distro: focal
|
2022-04-01 07:42:50 +02:00
|
|
|
image: openrct2/openrct2-build:8-focal
|
|
|
|
build_flags: -DCMAKE_POSITION_INDEPENDENT_CODE=on -DCMAKE_CXX_FLAGS="-g -gz"
|
|
|
|
- platform: x86_64
|
|
|
|
distro: jammy
|
|
|
|
image: openrct2/openrct2-build:8-jammy
|
2022-01-06 00:09:24 +01:00
|
|
|
build_flags: -DCMAKE_POSITION_INDEPENDENT_CODE=on -DCMAKE_CXX_FLAGS="-g -gz"
|
|
|
|
- platform: x86_64
|
|
|
|
distro: bullseye
|
2022-04-01 07:42:50 +02:00
|
|
|
image: openrct2/openrct2-build:8-bullseye
|
2022-01-06 00:09:24 +01:00
|
|
|
build_flags: -DCMAKE_POSITION_INDEPENDENT_CODE=on -DCMAKE_CXX_FLAGS="-g -gz"
|
2021-04-15 12:43:39 +02:00
|
|
|
- platform: i686
|
2022-05-22 23:42:17 +02:00
|
|
|
distro: focal
|
|
|
|
image: openrct2/openrct2-build:8-focal32
|
2022-05-09 23:25:30 +02:00
|
|
|
build_flags: -DFORCE32=ON -DENABLE_SCRIPTING=OFF -DCMAKE_CXX_FLAGS="-m32 -g -gz" -DWITH_TESTS=off
|
2020-01-24 12:46:12 +01:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-02-09 12:58:23 +01:00
|
|
|
- name: ccache
|
|
|
|
uses: hendrikmuhs/ccache-action@v1
|
2021-02-09 20:25:41 +01:00
|
|
|
with:
|
2022-01-06 13:20:11 +01:00
|
|
|
key: linux-${{ matrix.platform }}-${{ matrix.distro }}
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Get pre-reqs
|
|
|
|
run: . scripts/setenv && get-discord-rpc
|
2022-04-01 11:02:48 +02:00
|
|
|
- name: Install GCC problem matcher
|
|
|
|
uses: ammaraskar/gcc-problem-matcher@master
|
2019-10-28 20:53:45 +01:00
|
|
|
- name: Build OpenRCT2
|
2021-04-15 12:43:39 +02:00
|
|
|
run: . scripts/setenv -q && build -DWITH_TESTS=on -DCMAKE_BUILD_TYPE=Release -DBUILD_SHARED_LIBS=ON -DPORTABLE=ON ${{ matrix.build_flags }}
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Build artifacts
|
2022-01-06 00:09:24 +01:00
|
|
|
run: . scripts/setenv -q && build-portable artifacts/OpenRCT2-${{ runner.os }}-${{ matrix.distro }}-${{ matrix.platform }}.tar.gz bin/install/usr
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Upload artifacts (CI)
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/upload-artifact@v3
|
2020-01-24 12:46:12 +01:00
|
|
|
with:
|
2022-01-06 00:09:24 +01:00
|
|
|
name: OpenRCT2-${{ runner.os }}-${{ matrix.distro }}-${{ matrix.platform }}
|
2020-01-24 12:46:12 +01:00
|
|
|
path: artifacts
|
2021-04-15 11:46:59 +02:00
|
|
|
if-no-files-found: error
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Run Tests
|
|
|
|
run: . scripts/setenv -q && run-tests
|
|
|
|
- name: Upload artifacts (openrct2.org)
|
2019-10-28 20:53:45 +01:00
|
|
|
run: |
|
2022-05-22 23:39:52 +02:00
|
|
|
# Build identification code: https://github.com/Limetric/OpenRCT2.org/blob/e5b738f3dadcc5a3b78e8dfd434756ff31eaa1d3/src/misc/releaseAsset.js#L94-L116
|
2020-01-24 12:46:12 +01:00
|
|
|
. scripts/setenv -q
|
|
|
|
if [[ "$OPENRCT2_PUSH" == "true" ]]; then
|
2022-03-09 21:53:23 +01:00
|
|
|
upload-build artifacts/OpenRCT2-${{ runner.os }}-${{ matrix.distro }}-${{ matrix.platform }}.tar.gz linux-${{ matrix.platform }} $OPENRCT2_VERSION $OPENRCT2_SHA1 $OPENRCT2_BRANCH
|
2020-01-24 12:46:12 +01:00
|
|
|
else
|
2022-03-09 21:53:23 +01:00
|
|
|
echo 'Not going to push build'
|
2020-01-24 12:46:12 +01:00
|
|
|
fi
|
|
|
|
linux-appimage:
|
|
|
|
name: Linux (x64, AppImage)
|
|
|
|
runs-on: ubuntu-latest
|
2021-04-15 12:00:59 +02:00
|
|
|
needs: check-code-formatting
|
2022-05-21 00:17:39 +02:00
|
|
|
container: openrct2/openrct2-build:8-focal
|
2020-01-24 12:46:12 +01:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-02-09 12:58:23 +01:00
|
|
|
- name: ccache
|
|
|
|
uses: hendrikmuhs/ccache-action@v1
|
2021-02-09 20:25:41 +01:00
|
|
|
with:
|
|
|
|
key: linux-appimage
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Get pre-reqs
|
|
|
|
run: . scripts/setenv -q && get-discord-rpc
|
|
|
|
- name: Build OpenRCT2
|
2021-02-09 13:27:09 +01:00
|
|
|
run: . scripts/setenv -q && build -DCMAKE_BUILD_TYPE=Release -DAPPIMAGE=ON -DOPENRCT2_USE_CCACHE=on
|
2019-10-28 20:53:45 +01:00
|
|
|
- name: Build AppImage
|
2020-01-24 12:46:12 +01:00
|
|
|
run: . scripts/setenv -q && build-appimage
|
|
|
|
- name: Upload artifacts (CI)
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/upload-artifact@v3
|
2019-10-28 20:53:45 +01:00
|
|
|
with:
|
|
|
|
name: OpenRCT2-AppImage
|
2020-01-24 12:46:12 +01:00
|
|
|
path: artifacts
|
2021-04-15 11:46:59 +02:00
|
|
|
if-no-files-found: error
|
2020-01-27 15:50:39 +01:00
|
|
|
linux-docker:
|
|
|
|
name: Linux (docker)
|
2021-04-15 12:00:59 +02:00
|
|
|
needs: check-code-formatting
|
2020-07-06 18:52:38 +02:00
|
|
|
if: github.repository == 'OpenRCT2/OpenRCT2'
|
2020-01-27 15:50:39 +01:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2021-04-15 11:50:22 +02:00
|
|
|
- name: Checkout image
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-04-15 11:50:22 +02:00
|
|
|
with:
|
|
|
|
repository: OpenRCT2/openrct2-docker
|
2020-01-27 15:50:39 +01:00
|
|
|
- name: Build image
|
2021-04-15 11:50:22 +02:00
|
|
|
run: docker build -t openrct2/openrct2-cli:develop develop/cli
|
2020-01-27 15:50:39 +01:00
|
|
|
- name: Push image
|
|
|
|
env:
|
|
|
|
OPENRCT2_DOCKER_USER: ${{ secrets.OPENRCT2_DOCKER_USER }}
|
|
|
|
OPENRCT2_DOCKER_PASS: ${{ secrets.OPENRCT2_DOCKER_PASS }}
|
|
|
|
run: |
|
|
|
|
OPENRCT2_BRANCH=$(echo "$GITHUB_REF" | sed 's/refs\/heads\///')
|
|
|
|
echo "Current branch is $OPENRCT2_BRANCH"
|
|
|
|
if [ "$OPENRCT2_BRANCH" = 'develop' ]; then
|
2022-03-09 21:53:23 +01:00
|
|
|
docker login -u "$OPENRCT2_DOCKER_USER" -p "$OPENRCT2_DOCKER_PASS"
|
|
|
|
docker push openrct2/openrct2-cli:develop
|
2020-01-27 15:50:39 +01:00
|
|
|
else
|
2022-03-09 21:53:23 +01:00
|
|
|
echo 'Image not pushed'
|
2020-01-27 15:50:39 +01:00
|
|
|
fi
|
2020-01-24 12:46:12 +01:00
|
|
|
linux-clang:
|
2022-05-15 18:16:36 +02:00
|
|
|
name: Linux (Debug, [http, network, flac, vorbis OpenGL] disabled) using clang
|
2020-01-24 12:46:12 +01:00
|
|
|
runs-on: ubuntu-latest
|
2021-04-15 12:00:59 +02:00
|
|
|
needs: check-code-formatting
|
2022-05-21 00:17:39 +02:00
|
|
|
container: openrct2/openrct2-build:8-jammy
|
2020-01-24 12:46:12 +01:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-02-09 12:58:23 +01:00
|
|
|
- name: ccache
|
|
|
|
uses: hendrikmuhs/ccache-action@v1
|
2021-02-09 20:25:41 +01:00
|
|
|
with:
|
|
|
|
key: linux-clang
|
2022-04-01 11:02:48 +02:00
|
|
|
- name: Install GCC problem matcher
|
|
|
|
uses: ammaraskar/gcc-problem-matcher@master
|
2020-01-24 12:46:12 +01:00
|
|
|
- name: Build OpenRCT2
|
2022-05-15 18:16:36 +02:00
|
|
|
run: . scripts/setenv && build -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_BUILD_TYPE=Debug -DDISABLE_NETWORK=ON -DDISABLE_HTTP=ON -DDISABLE_FLAC=ON -DDISABLE_VORBIS=ON -DDISABLE_OPENGL=ON
|
2020-01-31 09:02:11 +01:00
|
|
|
android:
|
|
|
|
name: Android
|
|
|
|
runs-on: ubuntu-latest
|
2021-04-15 12:00:59 +02:00
|
|
|
needs: check-code-formatting
|
2022-05-21 00:17:39 +02:00
|
|
|
container: openrct2/openrct2-build:8-android
|
2020-01-31 09:02:11 +01:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/checkout@v3
|
2021-02-09 13:27:09 +01:00
|
|
|
- name: ccache
|
|
|
|
uses: hendrikmuhs/ccache-action@v1
|
2021-02-09 20:25:41 +01:00
|
|
|
with:
|
|
|
|
key: android
|
2022-04-01 11:02:48 +02:00
|
|
|
- name: Install GCC problem matcher
|
|
|
|
uses: ammaraskar/gcc-problem-matcher@master
|
2020-01-31 09:02:11 +01:00
|
|
|
- name: Build OpenRCT2
|
2020-02-01 16:41:24 +01:00
|
|
|
run: |
|
|
|
|
. scripts/setenv
|
|
|
|
pushd src/openrct2-android
|
2021-12-18 23:38:15 +01:00
|
|
|
./gradlew app:assembleRelease
|
2020-02-01 16:41:24 +01:00
|
|
|
popd
|
|
|
|
mkdir -p artifacts
|
2021-12-18 00:03:38 +01:00
|
|
|
mv src/openrct2-android/app/build/outputs/apk/release/app-release.apk artifacts/openrct2-arm.apk
|
2020-01-31 09:02:11 +01:00
|
|
|
- name: Upload artifacts (CI)
|
2022-03-09 21:15:18 +01:00
|
|
|
uses: actions/upload-artifact@v3
|
2020-01-31 09:02:11 +01:00
|
|
|
with:
|
2021-04-15 11:46:59 +02:00
|
|
|
name: OpenRCT2-Android
|
2020-02-01 16:41:24 +01:00
|
|
|
path: artifacts
|
2021-04-15 11:46:59 +02:00
|
|
|
if-no-files-found: error
|
2020-02-01 17:47:49 +01:00
|
|
|
- name: Upload artifacts (openrct2.org)
|
|
|
|
run: |
|
|
|
|
. scripts/setenv -q
|
|
|
|
if [[ "$OPENRCT2_PUSH" == "true" ]]; then
|
2022-03-09 21:53:23 +01:00
|
|
|
upload-build artifacts/openrct2-arm.apk android-arm $OPENRCT2_VERSION $OPENRCT2_SHA1 $OPENRCT2_BRANCH
|
2020-02-01 17:47:49 +01:00
|
|
|
else
|
2022-03-09 21:53:23 +01:00
|
|
|
echo 'Not going to push build'
|
2020-02-01 17:47:49 +01:00
|
|
|
fi
|