mirror of
https://github.com/siemens-mobile-hacks/ptr89.git
synced 2026-11-25 18:27:22 +00:00
CI
This commit is contained in:
parent
7c2c0bb895
commit
4d2880e4d6
5 changed files with 70 additions and 0 deletions
34
.github/workflows/ci.yml
vendored
Normal file
34
.github/workflows/ci.yml
vendored
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
name: Build
|
||||
on:
|
||||
release:
|
||||
types: [published]
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
submodules: true
|
||||
|
||||
- name: Installing dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get -y install cmake mingw-w64 mingw-w64-tools mingw-w64-i686-dev mingw-w64-x86-64-dev mingw-w64-common fakeroot build-essential
|
||||
|
||||
- name: Building emulator
|
||||
run: |
|
||||
tools/build_deb.sh
|
||||
tools/build_win.sh
|
||||
|
||||
- uses: softprops/action-gh-release@v1
|
||||
with:
|
||||
token: "${{ secrets.GITHUB_TOKEN }}"
|
||||
prerelease: true
|
||||
files:
|
||||
- ../*.deb
|
||||
- build-win/ptr89.exe
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -1,4 +1,5 @@
|
|||
build
|
||||
build-win
|
||||
.cache
|
||||
*.vkp
|
||||
*.ini
|
||||
|
|
|
|||
13
cmake/Toolchain-x86_64-w64-mingw32.cmake
Normal file
13
cmake/Toolchain-x86_64-w64-mingw32.cmake
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
SET(CMAKE_SYSTEM_NAME Windows)
|
||||
|
||||
SET(CMAKE_C_COMPILER x86_64-w64-mingw32-gcc)
|
||||
SET(CMAKE_CXX_COMPILER x86_64-w64-mingw32-g++)
|
||||
SET(CMAKE_RC_COMPILER x86_64-w64-mingw32-windres)
|
||||
SET(CMAKE_AR x86_64-w64-mingw32-ar)
|
||||
SET(CMAKE_RANLIB x86_64-w64-mingw32-ranlib)
|
||||
|
||||
SET(CMAKE_FIND_ROOT_PATH /usr/x86_64-w64-mingw32)
|
||||
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
||||
9
tools/build_deb.sh
Executable file
9
tools/build_deb.sh
Executable file
|
|
@ -0,0 +1,9 @@
|
|||
#!/bin/bash
|
||||
set -e
|
||||
set -x
|
||||
cd $(dirname $0)/../
|
||||
|
||||
fakeroot debian/rules binary
|
||||
fakeroot debian/rules clean
|
||||
|
||||
ls -lah ../*.deb
|
||||
13
tools/build_win.sh
Executable file
13
tools/build_win.sh
Executable file
|
|
@ -0,0 +1,13 @@
|
|||
#!/bin/bash
|
||||
set -e
|
||||
set -x
|
||||
cd $(dirname $0)/../
|
||||
|
||||
[[ -d ./build-win ]] && rm -rf ./build-win
|
||||
mkdir build-win
|
||||
|
||||
cd build-win
|
||||
cmake .. -DCMAKE_TOOLCHAIN_FILE=cmake/Toolchain-x86_64-w64-mingw32.cmake
|
||||
make -j$(nproc)
|
||||
|
||||
ls -lah ptr89.exe
|
||||
Loading…
Add table
Reference in a new issue