mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-09-01 11:39:18 +02:00
97 lines
2.7 KiB
YAML
97 lines
2.7 KiB
YAML
version: '{build}'
|
|
|
|
# Build on both Windows and Linux
|
|
image:
|
|
- Visual Studio 2022
|
|
- Ubuntu2404
|
|
|
|
# Używamy własnych kroków build
|
|
build: off
|
|
|
|
# Zmienna z konfiguracją (Windows)
|
|
environment:
|
|
CONFIG: RelWithDebInfo
|
|
|
|
# Per-image build steps: Windows uses cmd:, Linux uses sh:
|
|
for:
|
|
|
|
# ------------------------------------------------------------------ Windows
|
|
- matrix:
|
|
only:
|
|
- image: Visual Studio 2022
|
|
|
|
init:
|
|
- cmd: |
|
|
echo Build worker: %APPVEYOR_BUILD_WORKER_IMAGE%
|
|
ver
|
|
|
|
install:
|
|
- cmd: |
|
|
git submodule update --init --recursive
|
|
call setup-ci.bat
|
|
|
|
before_build:
|
|
- cmd: |
|
|
if not exist build mkdir build
|
|
cd build
|
|
cmake .. -G "Visual Studio 17 2022" -A x64 -DCMAKE_BUILD_TYPE=%CONFIG% -DPython3_ROOT_DIR=C:/Python314-x64
|
|
|
|
build_script:
|
|
- cmd: |
|
|
cmake --build . --config %CONFIG% --parallel
|
|
cd ..
|
|
|
|
after_build:
|
|
- cmd: |
|
|
echo Copying shaders...
|
|
if not exist build\bin\%CONFIG%\shaders mkdir build\bin\%CONFIG%\shaders
|
|
xcopy /E /Y shaders build\bin\%CONFIG%\shaders\
|
|
|
|
artifacts:
|
|
- path: build\bin\%CONFIG%\*.exe
|
|
name: binaries
|
|
- path: build\pdb\%CONFIG%\*.pdb
|
|
name: symbols
|
|
- path: build\bin\%CONFIG%\shaders
|
|
name: shaders
|
|
|
|
# ------------------------------------------------------------------ Linux
|
|
- matrix:
|
|
only:
|
|
- image: Ubuntu2404
|
|
|
|
init:
|
|
- sh: |
|
|
echo "Build worker: $APPVEYOR_BUILD_WORKER_IMAGE"
|
|
uname -a
|
|
|
|
install:
|
|
- sh: |
|
|
git submodule update --init --recursive
|
|
# Python 3.14 (dev headers + libpython) isn't in noble - deadsnakes has it.
|
|
sudo add-apt-repository -y ppa:deadsnakes/ppa
|
|
sudo apt-get update -y
|
|
sudo apt-get install -y python3.14-dev libglfw3-dev libpng-dev libopenal-dev libluajit-5.1-dev libserialport-dev libsndfile1-dev
|
|
# The image's CMake is 3.29.7, too old to find Python 3.14. Drop in the
|
|
# last 3.x release (3.31.12, the only 3.x line that knows 3.14) as a plain
|
|
# tarball into /usr/local, which shadows the image's /usr/bin/cmake.
|
|
wget -qO- https://cmake.org/files/v3.31/cmake-3.31.12-linux-x86_64.tar.gz | sudo tar xz --strip-components=1 -C /usr/local
|
|
cmake --version
|
|
|
|
build_script:
|
|
- sh: |
|
|
mkdir -p build
|
|
cd build
|
|
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_ZMQ=OFF -DWITH_OPENVR=OFF -DWITH_BETTER_RENDERER=OFF -DUSE_LTO=ON -DPython3_EXECUTABLE=/usr/bin/python3.14
|
|
cmake --build . --parallel
|
|
cd ..
|
|
|
|
after_build:
|
|
- sh: |
|
|
mkdir -p build/bin/shaders
|
|
cp -r shaders/. build/bin/shaders/ || true
|
|
|
|
artifacts:
|
|
- path: build/bin
|
|
name: binaries_linux
|