Merge pull request #1331 from xournalpp/update-azure
Separate pipelines and use Ninja for buildspresentation
commit
f1f8685f3e
10 changed files with 213 additions and 194 deletions
@ -1,4 +1,4 @@ |
||||
## Fix for windows |
||||
if (WIN32) |
||||
set (CMAKE_GENERATOR "MSYS Makefiles" CACHE INTERNAL "" FORCE) |
||||
set (CMAKE_GENERATOR "Ninja" CACHE INTERNAL "" FORCE) |
||||
endif () |
||||
|
||||
@ -1,96 +1,63 @@ |
||||
trigger: |
||||
branches: |
||||
include: |
||||
- '*' |
||||
- '*' |
||||
exclude: |
||||
- stable |
||||
- l10n_master |
||||
- stable |
||||
- l10n_master |
||||
paths: |
||||
exclude: |
||||
- po/xournalpp.pot |
||||
- po/*.po |
||||
|
||||
- po/xournalpp.pot |
||||
- po/*.po |
||||
|
||||
|
||||
stages: |
||||
- stage: 'Build_Test_Stage' |
||||
jobs: |
||||
- job: 'Linux' |
||||
pool: |
||||
vmImage: 'ubuntu-16.04' |
||||
displayName: 'Test Xournal++ on Linux' |
||||
steps: |
||||
- bash: | |
||||
sudo apt-get update |
||||
sudo apt-get install -y cmake libcppunit-dev libgtk-3-dev libpoppler-glib-dev portaudio19-dev libsndfile-dev liblua5.3-dev libzip-dev |
||||
displayName: 'Install dependencies' |
||||
- bash: | |
||||
mkdir build |
||||
displayName: 'Create build directory' |
||||
- bash: | |
||||
cmake .. -DCMAKE_DEBUG_INCLUDES_LDFLAGS=ON -DENABLE_CPPUNIT=ON -DDEBUG_COMPILE=ON |
||||
make -j `grep processor /proc/cpuinfo | tail -c 2` |
||||
workingDirectory: ./build |
||||
displayName: 'Build Xournal++' |
||||
- bash: | |
||||
ctest |
||||
workingDirectory: ./build |
||||
displayName: 'Run tests' |
||||
- stage: 'Build_Test_Stage' |
||||
jobs: |
||||
- job: 'Linux' |
||||
pool: |
||||
vmImage: 'ubuntu-16.04' |
||||
displayName: 'Test Xournal++ on Linux' |
||||
steps: |
||||
- template: steps/build_linux.yml |
||||
parameters: |
||||
build_type: 'Debug' |
||||
cmake_flags: '-DCMAKE_DEBUG_INCLUDES_LDFLAGS=ON -DENABLE_CPPUNIT=ON -DDEBUG_COMPILE=ON' |
||||
- bash: | |
||||
ctest --verbose |
||||
workingDirectory: ./build |
||||
displayName: 'Run tests' |
||||
|
||||
- job: 'Windows' |
||||
pool: |
||||
vmImage: 'vs2017-win2016' |
||||
displayName: 'Test Xournal++ on Windows' |
||||
steps: |
||||
- template: steps/build_windows.yml |
||||
parameters: |
||||
build_type: 'Debug' |
||||
cmake_flags: '-DCMAKE_DEBUG_INCLUDES_LDFLAGS=ON -DENABLE_CPPUNIT=ON -DDEBUG_COMPILE=ON' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "ctest --verbose" |
||||
workingDirectory: ./build |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Run tests' |
||||
|
||||
- job: Windows |
||||
pool: |
||||
vmImage: 'vs2017-win2016' |
||||
displayName: 'Build for Windows' |
||||
steps: |
||||
- script: | |
||||
git clone https://github.com/msys2/msys2-ci-base.git %CD:~0,2%\msys64 |
||||
%CD:~0,2%\msys64\usr\bin\rm -rf %CD:~0,2%\msys64\.git |
||||
displayName: 'Install MSYS2' |
||||
- script: | |
||||
set PATH=%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syuu |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syuu |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -S mingw-w64-x86_64-cmake make mingw-w64-x86_64-toolchain |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm --needed -S base-devel mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -S mingw-w64-x86_64-poppler mingw-w64-x86_64-gtk3 mingw-w64-x86_64-libsndfile mingw-w64-x86_64-libzip |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Scc |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Install dependencies on Windows' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "./build-portaudio.sh" |
||||
workingDirectory: ./windows-setup |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Portaudio' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "./build-lua.sh" |
||||
workingDirectory: ./windows-setup |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Lua' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "mkdir build" |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Create build directory' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "cmake .." |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "make" |
||||
workingDirectory: ./build |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Xournal++' |
||||
# - job: macOS |
||||
# pool: |
||||
# vmImage: 'macOS-10.13' |
||||
# displayName: 'Test Xournal++ on MacOS' |
||||
# steps: |
||||
# - template: steps/build_mac.yml |
||||
# parameters: |
||||
# build_type: 'Debug' |
||||
# cmake_flags: '-DCMAKE_DEBUG_INCLUDES_LDFLAGS=ON -DENABLE_CPPUNIT=ON -DDEBUG_COMPILE=ON' |
||||
# - bash: | |
||||
# ctest --verbose |
||||
# workingDirectory: ./build |
||||
# displayName: 'Run tests' |
||||
# |
||||
|
||||
@ -1,89 +1,45 @@ |
||||
trigger: |
||||
- master |
||||
- master |
||||
pr: none |
||||
|
||||
stages: |
||||
- stage: Release |
||||
jobs: |
||||
- job: Windows |
||||
pool: |
||||
vmImage: 'vs2017-win2016' |
||||
displayName: 'Build for Windows' |
||||
steps: |
||||
- script: | |
||||
git clone https://github.com/msys2/msys2-ci-base.git %CD:~0,2%\msys64 |
||||
%CD:~0,2%\msys64\usr\bin\rm -rf %CD:~0,2%\msys64\.git |
||||
displayName: 'Install MSYS2' |
||||
- script: | |
||||
set PATH=%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syuu |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syuu |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -S mingw-w64-x86_64-cmake make mingw-w64-x86_64-toolchain |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm --needed -S base-devel mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -S mingw-w64-x86_64-poppler mingw-w64-x86_64-gtk3 mingw-w64-x86_64-libsndfile mingw-w64-x86_64-libzip |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Scc |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Install dependencies on Windows' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "./build-portaudio.sh" |
||||
workingDirectory: ./windows-setup |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Portaudio' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "./build-lua.sh" |
||||
workingDirectory: ./windows-setup |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Lua' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "mkdir build" |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Create build directory' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "cmake .." |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "make" |
||||
workingDirectory: ./build |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Xournal++' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "./build-setup.sh" |
||||
workingDirectory: ./windows-setup |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Create Setup' |
||||
- task: PublishPipelineArtifact@0 |
||||
inputs: |
||||
artifactName: 'windows' |
||||
targetPath: './windows-setup/xournalpp-setup.exe' |
||||
displayName: 'Publish Windows Setup' |
||||
|
||||
# - job: macOS |
||||
# pool: |
||||
# vmImage: 'macOS-10.13' |
||||
# displayName: 'Build for macOS' |
||||
# steps: |
||||
# - bash: | |
||||
# echo !!!TODO!!! |
||||
# displayName: 'Install dependencies on macOS' |
||||
- stage: Release |
||||
jobs: |
||||
- job: Windows |
||||
pool: |
||||
vmImage: 'vs2017-win2016' |
||||
displayName: 'Build Release for Windows' |
||||
steps: |
||||
- template: steps/build_windows.yml |
||||
parameters: |
||||
build_type: 'Release' |
||||
cmake_flags: '' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "./build-setup.sh" |
||||
workingDirectory: ./windows-setup |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Create Setup' |
||||
- task: PublishPipelineArtifact@0 |
||||
inputs: |
||||
artifactName: 'windows' |
||||
targetPath: './windows-setup/xournalpp-setup.exe' |
||||
displayName: 'Publish Windows Setup' |
||||
|
||||
# - job: macOS |
||||
# pool: |
||||
# vmImage: 'macOS-10.13' |
||||
# displayName: 'Build for macOS' |
||||
# steps: |
||||
# - template: steps/build_mac.yml |
||||
# parameters: |
||||
# build_type: 'Release' |
||||
# cmake_flags: '' |
||||
# - bash: | |
||||
# ctest |
||||
# workingDirectory: ./build |
||||
# displayName: 'Run tests' |
||||
# |
||||
|
||||
@ -0,0 +1,19 @@ |
||||
# Template for building Xournal++ on Linux |
||||
|
||||
parameters: |
||||
build_type: 'Debug' |
||||
cmake_flags: '' |
||||
|
||||
steps: |
||||
- bash: | |
||||
sudo apt-get update |
||||
sudo apt-get install -y cmake ninja-build libcppunit-dev libgtk-3-dev libpoppler-glib-dev portaudio19-dev libsndfile-dev liblua5.3-dev libzip-dev |
||||
displayName: 'Install dependencies' |
||||
- bash: | |
||||
mkdir build |
||||
displayName: 'Create build directory' |
||||
- bash: | |
||||
cmake -GNinja .. -DCMAKE_BUILD_TYPE=${{ parameters.build_type}} ${{ parameters.cmake_flags }} |
||||
cmake --build . |
||||
workingDirectory: ./build |
||||
displayName: 'Build Xournal++' |
||||
@ -0,0 +1,20 @@ |
||||
parameters: |
||||
build_type: '' |
||||
cmake_flags: '' |
||||
|
||||
steps: |
||||
- bash: | |
||||
brew update |
||||
brew upgrade |
||||
brew install cmake ninja pkg-config gtk+3 poppler librsvg adwaita-icon-theme portaudio libsndfile lua libzip cppunit gettext |
||||
displayName: 'Install dependencies' |
||||
- bash: | |
||||
mkdir build |
||||
displayName: 'Create build directory' |
||||
- bash: | |
||||
export PKG_CONFIG_PATH="/usr/local/opt/libffi/lib/pkgconfig:$PKG_CONFIG_PATH" |
||||
export LDFLAGS="-L/usr/local/opt/libffi/lib $LDFLAGS" |
||||
cmake -GNinja .. -DCMAKE_BUILD_TYPE=${{ parameters.build_type}} ${{ parameters.cmake_flags }} |
||||
cmake --build . |
||||
workingDirectory: ./build |
||||
displayName: 'Build Xournal++' |
||||
@ -0,0 +1,57 @@ |
||||
parameters: |
||||
build_type: '' |
||||
cmake_flags: '' |
||||
|
||||
steps: |
||||
- script: | |
||||
git clone https://github.com/msys2/msys2-ci-base.git %CD:~0,2%\msys64 |
||||
%CD:~0,2%\msys64\usr\bin\rm -rf %CD:~0,2%\msys64\.git |
||||
displayName: 'Install MSYS2' |
||||
- script: | |
||||
set PATH=%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syuu |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syuu |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -S mingw-w64-x86_64-toolchain mingw-w64-x86_64-cmake mingw-w64-x86_64-make mingw-w64-x86_64-ninja patch mingw-w64-x86_64-cppunit |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -S mingw-w64-x86_64-poppler mingw-w64-x86_64-gtk3 mingw-w64-x86_64-libsndfile mingw-w64-x86_64-libzip |
||||
%CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Scc |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Install dependencies on Windows' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "./build-portaudio.sh" |
||||
workingDirectory: ./windows-setup |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Portaudio' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "./build-lua.sh" |
||||
workingDirectory: ./windows-setup |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Lua' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "mkdir build" |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Create build directory' |
||||
- script: | |
||||
set PATH=%PATH%;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\mingw64\bin" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "cmake .. -DCMAKE_BUILD_TYPE=${{ parameters.build_type}} ${{ parameters.cmake_flags }}" |
||||
%CD:~0,2%\msys64\usr\bin\bash -lc "cmake --build ." |
||||
workingDirectory: ./build |
||||
env: |
||||
MSYS2_ARCH: x86_64 |
||||
MSYSTEM: MINGW64 |
||||
CHERE_INVOKING: yes |
||||
displayName: 'Build Xournal++' |
||||
Loading…
Reference in new issue