Skip to content

Commit

Permalink
Update build.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
JustDoom authored Mar 23, 2024
1 parent aca4eb5 commit 3e14d0f
Showing 1 changed file with 35 additions and 25 deletions.
60 changes: 35 additions & 25 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: Build and Release
name: Test

on:
push:
branches:
- master
- maybe-windows!!

jobs:
build-ubuntu:
Expand All @@ -29,31 +29,41 @@ jobs:
name: ubuntu-executable
path: build/src/8ChocChip

# build-windows:
# runs-on: ubuntu-latest
# strategy:
# matrix:
# arch: [x64, x86] # Target architectures for Windows EXE

# steps:
# - uses: actions/checkout@v3
build-windows:
runs-on: windows-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Install CMake
run: choco install cmake --installargs '"ADD_CMAKE_TO_PATH=System"'

- name: Install vcpkg
run: |
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg
.\bootstrap-vcpkg.bat
working-directory: ${{ github.workspace }}

- name: Set VCPKG_ROOT environment variable
run: echo "VCPKG_ROOT=$(vcpkg integrate install)" >> $GITHUB_ENV

# - name: Install dependencies (SFML, build tools)
# run: |
# sudo apt-get update && sudo apt-get install -y \
# build-essential \
# cmake \
# gcc-multilib \
# g++-multilib \
# libtool \
# pkg-config \
# libsfml-dev \
# libudev-dev \
# libopenal-dev \
# libvorbis-dev \
# libflac-dev \
# libxrandr-dev \
# libxcursor-dev
- name: Install SFML with vcpkg
run: vcpkg install sfml

- name: Configure and build
run: |
mkdir build && cd build
cmake ..
cmake --build .
- name: Upload executable
uses: actions/upload-artifact@v2
with:
name: windows-executable
path: build/src/Debug/*.exe

# - name: Configure build environment for target architecture
# run: |
Expand Down

0 comments on commit 3e14d0f

Please sign in to comment.