Skip to content

Commit

Permalink
chore: build action (#13)
Browse files Browse the repository at this point in the history
  • Loading branch information
amhndu authored Jan 4, 2025
1 parent a797526 commit f6801f9
Showing 1 changed file with 75 additions and 0 deletions.
75 changes: 75 additions & 0 deletions .github/workflows/compile.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
name: CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build_linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 1

- name: Install dependencies
run: |
sudo apt update
sudo apt install -y libsfml-dev
- name: Build
run: |
mkdir build/ && cd build/
cmake -DCMAKE_BUILD_TYPE=Release ..
make -j4
- uses: actions/upload-artifact@v4
with:
name: SimpleNES-linux
path: build/SimpleNES


build_macos:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 1

- name: Install dependencies
run: |
brew install sfml
- name: Build
run: |
mkdir build/ && cd build/
cmake -DCMAKE_BUILD_TYPE=Release ..
make -j4
- uses: actions/upload-artifact@v4
with:
name: SimpleNES-macos
path: build/SimpleNES

build_windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 1

- name: Install dependencies
run: |
vcpkg install sfml
- name: Build
run: |
mkdir build/ && cd build/
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake ..
cmake --build .
- uses: actions/upload-artifact@v4
with:
name: SimpleNES-win.exe
path: build/SimpleNES.exe

0 comments on commit f6801f9

Please sign in to comment.