mirror of
https://github.com/Mahdi-zarei/nekoray.git
synced 2025-12-28 21:31:22 +08:00
Merge pull request #787 from throneproj/woa
ci: add Windows on Arm build
This commit is contained in:
commit
4e050f6525
38
.github/workflows/build.yml
vendored
38
.github/workflows/build.yml
vendored
@ -17,25 +17,28 @@ jobs:
|
|||||||
include:
|
include:
|
||||||
- cross_os: windows
|
- cross_os: windows
|
||||||
cross_arch: amd64
|
cross_arch: amd64
|
||||||
go_version: "1.25.0"
|
go_version: "1.25.1"
|
||||||
|
- cross_os: windows
|
||||||
|
cross_arch: arm64
|
||||||
|
go_version: "1.25.1"
|
||||||
- cross_os: linux
|
- cross_os: linux
|
||||||
cross_arch: amd64
|
cross_arch: amd64
|
||||||
go_version: "1.25.0"
|
go_version: "1.25.1"
|
||||||
- cross_os: linux
|
- cross_os: linux
|
||||||
cross_arch: arm64
|
cross_arch: arm64
|
||||||
go_version: "1.25.0"
|
go_version: "1.25.1"
|
||||||
- cross_os: darwin
|
- cross_os: darwin
|
||||||
cross_arch: amd64
|
cross_arch: amd64
|
||||||
go_version: "1.24.7"
|
go_version: "1.24.7"
|
||||||
- cross_os: darwin
|
- cross_os: darwin
|
||||||
cross_arch: arm64
|
cross_arch: arm64
|
||||||
go_version: "1.25.0"
|
go_version: "1.25.1"
|
||||||
- cross_os: windowslegacy
|
- cross_os: windowslegacy
|
||||||
cross_arch: amd64
|
cross_arch: amd64
|
||||||
go_version: "1.25.0"
|
go_version: "1.25.1"
|
||||||
- cross_os: windowslegacy
|
- cross_os: windowslegacy
|
||||||
cross_arch: 386
|
cross_arch: 386
|
||||||
go_version: "1.25.0"
|
go_version: "1.25.1"
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
@ -94,6 +97,9 @@ jobs:
|
|||||||
- platform: windows-latest
|
- platform: windows-latest
|
||||||
qt_version: "6.9.0"
|
qt_version: "6.9.0"
|
||||||
target: x86_64
|
target: x86_64
|
||||||
|
- platform: windows-11-arm
|
||||||
|
qt_version: "6.9.0"
|
||||||
|
target: arm64
|
||||||
- platform: ubuntu-22.04
|
- platform: ubuntu-22.04
|
||||||
qt_version: "6.9.0"
|
qt_version: "6.9.0"
|
||||||
target: amd64
|
target: amd64
|
||||||
@ -130,6 +136,11 @@ jobs:
|
|||||||
uses: bwoodsend/setup-winlibs-action@v1.15
|
uses: bwoodsend/setup-winlibs-action@v1.15
|
||||||
with:
|
with:
|
||||||
architecture: ${{ matrix.target }}
|
architecture: ${{ matrix.target }}
|
||||||
|
- name: Install MSVC compiler
|
||||||
|
if: matrix.platform == 'windows-11-arm'
|
||||||
|
uses: ilammy/msvc-dev-cmd@v1
|
||||||
|
with:
|
||||||
|
arch: arm64
|
||||||
- name: Download Artifacts
|
- name: Download Artifacts
|
||||||
uses: actions/download-artifact@v4.3.0
|
uses: actions/download-artifact@v4.3.0
|
||||||
with:
|
with:
|
||||||
@ -184,6 +195,17 @@ jobs:
|
|||||||
ninja -j2
|
ninja -j2
|
||||||
cd ..
|
cd ..
|
||||||
./script/deploy_windows.sh ${{ matrix.target }}
|
./script/deploy_windows.sh ${{ matrix.target }}
|
||||||
|
- name: WOA - Generate MakeFile and Build
|
||||||
|
shell: bash
|
||||||
|
if: matrix.platform == 'windows-11-arm'
|
||||||
|
run: |
|
||||||
|
mkdir build
|
||||||
|
cd build
|
||||||
|
curl -fLso srslist.h "https://raw.githubusercontent.com/throneproj/routeprofiles/rule-set/srslist.h"
|
||||||
|
cmake -GNinja -DCMAKE_BUILD_TYPE=Release ..
|
||||||
|
ninja -j2
|
||||||
|
cd ..
|
||||||
|
./script/deploy_woa.sh
|
||||||
- name: Build Installer with NSIS
|
- name: Build Installer with NSIS
|
||||||
shell: cmd
|
shell: cmd
|
||||||
if: matrix.platform == 'windows-latest' && matrix.qt_version != '6.2.12'
|
if: matrix.platform == 'windows-latest' && matrix.qt_version != '6.2.12'
|
||||||
@ -286,6 +308,10 @@ jobs:
|
|||||||
zip -9 -r $version_standalone-windowslegacy64.zip Throne
|
zip -9 -r $version_standalone-windowslegacy64.zip Throne
|
||||||
rm -rf Throne
|
rm -rf Throne
|
||||||
####
|
####
|
||||||
|
mv windows-arm64 Throne
|
||||||
|
zip -9 -r $version_standalone-windows-arm64.zip Throne
|
||||||
|
rm -rf Throne
|
||||||
|
####
|
||||||
mkdir Throne
|
mkdir Throne
|
||||||
mv macos-arm64/Throne.app Throne/Throne.app
|
mv macos-arm64/Throne.app Throne/Throne.app
|
||||||
zip -9 --symlinks -r $version_standalone-macos-arm64.zip Throne
|
zip -9 --symlinks -r $version_standalone-macos-arm64.zip Throne
|
||||||
|
|||||||
@ -13,12 +13,7 @@ generate_product_version(
|
|||||||
)
|
)
|
||||||
add_definitions(-DUNICODE -D_UNICODE -DNOMINMAX)
|
add_definitions(-DUNICODE -D_UNICODE -DNOMINMAX)
|
||||||
set(GUI_TYPE WIN32)
|
set(GUI_TYPE WIN32)
|
||||||
if (MINGW)
|
if (MSVC)
|
||||||
if (NOT DEFINED MinGW_ROOT)
|
|
||||||
set(MinGW_ROOT "C:/msys64/mingw64")
|
|
||||||
endif ()
|
|
||||||
else ()
|
|
||||||
add_compile_options("/utf-8")
|
add_compile_options("/utf-8")
|
||||||
add_compile_options("/std:c++17")
|
|
||||||
add_definitions(-D_WIN32_WINNT=0x600 -D_SCL_SECURE_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS)
|
add_definitions(-D_WIN32_WINNT=0x600 -D_SCL_SECURE_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS)
|
||||||
endif ()
|
endif ()
|
||||||
|
|||||||
22
script/deploy_woa.sh
Executable file
22
script/deploy_woa.sh
Executable file
@ -0,0 +1,22 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
|
||||||
|
source script/env_deploy.sh
|
||||||
|
DEST=$DEPLOYMENT/windows-arm64
|
||||||
|
rm -rf $DEST
|
||||||
|
mkdir -p $DEST
|
||||||
|
|
||||||
|
#### copy exe ####
|
||||||
|
cp $BUILD/Throne.exe $DEST
|
||||||
|
|
||||||
|
cd download-artifact
|
||||||
|
cd *windows-arm64
|
||||||
|
tar xvzf artifacts.tgz -C ../../
|
||||||
|
cd ../..
|
||||||
|
|
||||||
|
#### deploy qt & DLL runtime ####
|
||||||
|
pushd $DEST
|
||||||
|
windeployqt Throne.exe --no-translations --no-system-d3d-compiler --no-opengl-sw --no-svg --verbose 2
|
||||||
|
popd
|
||||||
|
|
||||||
|
rm -rf $DEST/dxcompiler.dll $DEST/dxil.dll
|
||||||
Loading…
Reference in New Issue
Block a user