forked from GUDHI/gudhi-devel
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
90 lines (84 loc) · 3.63 KB
/
azure-pipelines.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
jobs:
- job: 'OSx'
displayName: "Build and test OSx"
timeoutInMinutes: 0
cancelTimeoutInMinutes: 60
pool:
vmImage: macOS-latest
variables:
pythonVersion: '3.7'
cmakeBuildType: Release
steps:
# Use a specific Python version
- task: UsePythonVersion@0
displayName: Use Python $(pythonVersion)
inputs:
versionSpec: $(pythonVersion)
addToPath: true
architecture: 'x64'
- bash: |
git submodule update --init
python -m pip install --user -r ext/gudhi-deploy/build-requirements.txt
python -m pip install --user -r ext/gudhi-deploy/test-requirements.txt
python -m pip uninstall -y pykeops
brew update || true
brew install graphviz doxygen boost eigen gmp mpfr tbb cgal || true
displayName: 'Install build dependencies'
- bash: |
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE:STRING=$(cmakeBuildType) -DWITH_GUDHI_EXAMPLE=ON -DWITH_GUDHI_TEST=ON -DWITH_GUDHI_UTILITIES=ON -DWITH_GUDHI_PYTHON=ON ..
make
make doxygen
ctest --output-on-failure
displayName: 'Build, test and documentation generation'
- job: 'Windows'
displayName: "Build and test Windows"
timeoutInMinutes: 0
cancelTimeoutInMinutes: 60
pool:
vmImage: windows-latest
variables:
pythonVersion: '3.7'
cmakeVcpkgFlags: -DVCPKG_TARGET_TRIPLET=x64-windows -DCMAKE_TOOLCHAIN_FILE=c:\vcpkg\scripts\buildsystems\vcpkg.cmake
cmakeFlags: -DWITH_GUDHI_EXAMPLE=ON -DWITH_GUDHI_TEST=ON -DWITH_GUDHI_UTILITIES=ON -DWITH_GUDHI_PYTHON=OFF
steps:
# Use a specific Python version
- task: UsePythonVersion@0
displayName: Use Python $(pythonVersion)
inputs:
versionSpec: $(pythonVersion)
addToPath: true
architecture: 'x64'
- script: |
git submodule update --init
python -m pip install --user -r ext/gudhi-deploy/build-requirements.txt
# No PyKeOps on windows, let's workaround this one.
for /F "tokens=*" %%A in (ext\gudhi-deploy\test-requirements.txt) do python -m pip install %%A
vcpkg install boost-filesystem:x64-windows boost-test:x64-windows boost-program-options:x64-windows tbb:x64-windows eigen3:x64-windows cgal:x64-windows
displayName: 'Install build dependencies'
- script: |
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" amd64
IF %errorlevel% NEQ 0 exit /b %errorlevel%
mkdir build
cd build
cmake -G "Visual Studio 17 2022" -A x64 -DCMAKE_BUILD_TYPE=Release -DFORCE_EIGEN_DEFAULT_DENSE_INDEX_TYPE_TO_INT=ON $(cmakeVcpkgFlags) $(cmakeFlags) ..
IF %errorlevel% NEQ 0 exit /b %errorlevel%
MSBuild GUDHIdev.sln /m /p:Configuration=Release /p:Platform=x64
IF %errorlevel% NEQ 0 exit /b %errorlevel%
ctest --output-on-failure -C Release -E diff_files
IF %errorlevel% NEQ 0 exit /b %errorlevel%
cmake -DWITH_GUDHI_PYTHON=ON .
IF %errorlevel% NEQ 0 exit /b %errorlevel%
cd src\python
copy "C:\vcpkg\installed\x64-windows\bin\mpfr*.dll" ".\gudhi\"
copy "C:\vcpkg\installed\x64-windows\bin\gmp*.dll" ".\gudhi\"
copy "C:\vcpkg\installed\x64-windows\bin\tbb.dll" ".\gudhi\"
copy "C:\vcpkg\installed\x64-windows\bin\tbbmalloc.dll" ".\gudhi\"
python setup.py build_ext --inplace
IF %errorlevel% NEQ 0 exit /b %errorlevel%
SET PYTHONPATH=%CD%;%PYTHONPATH%
echo %PYTHONPATH%
ctest --output-on-failure -C Release
IF %errorlevel% NEQ 0 exit /b %errorlevel%
displayName: 'Build and test'