mirror of
https://github.com/BeamMP/BeamMP-Server.git
synced 2026-04-03 06:16:04 +00:00
add windows build step
This commit is contained in:
31
.github/workflows/build-windows.yml
vendored
Normal file
31
.github/workflows/build-windows.yml
vendored
Normal file
@@ -0,0 +1,31 @@
|
||||
name: Windows
|
||||
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
windows-build:
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
submodules: 'recursive'
|
||||
|
||||
- name: Setup vcpkg
|
||||
uses: lukka/run-vcpkg@v11
|
||||
with:
|
||||
runVcpkgInstall: true
|
||||
|
||||
- name: Create Build Environment
|
||||
shell: bash
|
||||
run: ./scripts/windows/1-configure.sh '-DCMAKE_TOOLCHAIN_FILE=./vcpkg/scripts/buildsystems/vcpkg.cmake'
|
||||
|
||||
- name: Build Server
|
||||
shell: bash
|
||||
run: bash ./scripts/windows/2-build.sh
|
||||
|
||||
- name: Archive server artifact
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: BeamMP-Server-windows
|
||||
path: ./bin/BeamMP-Server.exe
|
||||
|
||||
5
scripts/windows/1-configure.sh
Normal file
5
scripts/windows/1-configure.sh
Normal file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -ex
|
||||
|
||||
cmake . -B bin $1 -DCMAKE_BUILD_TYPE=Release -DBeamMP-Server_ENABLE_LTO=ON
|
||||
5
scripts/windows/2-build-tests.sh
Executable file
5
scripts/windows/2-build-tests.sh
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -ex
|
||||
|
||||
cmake --build bin --parallel -t BeamMP-Server-tests
|
||||
5
scripts/windows/2-build.sh
Executable file
5
scripts/windows/2-build.sh
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -ex
|
||||
|
||||
cmake --build bin --parallel -t BeamMP-Server
|
||||
Reference in New Issue
Block a user