mirror of
https://github.com/simple64/simple64.git
synced 2026-11-13 03:48:42 +01:00
78 lines
2.5 KiB
YAML
78 lines
2.5 KiB
YAML
name: Build project
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
|
|
jobs:
|
|
build-linux:
|
|
runs-on: ubuntu-latest
|
|
container: registry.fedoraproject.org/fedora:latest
|
|
steps:
|
|
- name: Update and install packages
|
|
run: |
|
|
dnf -y update
|
|
dnf -y install pkgconf-pkg-config which cmake make nasm qt6-qtwebsockets-devel hidapi-devel zlib-devel libpng-devel SDL2_net-devel wget zip git
|
|
- uses: actions/checkout@v3
|
|
- name: Run build script
|
|
run: |
|
|
git config --global --add safe.directory /__w/simple64/simple64
|
|
./build.sh
|
|
build-windows:
|
|
runs-on: windows-2022
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- name: Get short SHA
|
|
id: slug
|
|
run: echo "::set-output name=sha7::$(git rev-parse --short HEAD)"
|
|
- uses: msys2/setup-msys2@v2
|
|
with:
|
|
update: true
|
|
install: >-
|
|
make
|
|
mingw-w64-x86_64-cmake
|
|
mingw-w64-x86_64-gcc
|
|
mingw-w64-x86_64-hidapi
|
|
mingw-w64-x86_64-freetype
|
|
mingw-w64-x86_64-libpng
|
|
mingw-w64-x86_64-SDL2
|
|
mingw-w64-x86_64-SDL2_net
|
|
mingw-w64-x86_64-qt6
|
|
mingw-w64-x86_64-python3-pip
|
|
mingw-w64-x86_64-python3-pyopenssl
|
|
mingw-w64-x86_64-nasm
|
|
git
|
|
zip
|
|
- name: Run build script
|
|
run: msys2 -c 'export SIMPLE64_AUTOUPDATE=1; ./build.sh'
|
|
- name: Upload zip
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: simple64-win64-${{ steps.slug.outputs.sha7 }}.zip
|
|
path: simple64-*.zip
|
|
# build-mac:
|
|
# runs-on: macos-10.15
|
|
# steps:
|
|
# - uses: actions/checkout@v3
|
|
# - name: Get short SHA
|
|
# id: slug
|
|
# run: echo "::set-output name=sha7::$(git rev-parse --short HEAD)"
|
|
# - name: brew update
|
|
# run: |
|
|
# brew update
|
|
# brew install hidapi sdl2_net sdl2 qt@5
|
|
# - name: Run build script
|
|
# run: |
|
|
# export qt_version=$(ls /usr/local/Cellar/qt@5)
|
|
# sudo ln -s /usr/local/Cellar/qt@5/$qt_version/plugins /usr/local/plugins
|
|
# sudo ln -s /usr/local/Cellar/qt@5/$qt_version/mkspecs /usr/local/mkspecs
|
|
# sudo ln -s /usr/local/Cellar/qt@5/$qt_version/bin/qmake /usr/local/bin/qmake
|
|
# export PATH=$PATH:/usr/local/Cellar/qt@5/$qt_version/bin
|
|
# sudo sh ./build.sh
|
|
# - name: Upload dmg
|
|
# uses: actions/upload-artifact@v3
|
|
# with:
|
|
# name: simple64-osx-${{ steps.slug.outputs.sha7 }}.dmg
|
|
# path: simple64/simple64-*.dmg
|