This repository has been archived by the owner on Aug 3, 2024. It is now read-only.
Add MIT license back #126
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: CMake | |
on: | |
push: | |
branches: [ "main" ] | |
env: | |
VITASDK: /usr/local/vitasdk | |
jobs: | |
build-windows: | |
name: Windows | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: suisei-cn/[email protected] | |
name: Download packages | |
with: | |
url: "https://github.com/Hammerill/Sand-Box2D/releases/download/v1.0.0/win64-packages.zip" | |
target: pkgs/ | |
- name: Build project | |
run: | | |
7z x pkgs/win64-packages.zip -opkgs | |
git clone https://github.com/Hammerill/Sand-Box2D && cd Sand-Box2D | |
mkdir build | |
cd build | |
cmake .. -G "MinGW Makefiles" | |
cmake .. -DBUILD_WINDOWS_PKGS=D:/a/Sand-Box2D/Sand-Box2D/pkgs | |
make | |
- name: Output build | |
uses: actions/upload-artifact@v3 | |
with: | |
name: Windows EXE | |
path: | | |
Sand-Box2D/build/assets | |
Sand-Box2D/build/*.exe | |
build-linux: | |
name: Linux | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update -y | |
sudo apt-get install libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev libsdl2-ttf-dev libsdl2-gfx-dev libbox2d-dev libjsoncpp-dev libcurl4-openssl-dev | |
- name: Build project | |
run: | | |
git clone https://github.com/Hammerill/Sand-Box2D && cd Sand-Box2D | |
mkdir build | |
cd build | |
cmake .. -DBUILD_WINDOWS=OFF -DBUILD_LINUX=ON -DLEGACY_INTERSECT=ON | |
make -j4 | |
- name: Output build | |
uses: actions/upload-artifact@v3 | |
with: | |
name: Linux executable | |
path: | | |
Sand-Box2D/build/assets | |
Sand-Box2D/build/Sand-Box2D | |
build-vita: | |
name: Vita | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install VitaSDK | |
continue-on-error: true | |
run: | | |
git clone https://github.com/vitasdk/vdpm | |
cd vdpm | |
./bootstrap-vitasdk.sh | |
./install-all.sh | |
- name: Build project | |
run: | | |
git clone https://github.com/Hammerill/Sand-Box2D && cd Sand-Box2D | |
mkdir build | |
cd build | |
cmake .. -DBUILD_WINDOWS=OFF -DBUILD_VITA=ON | |
make -j4 | |
- name: Output build | |
uses: actions/upload-artifact@v3 | |
with: | |
name: Vita VPK | |
path: | | |
Sand-Box2D/build/*.vpk |