for github actions added steps to build x32/x64 windows application
This commit is contained in:
parent
eeed6c3474
commit
409386336d
1 changed files with 136 additions and 110 deletions
246
.github/workflows/deploy.yml
vendored
246
.github/workflows/deploy.yml
vendored
|
@ -2,147 +2,173 @@ name: Deploy workflow
|
|||
|
||||
# Controls when the action will run. Workflow runs when manually triggered using the UI
|
||||
# or API.
|
||||
on: [push, pull_request]
|
||||
on: [push] #, pull_request]
|
||||
|
||||
|
||||
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||
jobs:
|
||||
Build-Linux-Ubuntu:
|
||||
name: Build-Linux-Ubuntu
|
||||
runs-on: ubuntu-latest
|
||||
# Build-Linux-Ubuntu:
|
||||
# name: Build-Linux-Ubuntu
|
||||
# runs-on: ubuntu-latest
|
||||
|
||||
env:
|
||||
QT_VERSION: 5.15.2
|
||||
QIF_VERSION: 4.4
|
||||
# env:
|
||||
# QT_VERSION: 5.15.2
|
||||
# QIF_VERSION: 4.4
|
||||
|
||||
steps:
|
||||
- name: Install Qt
|
||||
uses: jurplel/install-qt-action@v3
|
||||
with:
|
||||
version: '5.15.2'
|
||||
host: 'linux'
|
||||
target: 'desktop'
|
||||
arch: 'gcc_64'
|
||||
dir: '${{ github.workspace }}/Qt/'
|
||||
install-deps: 'true'
|
||||
modules: 'qtcharts'
|
||||
archives: 'qtbase qtsvg'
|
||||
cache: 'true'
|
||||
cache-key-prefix: 'install-qt-action-linux'
|
||||
setup-python: 'true'
|
||||
tools: 'tools_ifw tools_qtcreator,qt.tools.qtcreator'
|
||||
set-env: 'true'
|
||||
tools-only: 'false'
|
||||
aqtversion: '==2.1.*'
|
||||
py7zrversion: '==0.19.*'
|
||||
extra: '--external 7z'
|
||||
# steps:
|
||||
# - name: Install Qt
|
||||
# uses: jurplel/install-qt-action@v3
|
||||
# with:
|
||||
# version: '5.15.2'
|
||||
# host: 'linux'
|
||||
# target: 'desktop'
|
||||
# arch: 'gcc_64'
|
||||
# dir: '${{ github.workspace }}/Qt/'
|
||||
# install-deps: 'true'
|
||||
# modules: 'qtcharts'
|
||||
# archives: 'qtbase qtsvg'
|
||||
# cache: 'true'
|
||||
# cache-key-prefix: 'install-qt-action-linux'
|
||||
# setup-python: 'true'
|
||||
# tools: 'tools_ifw tools_qtcreator,qt.tools.qtcreator'
|
||||
# set-env: 'true'
|
||||
# tools-only: 'false'
|
||||
# aqtversion: '==2.1.*'
|
||||
# py7zrversion: '==0.19.*'
|
||||
# extra: '--external 7z'
|
||||
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 10
|
||||
# - uses: actions/checkout@v3
|
||||
# with:
|
||||
# fetch-depth: 10
|
||||
|
||||
- uses: awalsh128/cache-apt-pkgs-action@latest
|
||||
with:
|
||||
packages: p7zip p7zip-full python3 python3-pip libgl-dev mesa-common-dev libpulse-dev libxcb-* libxkbcommon-x11-0
|
||||
version: 1.0
|
||||
# - uses: awalsh128/cache-apt-pkgs-action@latest
|
||||
# with:
|
||||
# packages: p7zip p7zip-full python3 python3-pip libgl-dev mesa-common-dev libpulse-dev libxcb-* libxkbcommon-x11-0
|
||||
# version: 1.0
|
||||
|
||||
- name: Install Qt
|
||||
run: |
|
||||
if [ ! -f $QT_BIN_DIR/qmake ]; then \
|
||||
python3 -m pip install --user $(whoami) --upgrade pip && \
|
||||
export PATH=$HOME/.local/bin:$PATH && \
|
||||
python3 -m pip install -U aqtinstall requests py7zr && \
|
||||
python3 -m pip show aqtinstall && \
|
||||
python3 -m aqt install-qt linux desktop $QT_VERSION gcc_64 -m all -O $HOME/Qt && \
|
||||
python3 -m aqt install-tool linux desktop tools_ifw -O $HOME/Qt ; \
|
||||
fi
|
||||
# - name: Install Qt
|
||||
# run: |
|
||||
# if [ ! -f $QT_BIN_DIR/qmake ]; then \
|
||||
# python3 -m pip install --user $(whoami) --upgrade pip && \
|
||||
# export PATH=$HOME/.local/bin:$PATH && \
|
||||
# python3 -m pip install -U aqtinstall requests py7zr && \
|
||||
# python3 -m pip show aqtinstall && \
|
||||
# python3 -m aqt install-qt linux desktop $QT_VERSION gcc_64 -m all -O $HOME/Qt && \
|
||||
# python3 -m aqt install-tool linux desktop tools_ifw -O $HOME/Qt ; \
|
||||
# fi
|
||||
|
||||
- name: Cache Qt
|
||||
uses: actions/cache@v3
|
||||
id: cache-qt
|
||||
with:
|
||||
key: qt-5.15.2-linux
|
||||
path: "$HOME/Qt"
|
||||
# - name: Cache Qt
|
||||
# uses: actions/cache@v3
|
||||
# id: cache-qt
|
||||
# with:
|
||||
# key: qt-5.15.2-linux
|
||||
# path: "$HOME/Qt"
|
||||
|
||||
- name: Build project
|
||||
run: bash deploy/build_linux.sh
|
||||
# - name: Build project
|
||||
# run: bash deploy/build_linux.sh
|
||||
|
||||
|
||||
|
||||
Build-Windows-x64:
|
||||
name: Build-Windows-x64
|
||||
runs-on: ubuntu-latest
|
||||
Build-Windows:
|
||||
name: Build-Windows
|
||||
runs-on: windows-latest
|
||||
continue-on-error: true
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
arch: [32, 64]
|
||||
include:
|
||||
- qt-arch: 'win32_msvc2019'
|
||||
arch: 32
|
||||
- qt-msvc-path: 'msvc2019'
|
||||
arch: 32
|
||||
- msvc-arch: 'x86'
|
||||
arch: 32
|
||||
- qt-arch: 'win64_msvc2019_64'
|
||||
arch: 64
|
||||
- qt-msvc-path: 'msvc2019_64'
|
||||
arch: 64
|
||||
- msvc-arch: 'x64'
|
||||
arch: 64
|
||||
|
||||
env:
|
||||
QT_VERSION: 5.15.2
|
||||
QIF_VERSION: 4.4
|
||||
QIF_VERSION: 4.5
|
||||
BUILD_ARCH: ${{ matrix.arch }}
|
||||
|
||||
steps:
|
||||
- name: Install Qt
|
||||
- name: 'Get sources'
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
submodules: 'true'
|
||||
fetch-depth: 10
|
||||
|
||||
- name: 'Install Qt'
|
||||
uses: jurplel/install-qt-action@v3
|
||||
with:
|
||||
version: '5.15.2'
|
||||
version: ${{ env.QT_VERSION }}
|
||||
host: 'windows'
|
||||
target: 'desktop'
|
||||
arch: 'win64_msvc2019_64'
|
||||
dir: '${{ github.workspace }}/Qt/'
|
||||
install-deps: 'true'
|
||||
modules: 'qtcharts'
|
||||
archives: 'qtbase qtsvg'
|
||||
cache: 'false'
|
||||
cache-key-prefix: 'install-qt-action-windows64'
|
||||
arch: '${{ matrix.qt-arch }}'
|
||||
dir: ${{ runner.temp }}
|
||||
setup-python: 'true'
|
||||
tools: 'tools_ifw tools_qtcreator,qt.tools.qtcreator'
|
||||
tools: 'tools_ifw'
|
||||
set-env: 'true'
|
||||
tools-only: 'false'
|
||||
aqtversion: '==2.1.*'
|
||||
py7zrversion: '==0.19.*'
|
||||
extra: '--external 7z'
|
||||
|
||||
|
||||
- uses: actions/checkout@v3
|
||||
- name: 'Setup mvsc'
|
||||
uses: ilammy/msvc-dev-cmd@v1
|
||||
with:
|
||||
fetch-depth: 10
|
||||
arch: ${{ matrix.msvc-arch }}
|
||||
|
||||
- name: Build project
|
||||
run: cmd //c winbuild.bat
|
||||
- name: 'Build project'
|
||||
shell: cmd
|
||||
run: |
|
||||
set BUILD_ARCH=${{ env.BUILD_ARCH }}
|
||||
set QT_BIN_DIR="${{ runner.temp }}\\Qt\\${{ env.QT_VERSION }}\\${{ matrix.qt-msvc-path }}\\bin"
|
||||
set QIF_BIN_DIR="${{ runner.temp }}\\Qt\\Tools\\QtInstallerFramework\\${{ env.QIF_VERSION }}\\bin"
|
||||
call deploy\\build_windows.bat
|
||||
|
||||
|
||||
|
||||
Build-MacOS:
|
||||
name: Build-MacOS
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
env:
|
||||
QT_VERSION: 5.15.2
|
||||
QIF_VERSION: 4.4
|
||||
|
||||
steps:
|
||||
- name: Install Qt
|
||||
uses: jurplel/install-qt-action@v3
|
||||
- name: 'Upload artifact'
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
version: '5.15.2'
|
||||
host: 'mac'
|
||||
target: 'desktop'
|
||||
arch: 'clang_64'
|
||||
dir: '${{ github.workspace }}/Qt/'
|
||||
install-deps: 'true'
|
||||
modules: 'qtcharts'
|
||||
archives: 'qtbase qtsvg'
|
||||
cache: 'true'
|
||||
cache-key-prefix: 'install-qt-action-mac'
|
||||
setup-python: 'true'
|
||||
tools: 'tools_ifw tools_qtcreator,qt.tools.qtcreator'
|
||||
set-env: 'true'
|
||||
tools-only: 'false'
|
||||
aqtversion: '==2.1.*'
|
||||
py7zrversion: '==0.19.*'
|
||||
extra: '--external 7z'
|
||||
name: AmneziaVPN_x${{ env.BUILD_ARCH }}
|
||||
path: AmneziaVPN_x${{ env.BUILD_ARCH }}.exe
|
||||
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 10
|
||||
# Build-MacOS:
|
||||
# name: Build-MacOS
|
||||
# runs-on: ubuntu-latest
|
||||
|
||||
- name: Build project
|
||||
run: bash deploy/build_macos.sh
|
||||
# env:
|
||||
# QT_VERSION: 5.15.2
|
||||
# QIF_VERSION: 4.4
|
||||
|
||||
# steps:
|
||||
# - name: Install Qt
|
||||
# uses: jurplel/install-qt-action@v3
|
||||
# with:
|
||||
# version: '5.15.2'
|
||||
# host: 'mac'
|
||||
# target: 'desktop'
|
||||
# arch: 'clang_64'
|
||||
# dir: '${{ github.workspace }}/Qt/'
|
||||
# install-deps: 'true'
|
||||
# modules: 'qtcharts'
|
||||
# archives: 'qtbase qtsvg'
|
||||
# cache: 'true'
|
||||
# cache-key-prefix: 'install-qt-action-mac'
|
||||
# setup-python: 'true'
|
||||
# tools: 'tools_ifw tools_qtcreator,qt.tools.qtcreator'
|
||||
# set-env: 'true'
|
||||
# tools-only: 'false'
|
||||
# aqtversion: '==2.1.*'
|
||||
# py7zrversion: '==0.19.*'
|
||||
# extra: '--external 7z'
|
||||
|
||||
# - uses: actions/checkout@v3
|
||||
# with:
|
||||
# fetch-depth: 10
|
||||
|
||||
# - name: Build project
|
||||
# run: bash deploy/build_macos.sh
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue