-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
20b12c9
commit f5be06e
Showing
4 changed files
with
86 additions
and
6 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
name: compile | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
ubuntu_build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install dependencies(Ubuntu) | ||
run: | | ||
sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu `lsb_release -sc` main universe restricted multiverse" -y | ||
sudo apt-get install libsdl2-dev -y | ||
sudo apt-get install gcc cmake -y | ||
- name: Build & Install(Ubuntu) | ||
run: | | ||
sudo mkdir cmake-build-release | ||
cd cmake-build-release | ||
sudo cmake -DCMAKE_BUILD_TYPE=Release .. | ||
sudo cmake --install . | ||
- name: Build all examples(Ubuntu) | ||
run: | | ||
cd cmake-build-release | ||
sudo cmake -DCMAKE_BUILD_TYPE=Release .. | ||
sudo cmake --build . | ||
windows_build: | ||
runs-on: windows-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install dependencies(Windows) | ||
shell: powershell | ||
run: | | ||
vcpkg install sdl2:x64-windows | ||
vcpkg integrate install | ||
- name: Build & Install(Windows) | ||
shell: powershell | ||
run: | | ||
mkdir cmake-build-release | ||
cd cmake-build-release | ||
cmake -DCMAKE_BUILD_TYPE=Release .. -DCMAKE_TOOLCHAIN_FILE=C:\vcpkg\scripts\buildsystems\vcpkg.cmake | ||
cmake --install . | ||
- name: Build all examples(Windows) | ||
shell: powershell | ||
run: | | ||
cd cmake-build-release | ||
cmake -DCMAKE_BUILD_TYPE=Release .. -DCMAKE_TOOLCHAIN_FILE=C:\vcpkg\scripts\buildsystems\vcpkg.cmake | ||
cmake --build . | ||
macos_build: | ||
runs-on: macos-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Install dependencies(MacOS) | ||
run: | | ||
brew install cmake sdl2 | ||
- name: Build & Install(MacOS) | ||
run: | | ||
sudo mkdir cmake-build-release | ||
cd cmake-build-release | ||
sudo cmake -DCMAKE_BUILD_TYPE=Release .. | ||
sudo cmake --install . | ||
- name: Build all examples(MacOS) | ||
run: | | ||
cd cmake-build-release | ||
sudo cmake -DCMAKE_BUILD_TYPE=Release .. | ||
sudo cmake --build . |
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
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
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