2022-05-14 05:56:57 +00:00
|
|
|
name: Windows Build Steps - Qt
|
|
|
|
|
|
|
|
on:
|
|
|
|
workflow_call:
|
|
|
|
inputs:
|
|
|
|
jobName:
|
|
|
|
required: true
|
|
|
|
type: string
|
|
|
|
os:
|
|
|
|
required: false
|
|
|
|
type: string
|
|
|
|
default: windows-2019
|
|
|
|
platform:
|
|
|
|
required: false
|
|
|
|
type: string
|
|
|
|
default: x64
|
|
|
|
configuration:
|
|
|
|
required: true
|
|
|
|
type: string
|
|
|
|
simd:
|
|
|
|
required: false
|
|
|
|
type: string
|
|
|
|
default: AVX2
|
2022-05-23 03:33:32 +00:00
|
|
|
buildSystem:
|
|
|
|
required: false
|
|
|
|
type: string
|
|
|
|
default: msbuild
|
2022-05-14 05:56:57 +00:00
|
|
|
qt_binary_url:
|
|
|
|
required: false
|
|
|
|
type: string
|
2022-07-17 12:01:47 +00:00
|
|
|
default: https://github.com/PCSX2/pcsx2-windows-dependencies/releases/download/2022-07-24/qt-6.3.1-x64.7z
|
2022-05-14 05:56:57 +00:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build_windows_qt:
|
|
|
|
name: ${{ inputs.jobName }}
|
|
|
|
runs-on: ${{ inputs.os }}
|
|
|
|
# Set some sort of timeout in the event of run-away builds. We are limited on concurrent jobs so, get rid of them.
|
|
|
|
timeout-minutes: 60
|
|
|
|
env:
|
|
|
|
POWERSHELL_TELEMETRY_OPTOUT: 1
|
|
|
|
BUILDCACHE_COMPRESS_FORMAT: ZSTD
|
|
|
|
BUILDCACHE_COMPRESS_LEVEL: 9
|
|
|
|
BUILDCACHE_MAX_CACHE_SIZE: 536870912 # 512MB
|
|
|
|
BUILDCACHE_DIRECT_MODE: true
|
|
|
|
BUILDCACHE_LOG_FILE: ${{ github.workspace }}\buildcache.log
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Checkout Repository
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
submodules: recursive
|
|
|
|
|
|
|
|
- name: Prepare Artifact Metadata
|
|
|
|
id: artifact-metadata
|
|
|
|
shell: bash
|
|
|
|
env:
|
|
|
|
OS: windows
|
2022-05-23 03:33:32 +00:00
|
|
|
BUILD_SYSTEM: ${{ inputs.buildSystem }}
|
2022-05-14 05:56:57 +00:00
|
|
|
GUI_FRAMEWORK: Qt
|
|
|
|
ARCH: ${{ inputs.platform }}
|
|
|
|
SIMD: ${{ inputs.simd }}
|
|
|
|
EVENT_NAME: ${{ github.event_name }}
|
|
|
|
PR_TITLE: ${{ github.event.pull_request.title }}
|
|
|
|
PR_NUM: ${{ github.event.pull_request.number }}
|
|
|
|
PR_SHA: ${{ github.event.pull_request.head.sha }}
|
|
|
|
run: ./.github/workflows/scripts/common/name-artifacts.sh
|
|
|
|
|
|
|
|
- name: Setup msbuild
|
|
|
|
if: inputs.configuration != 'CMake'
|
|
|
|
uses: microsoft/setup-msbuild@v1
|
|
|
|
|
|
|
|
- name: Download Qt build files
|
|
|
|
shell: cmd
|
|
|
|
run: |
|
|
|
|
cd 3rdparty\qt
|
|
|
|
aria2c ${{ inputs.qt_binary_url }}
|
|
|
|
7z x qt-*-x64.7z
|
|
|
|
del qt-*-x64.7z
|
|
|
|
|
|
|
|
- name: Build PCSX2
|
|
|
|
shell: cmd
|
|
|
|
run: |
|
|
|
|
if "${{ inputs.configuration }}"=="CMake" (
|
|
|
|
call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\${{ steps.cmake.outputs.vcvars }}"
|
|
|
|
cmake --build build --config ${{ steps.cmake.outputs.buildtype }}
|
|
|
|
) else (
|
2022-05-16 23:12:26 +00:00
|
|
|
msbuild "PCSX2_qt.sln" /m /v:m /p:Configuration="${{ inputs.configuration }}" /p:Platform="${{ inputs.platform }}"
|
2022-05-14 05:56:57 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
- name: Upload artifact
|
|
|
|
uses: actions/upload-artifact@v3
|
|
|
|
with:
|
|
|
|
name: ${{ steps.artifact-metadata.outputs.artifact-name }}
|
|
|
|
path: |
|
|
|
|
./bin
|
|
|
|
!./bin/**/*.bsc
|
|
|
|
!./bin/**/*.exp
|
|
|
|
!./bin/**/*.ilk
|
|
|
|
!./bin/**/*.iobj
|
|
|
|
!./bin/**/*.ipdb
|
|
|
|
!./bin/**/*.pdb
|
|
|
|
!./bin/**/*.lib
|
|
|
|
|
|
|
|
- name: Upload artifact - with symbols
|
|
|
|
if: inputs.configuration != 'CMake'
|
|
|
|
uses: actions/upload-artifact@v3
|
|
|
|
with:
|
|
|
|
name: ${{ steps.artifact-metadata.outputs.artifact-name }}-symbols
|
|
|
|
path: ./bin/**/*.pdb
|