CHG gradle version #716
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Nightly build Linux x64 | |
on: | |
push: | |
tags: | |
- 'Nightly' | |
jobs: | |
set-revision: | |
name: set revision | |
runs-on: ubuntu-20.04 | |
outputs: | |
output1: ${{ steps.out1.outputs.revision }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: detect revision | |
run: | | |
read text < ./src/simutrans/revision.h | |
revision=${text:17:5} | |
echo "revision=$revision" >> $GITHUB_ENV | |
- id: out1 | |
run: echo "revision=$revision" >> $GITHUB_OUTPUT | |
makeobj_linux-x64-nightly: | |
name: makeobj | |
runs-on: ubuntu-20.04 | |
needs: [set-revision] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: install_dependencies | |
run: | | |
sudo apt-get -y update | |
sudo apt-get -ym install autoconf | |
sudo apt-get -ym install libpng-dev | |
sudo apt-get -ym install libbz2-dev | |
- name: setup | |
run: | | |
autoconf | |
./configure | |
echo "STATIC = 1" >>config.default | |
cat config.default >>/dev/stderr | |
- name: make makeobj | |
run: | | |
cd src/makeobj | |
make | |
- name: zip result | |
run: | | |
cd src/makeobj | |
zip -r -9 makeobj_linux-x64-nightly.zip makeobj | |
- name: Update binaries of Nightly Release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: src/makeobj/makeobj_linux-x64-nightly.zip | |
asset_name: makeobj_linux-x64-nightly_r${{ needs.set-revision.outputs.output1 }}.zip | |
tag: Nightly | |
overwrite: true | |
simulinux-x64-nightly: | |
name: simutrans SDL2 | |
runs-on: ubuntu-20.04 | |
needs: [set-revision] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: install_dependencies | |
run: | | |
sudo apt-get -y update | |
sudo apt-get -ym install libsdl2-dev | |
sudo apt-get -ym install libfreetype6-dev | |
sudo apt-get -ym install libfontconfig-dev | |
sudo apt-get -ym install libbz2-dev | |
sudo apt-get -ym install libminiupnpc-dev | |
sudo apt-get -ym install libzstd-dev | |
# We build fluidsynth with the minimum set of options we need to keep dependencies low | |
sudo apt-get -ym install libsndfile1-dev | |
wget https://github.com/FluidSynth/fluidsynth/archive/refs/tags/v2.3.0.tar.gz | |
tar xf v*.tar.gz | |
cd fluidsynth* | |
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_LIBDIR=lib -Denable-aufile=0 -Denable-dbus=0 -Denable-ipv6=0 -Denable-jack=0 -Denable-ladspa=0 -Denable-midishare=0 -Denable-opensles=0 -Denable-oboe=0 -Denable-oss=0 -Denable-readline=0 -Denable-winmidi=0 -Denable-waveout=0 -Denable-network=0 -Denable-pulseaudio=0 -Denable-dsound=0 -Denable-alsa=0 -Denable-libinstpatch=0 -Denable-portaudio=0 -Denable-wasapi=0 -Denable-openmp=1 -Denable-libsndfile=1 -Denable-sdl2=1 | |
cmake --build build -j $(nproc) | |
sudo cmake --install build | |
- name: setup | |
run: | | |
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DOPTION_BUNDLE_LIBRARIES=ON | |
cp ./revision.h ./build/revision.h | |
cmake --build build -j$(nproc) --target install | |
- name: distribute | |
run: | | |
chmod -v 755 ./tools/lang_files_standard.sh | |
./tools/lang_files_standard.sh | |
cp simutrans/text/* build/simutrans/text | |
cd build | |
zip -r simulinux-x64-nightly.zip simutrans | |
- name: Update binaries of Nightly Release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: build/simulinux-x64-nightly.zip | |
asset_name: simulinux-x64-nightly_r${{ needs.set-revision.outputs.output1 }}.zip | |
tag: Nightly | |
overwrite: true | |
simulinux-posix-x64_nightly: | |
name: simutrans posix | |
runs-on: ubuntu-20.04 | |
needs: [set-revision] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: install_dependencies | |
run: | | |
sudo apt-get -y update | |
sudo apt-get -ym install autoconf | |
sudo apt-get -ym install libbz2-dev | |
- name: setup | |
run: | | |
cd libs/zstd-1.5.2/lib | |
make | |
cd ../../../ | |
autoconf | |
./configure | |
echo "CFLAGS += -std=c++2a " >>config.default | |
echo "STATIC := 1" >>config.default | |
echo "BACKEND = posix" >>config.default | |
cat config.default >>/dev/stderr | |
- name: make | |
run: | | |
make | |
- name: distribute | |
run: | | |
chmod -v 755 ./tools/lang_files_standard.sh | |
./tools/lang_files_standard.sh | |
zip -r simulinux_posix-x64-nightly.zip simutrans | |
- name: Update binaries of Nightly Release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: simulinux_posix-x64-nightly.zip | |
asset_name: simulinux_posix-x64-nightly_r${{ needs.set-revision.outputs.output1 }}.zip | |
tag: Nightly | |
overwrite: true | |
nettool-linux: | |
name: Nettool | |
runs-on: ubuntu-20.04 | |
needs: [set-revision] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: install_dependencies | |
run: | | |
sudo apt-get -y update | |
sudo apt-get -ym install autoconf | |
- name: setup | |
run: | | |
autoconf | |
./configure | |
echo "CFLAGS += -std=c++2a " >>config.default | |
echo "STATIC = 1" >>config.default | |
cat config.default >>/dev/stderr | |
- name: make | |
run: | | |
cd src/nettool | |
make | |
- name: zip result | |
run: | | |
cd src/nettool | |
zip -r -9 nettool_linux-x64-nightly.zip nettool | |
- name: Update binaries of Nightly Release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: src/nettool/nettool_linux-x64-nightly.zip | |
asset_name: nettool_linux-x64-nightly_r${{ needs.set-revision.outputs.output1 }}.zip | |
tag: Nightly | |
overwrite: true |