mirror of
https://github.com/YACReader/yacreader
synced 2025-07-20 05:54:39 -04:00
Merge pull request #76 from YACReader/feature/build-win32-binaries-azure-pipelines
Feature/build win32 binaries azure pipelines
This commit is contained in:
44
.travis.yml
44
.travis.yml
@ -1,44 +0,0 @@
|
|||||||
os:
|
|
||||||
- linux
|
|
||||||
- osx
|
|
||||||
dist:
|
|
||||||
- xenial
|
|
||||||
|
|
||||||
language:
|
|
||||||
- c++
|
|
||||||
|
|
||||||
compiler:
|
|
||||||
- gcc
|
|
||||||
- clang
|
|
||||||
|
|
||||||
addons:
|
|
||||||
apt:
|
|
||||||
sources:
|
|
||||||
- sourceline: 'deb http://download.opensuse.org/repositories/home:/selmf/xUbuntu_16.04/ /'
|
|
||||||
key_url: 'https://download.opensuse.org/repositories/home:selmf/xUbuntu_16.04/Release.key'
|
|
||||||
- sourceline: 'ppa:kubuntu-ppa/backports'
|
|
||||||
packages:
|
|
||||||
- qt-default
|
|
||||||
- qt5-qmake
|
|
||||||
- qtbase5-dev
|
|
||||||
- qtmultimedia5-dev
|
|
||||||
- libpoppler-qt5-dev
|
|
||||||
- qtscript5-dev
|
|
||||||
- libqt5opengl5-dev
|
|
||||||
- libglu1-mesa-dev
|
|
||||||
- libunarr-dev
|
|
||||||
- qtdeclarative5-dev
|
|
||||||
homebrew:
|
|
||||||
packages:
|
|
||||||
- qt
|
|
||||||
|
|
||||||
before_script:
|
|
||||||
- if [[ "$TRAVIS_OS_NAME" == "osx" ]];
|
|
||||||
then brew link qt --force;
|
|
||||||
qmake CONFIG+=unarr;
|
|
||||||
fi
|
|
||||||
- if [[ "$TRAVIS_OS_NAME" == "linux" ]];
|
|
||||||
then QT_SELECT=qt5 qmake CONFIG+=unarr;
|
|
||||||
fi
|
|
||||||
|
|
||||||
script: make
|
|
20
appveyor.yml
20
appveyor.yml
@ -1,20 +0,0 @@
|
|||||||
image: Visual Studio 2017
|
|
||||||
|
|
||||||
environment:
|
|
||||||
matrix:
|
|
||||||
- platform: x86
|
|
||||||
QT5: C:\Qt\5.12.1\msvc2017
|
|
||||||
VCVARS: '"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvars32.bat"'
|
|
||||||
- platform: x64
|
|
||||||
QT5: C:\Qt\5.12.1\msvc2017_64
|
|
||||||
VCVARS: '"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvars64.bat"'
|
|
||||||
|
|
||||||
before_build:
|
|
||||||
- set PATH=%QT5%\bin;%PATH%
|
|
||||||
- call %VCVARS%
|
|
||||||
- cd %APPVEYOR_BUILD_FOLDER%
|
|
||||||
- qmake CONFIG+=unarr
|
|
||||||
|
|
||||||
build_script:
|
|
||||||
- cd %APPVEYOR_BUILD_FOLDER%
|
|
||||||
- nmake
|
|
50
azure-pipelines-windows-template.yml
Normal file
50
azure-pipelines-windows-template.yml
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
parameters:
|
||||||
|
name: Windows_x64
|
||||||
|
arquitecture: 'x64'
|
||||||
|
qt_version: '5.12.4'
|
||||||
|
qt_spec: 'msvc2017_64'
|
||||||
|
qt_aqt_spec: 'win64_msvc2017_64'
|
||||||
|
vc_redist_url: 'https://go.microsoft.com/fwlink/?LinkId=746572'
|
||||||
|
vc_redist_file_name: 'vc_redist.x64.exe'
|
||||||
|
vc_vars: 'vcvars64.bat'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
- job: ${{ parameters.name }}
|
||||||
|
pool:
|
||||||
|
vmImage: 'vs2017-win2016'
|
||||||
|
steps:
|
||||||
|
- template: azure-pipelines-build-number.yml
|
||||||
|
- script: |
|
||||||
|
pip install aqtinstall
|
||||||
|
mkdir C:\Qt
|
||||||
|
python -m aqt install -O c:\Qt ${{ parameters.qt_version }} windows desktop ${{ parameters.qt_aqt_spec }}
|
||||||
|
choco install -y wget
|
||||||
|
choco install innosetup
|
||||||
|
wget "https://sourceforge.net/projects/sevenzip/files/7-Zip/18.05/7z1805-src.7z" -P $(Build.SourcesDirectory)\compressed_archive
|
||||||
|
7z x $(Build.SourcesDirectory)\compressed_archive\7z1805-src.7z -o$(Build.SourcesDirectory)\compressed_archive\lib7zip
|
||||||
|
wget "${{ parameters.vc_redist_url }}" -O $(Build.SourcesDirectory)\${{ parameters.vc_redist_file_name }}
|
||||||
|
displayName: 'Install dependencies'
|
||||||
|
- script: |
|
||||||
|
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Auxiliary\Build\${{ parameters.vc_vars }}"
|
||||||
|
set PATH=%PATH%;C:\Qt\Qt${{ parameters.qt_version }}\${{ parameters.qt_version }}\${{ parameters.qt_spec }}\bin
|
||||||
|
set DEFINES_VAR=DEFINES+="BUILD_NUMBER=\\\\\\\"$(Build.BuildNumber)\\\\\\\""
|
||||||
|
qmake CONFIG+="7zip" %DEFINES_VAR%
|
||||||
|
nmake
|
||||||
|
displayName: 'Build'
|
||||||
|
- script: |
|
||||||
|
set PATH=%PATH%;C:\Qt\Qt${{ parameters.qt_version }}\${{ parameters.qt_version }}\${{ parameters.qt_spec }}\bin
|
||||||
|
cd $(Build.SourcesDirectory)\ci\win
|
||||||
|
.\create_installer.cmd ${{ parameters.arquitecture }} 7z $(Build.BuildNumber)
|
||||||
|
displayName: 'Create installer'
|
||||||
|
- task: CopyFiles@2
|
||||||
|
inputs:
|
||||||
|
sourceFolder: $(Build.SourcesDirectory)\ci\win\Output\
|
||||||
|
contents: '*'
|
||||||
|
targetFolder: $(Build.ArtifactStagingDirectory)
|
||||||
|
- task: PublishPipelineArtifact@1
|
||||||
|
inputs:
|
||||||
|
path: $(Build.ArtifactStagingDirectory)
|
||||||
|
artifactName: Windows ${{ parameters.arquitecture }} $(Build.BuildNumber) 7z Installer
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -64,43 +64,23 @@ jobs:
|
|||||||
inputs:
|
inputs:
|
||||||
path: $(Build.ArtifactStagingDirectory)
|
path: $(Build.ArtifactStagingDirectory)
|
||||||
artifactName: Macos $(Build.BuildNumber) dmg
|
artifactName: Macos $(Build.BuildNumber) dmg
|
||||||
- job: Windows
|
- template: azure-pipelines-windows-template.yml
|
||||||
pool:
|
parameters:
|
||||||
vmImage: 'vs2017-win2016'
|
name: Windows_x64
|
||||||
steps:
|
arquitecture: 'x64'
|
||||||
- template: azure-pipelines-build-number.yml
|
qt_version: '5.12.4'
|
||||||
- script: |
|
qt_spec: 'msvc2017_64'
|
||||||
pip install aqtinstall
|
qt_aqt_spec: 'win64_msvc2017_64'
|
||||||
mkdir C:\Qt
|
vc_redist_url: 'https://go.microsoft.com/fwlink/?LinkId=746572'
|
||||||
python -m aqt install -O c:\Qt 5.12.4 windows desktop win64_msvc2017_64
|
vc_redist_file_name: 'vc_redist.x64.exe'
|
||||||
choco install -y wget
|
vc_vars: 'vcvars64.bat'
|
||||||
choco install innosetup
|
- template: azure-pipelines-windows-template.yml
|
||||||
wget "https://sourceforge.net/projects/sevenzip/files/7-Zip/18.05/7z1805-src.7z" -P $(Build.SourcesDirectory)\compressed_archive
|
parameters:
|
||||||
7z x $(Build.SourcesDirectory)\compressed_archive\7z1805-src.7z -o$(Build.SourcesDirectory)\compressed_archive\lib7zip
|
name: Windows_x86
|
||||||
wget "https://go.microsoft.com/fwlink/?LinkId=746572" -O $(Build.SourcesDirectory)\vc_redist.x64.exe
|
arquitecture: 'x86'
|
||||||
# 32bit https://go.microsoft.com/fwlink/?LinkId=746571
|
qt_version: '5.12.4'
|
||||||
displayName: 'Install dependencies'
|
qt_spec: 'msvc2017'
|
||||||
- script: |
|
qt_aqt_spec: 'win32_msvc2017'
|
||||||
call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Auxiliary\Build\vcvars64.bat"
|
vc_redist_url: 'https://go.microsoft.com/fwlink/?LinkId=746571'
|
||||||
set PATH=%PATH%;C:\Qt\Qt5.12.4\5.12.4\msvc2017_64\bin
|
vc_redist_file_name: 'vc_redist.x86.exe'
|
||||||
set DEFINES_VAR=DEFINES+="BUILD_NUMBER=\\\\\\\"$(Build.BuildNumber)\\\\\\\""
|
vc_vars: 'vcvars32.bat'
|
||||||
qmake CONFIG+="7zip" %DEFINES_VAR%
|
|
||||||
nmake
|
|
||||||
displayName: 'Build'
|
|
||||||
- script: |
|
|
||||||
set PATH=%PATH%;C:\Qt\Qt5.12.4\5.12.4\msvc2017_64\bin
|
|
||||||
cd $(Build.SourcesDirectory)\ci\win
|
|
||||||
.\create_installer.cmd x64 7z $(Build.BuildNumber)
|
|
||||||
displayName: 'Create installer'
|
|
||||||
- task: CopyFiles@2
|
|
||||||
inputs:
|
|
||||||
sourceFolder: $(Build.SourcesDirectory)\ci\win\Output\
|
|
||||||
contents: '*'
|
|
||||||
targetFolder: $(Build.ArtifactStagingDirectory)
|
|
||||||
- task: PublishPipelineArtifact@1
|
|
||||||
inputs:
|
|
||||||
path: $(Build.ArtifactStagingDirectory)
|
|
||||||
artifactName: Windows 64 $(Build.BuildNumber) 7z Installer
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -53,7 +53,8 @@ echo %VERSION%
|
|||||||
del
|
del
|
||||||
|
|
||||||
if "%1"=="x86" (
|
if "%1"=="x86" (
|
||||||
type build_installer.iss | findstr /v ArchitecturesInstallIn64BitMode | findstr /v ArchitecturesAllowed > build_installer.iss
|
type build_installer.iss | findstr /v ArchitecturesInstallIn64BitMode | findstr /v ArchitecturesAllowed > copy_build_installer.iss
|
||||||
|
type copy_build_installer.iss > build_installer.iss
|
||||||
)
|
)
|
||||||
|
|
||||||
iscc /DVERSION=%VERSION% /DPLATFORM=%1 /DCOMPRESSED_ARCHIVE_BACKEND=%2 /DBUILD_NUMBER=%3 build_installer.iss || exit /b
|
iscc /DVERSION=%VERSION% /DPLATFORM=%1 /DCOMPRESSED_ARCHIVE_BACKEND=%2 /DBUILD_NUMBER=%3 build_installer.iss || exit /b
|
||||||
|
Reference in New Issue
Block a user