mirror of
https://github.com/MatsuriDayo/nekoray.git
synced 2025-12-18 04:54:38 +03:00
use Qt5.15 for win7
This commit is contained in:
50
.github/workflows/build-qv2ray-cmake.yml
vendored
50
.github/workflows/build-qv2ray-cmake.yml
vendored
@@ -58,8 +58,16 @@ jobs:
|
||||
build-cpp:
|
||||
strategy:
|
||||
matrix:
|
||||
platform: [ windows-2022, ubuntu-20.04 ]
|
||||
arch: [ x64 ]
|
||||
include:
|
||||
- platform: windows-2022
|
||||
arch: x64
|
||||
qt_version: "5.15"
|
||||
- platform: windows-2022
|
||||
arch: x64
|
||||
qt_version: "6.5"
|
||||
- platform: ubuntu-20.04
|
||||
arch: x64
|
||||
qt_version: "5.12"
|
||||
fail-fast: false
|
||||
|
||||
runs-on: ${{ matrix.platform }}
|
||||
@@ -78,15 +86,12 @@ jobs:
|
||||
toolset: 14.2
|
||||
arch: ${{ matrix.arch }}
|
||||
# ========================================================================================================= Qt Install
|
||||
- name: Windows - Download Custom Qt 5.15 SDK
|
||||
- name: Windows - Download Custom Qt ${{ matrix.qt_version }} SDK
|
||||
shell: bash
|
||||
if: matrix.platform == 'windows-2022'
|
||||
run: |
|
||||
mkdir qtsdk ; cd qtsdk
|
||||
curl -LSO https://github.com/MatsuriDayo/nekoray_qt_runtime/releases/download/20220503/Qt6.5.0-Windows-x86_64-VS2022-17.5.5-20230507.7z
|
||||
7z x *.7z
|
||||
rm *.7z
|
||||
mv Qt* Qt
|
||||
env:
|
||||
DL_QT_VER: ${{ matrix.qt_version }}
|
||||
run: bash ./libs/download_qtsdk_win.sh
|
||||
# ========================================================================================================= 编译与 Qt 无关的依赖
|
||||
- name: Install ninja-build tool
|
||||
uses: seanmiddleditch/gha-setup-ninja@v3
|
||||
@@ -95,12 +100,11 @@ jobs:
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: libs/deps
|
||||
key: DepsCache-${{ matrix.platform }}-${{ matrix.arch }}-${{ hashFiles('libs/build_deps_*.sh') }}
|
||||
key: DepsCache-${{ matrix.platform }}-${{ matrix.arch }}-${{ hashFiles('libs/build_deps_*.sh') }}-Qt${{ matrix.qt_version }}
|
||||
- name: Build Dependencies
|
||||
shell: bash
|
||||
if: steps.cache-deps.outputs.cache-hit != 'true' && matrix.platform != 'ubuntu-20.04'
|
||||
run: |
|
||||
./libs/build_deps_all.sh
|
||||
run: ./libs/build_deps_all.sh
|
||||
- name: Build Dependencies (Docker)
|
||||
shell: bash
|
||||
if: steps.cache-deps.outputs.cache-hit != 'true' && matrix.platform == 'ubuntu-20.04'
|
||||
@@ -115,13 +119,18 @@ jobs:
|
||||
shell: bash
|
||||
if: matrix.platform == 'windows-2022'
|
||||
env:
|
||||
DL_QT_VER: ${{ matrix.qt_version }}
|
||||
CC: cl.exe
|
||||
CXX: cl.exe
|
||||
run: |
|
||||
source libs/env_qtsdk.sh $PWD/qtsdk/Qt
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -GNinja -DQT_VERSION_MAJOR=6 -DCMAKE_BUILD_TYPE=Release ..
|
||||
if [ "$DL_QT_VER" == "5.15" ]; then
|
||||
cmake -GNinja -DCMAKE_BUILD_TYPE=Release ..
|
||||
else
|
||||
cmake -GNinja -DQT_VERSION_MAJOR=6 -DCMAKE_BUILD_TYPE=Release ..
|
||||
fi
|
||||
ninja
|
||||
cd ..
|
||||
./libs/deploy_windows64.sh
|
||||
@@ -141,7 +150,7 @@ jobs:
|
||||
- name: Uploading Artifact
|
||||
uses: actions/upload-artifact@master
|
||||
with:
|
||||
name: NekoRay-${{ github.sha }}-${{ matrix.platform }}-${{ matrix.arch }}
|
||||
name: NekoRay-${{ github.sha }}-${{ matrix.platform }}-${{ matrix.arch }}-Qt${{ matrix.qt_version }}
|
||||
path: artifacts.tgz
|
||||
publish:
|
||||
name: Pack & Publish Release
|
||||
@@ -167,6 +176,9 @@ jobs:
|
||||
cd deployment
|
||||
cp -r public_res/* linux64
|
||||
cp -r public_res/* windows64
|
||||
cp -r public_res/* windows7-x64
|
||||
cp windows64/neko*core.exe windows7-x64
|
||||
cp windows64/updater.exe windows7-x64
|
||||
rm -rf public_res *.pdb
|
||||
####
|
||||
mv linux64 nekoray
|
||||
@@ -176,6 +188,10 @@ jobs:
|
||||
mv windows64 nekoray
|
||||
zip -r $version_standalone-windows64.zip nekoray
|
||||
rm -rf nekoray
|
||||
####
|
||||
mv windows7-x64 nekoray
|
||||
zip -r $version_standalone-windows7-x64.zip nekoray
|
||||
rm -rf nekoray
|
||||
- name: Pack Debian
|
||||
if: github.event.inputs.publish != 'y'
|
||||
run: |
|
||||
@@ -183,8 +199,6 @@ jobs:
|
||||
find . -name artifacts.tgz | xargs -n1 tar xvzf
|
||||
cd deployment
|
||||
cp -r public_res/* linux64
|
||||
cp -r public_res/* windows64
|
||||
rm -rf public_res *.pdb
|
||||
####
|
||||
bash ../libs/package_debian.sh ${{ github.event.inputs.tag }}
|
||||
mv nekoray.deb $version_standalone-debian-x64.deb
|
||||
@@ -195,7 +209,6 @@ jobs:
|
||||
find . -name artifacts.tgz | xargs -n1 tar xvzf
|
||||
cd deployment
|
||||
cp -r public_res/* linux64
|
||||
rm -rf public_res *.pdb
|
||||
####
|
||||
bash ../libs/package_appimage.sh
|
||||
mv nekoray-x86_64.AppImage $version_standalone-linux-x64.AppImage
|
||||
@@ -204,6 +217,9 @@ jobs:
|
||||
cd deployment
|
||||
rm -rf linux64
|
||||
rm -rf windows64
|
||||
rm -rf windows7-x64
|
||||
rm -rf public_res
|
||||
rm -rf *.pdb
|
||||
- name: Uploading Artifact
|
||||
uses: actions/upload-artifact@master
|
||||
with:
|
||||
|
||||
@@ -53,6 +53,10 @@ func (s *BaseServer) Update(ctx context.Context, in *gen.UpdateReq) (*gen.Update
|
||||
var search string
|
||||
if runtime.GOOS == "windows" && runtime.GOARCH == "amd64" {
|
||||
search = "windows64"
|
||||
// check Qt5 update after nekoray v3.3
|
||||
if _, err := os.Stat("../Qt5Core.dll"); err == nil {
|
||||
search = "windows7-x64"
|
||||
}
|
||||
} else if runtime.GOOS == "linux" && runtime.GOARCH == "amd64" {
|
||||
search = "linux64"
|
||||
} else if runtime.GOOS == "darwin" {
|
||||
|
||||
@@ -2,7 +2,11 @@
|
||||
set -e
|
||||
|
||||
source libs/deploy_common.sh
|
||||
DEST=$DEPLOYMENT/windows64
|
||||
if [ "$DL_QT_VER" == "5.15" ]; then
|
||||
DEST=$DEPLOYMENT/windows7-x64
|
||||
else
|
||||
DEST=$DEPLOYMENT/windows64
|
||||
fi
|
||||
rm -rf $DEST
|
||||
mkdir -p $DEST
|
||||
|
||||
@@ -14,8 +18,12 @@ pushd $DEST
|
||||
windeployqt nekoray.exe --no-compiler-runtime --no-system-d3d-compiler --no-opengl-sw --verbose 2
|
||||
rm -rf translations
|
||||
rm -rf libEGL.dll libGLESv2.dll Qt6Pdf.dll
|
||||
curl -fLSO https://github.com/MatsuriDayo/nekoray_qt_runtime/releases/download/20220503/libcrypto-3-x64.dll
|
||||
curl -fLSO https://github.com/MatsuriDayo/nekoray_qt_runtime/releases/download/20220503/libssl-3-x64.dll
|
||||
|
||||
if [ "$DL_QT_VER" != "5.15" ]; then
|
||||
curl -fLSO https://github.com/MatsuriDayo/nekoray_qt_runtime/releases/download/20220503/libcrypto-3-x64.dll
|
||||
curl -fLSO https://github.com/MatsuriDayo/nekoray_qt_runtime/releases/download/20220503/libssl-3-x64.dll
|
||||
fi
|
||||
|
||||
popd
|
||||
|
||||
#### prepare deployment ####
|
||||
|
||||
10
libs/download_qtsdk_win.sh
Normal file
10
libs/download_qtsdk_win.sh
Normal file
@@ -0,0 +1,10 @@
|
||||
mkdir qtsdk
|
||||
cd qtsdk
|
||||
if [ "$DL_QT_VER" == "5.15" ]; then
|
||||
curl -LSO https://github.com/MatsuriDayo/nekoray_qt_runtime/releases/download/20220503/Qt5.15.7-Windows-x86_64-VS2019-16.11.20-20221103.7z
|
||||
else
|
||||
curl -LSO https://github.com/MatsuriDayo/nekoray_qt_runtime/releases/download/20220503/Qt6.5.0-Windows-x86_64-VS2022-17.5.5-20230507.7z
|
||||
fi
|
||||
7z x *.7z
|
||||
rm *.7z
|
||||
mv Qt* Qt
|
||||
Reference in New Issue
Block a user