# aka.ms/yaml # TODO: reuse steps trigger: - master - develop jobs: - job: Linux pool: vmImage: 'ubuntu-16.04' steps: - template: azure-pipelines-build-number.yml - script: | sudo add-apt-repository 'deb http://download.opensuse.org/repositories/home:/selmf/xUbuntu_16.04/ /' sudo add-apt-repository ppa:kubuntu-ppa/backports sudo apt-get update sudo apt-get install -y --allow-unauthenticated qt-default qt5-qmake \ qtbase5-dev qtmultimedia5-dev libpoppler-qt5-dev qtscript5-dev \ libqt5opengl5-dev libglu1-mesa-dev libunarr-dev qtdeclarative5-dev displayName: 'Install dependencies' - script: | export DEFINES_VAR=DEFINES+\=\"BUILD_NUMBER=\\\\\\\"$(Build.BuildNumber)\\\\\\\"\" qmake CONFIG+="unarr" $DEFINES_VAR make displayName: 'Build' - job: MacOS variables: - group: macos-codesign pool: vmImage: 'macOS-10.14' steps: - template: azure-pipelines-build-number.yml - script: | brew install qt brew link qt --force brew install create-dmg brew install clang-format brew install node brew link --overwrite node npm install -g appdmg wget "https://sourceforge.net/projects/p7zip/files/p7zip/16.02/p7zip_16.02_src_all.tar.bz2" -P $(Build.SourcesDirectory)/compressed_archive tar xjf $(Build.SourcesDirectory)/compressed_archive/p7zip_16.02_src_all.tar.bz2 -C $(Build.SourcesDirectory)/compressed_archive mv $(Build.SourcesDirectory)/compressed_archive/p7zip_16.02 $(Build.SourcesDirectory)/compressed_archive/libp7zip displayName: 'Install dependencies' - script: | cd $(Build.SourcesDirectory) find . \( -name '*.h' -or -name '*.cpp' -or -name '*.c' -or -name '*.mm' -or -name '*.m' \) -print0 | xargs -0 clang-format -style=file -i if [ "$(git diff $(Build.SourceVersion))" != "" ]; then exit 1; fi displayName: 'Check format' - task: InstallAppleCertificate@2 inputs: certSecureFile: 'developerID_application.p12' certPwd: $(P12Password) - script: | cd $(Build.SourcesDirectory) VERSION="$(cat common/yacreader_global.h | grep '#define VERSION "' | tr -d '#define VERSION' | tr -d '"' )" ./compileOSX.sh $VERSION $(Build.BuildNumber) displayName: 'Build' - task: CopyFiles@2 inputs: contents: '*.dmg' targetFolder: $(Build.ArtifactStagingDirectory) - task: PublishPipelineArtifact@1 inputs: path: $(Build.ArtifactStagingDirectory) artifactName: Macos $(Build.BuildNumber) dmg - template: azure-pipelines-windows-template.yml 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 - template: azure-pipelines-windows-template.yml name: Windows x86 arquitecture: x86 qt_version: 5.12.4 qt_spec: msvc2017 qt_aqt_spec: win32_msvc2017 vc_redist_url: https://go.microsoft.com/fwlink/?LinkId=746571 vc_redist_file_name: vc_redist.x86.exe vc_vars: vcvars32.bat