forked from dmlc/dmlc-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
appveyor.yml
134 lines (129 loc) · 4.78 KB
/
appveyor.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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
environment:
matrix:
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
target: msvc
ver: 2019
generator: "Visual Studio 16 2019"
configuration: Debug
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
target: msvc
ver: 2019
generator: "Visual Studio 16 2019"
configuration: Release
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
target: mingw32
generator: "MinGW Makefiles"
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
target: cygwin
generator: "Unix Makefiles"
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
target: mingw
generator: "MinGW Makefiles"
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
target: msys2
generator: "Unix Makefiles"
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
target: msvc
ver: 2013
generator: "Visual Studio 12 2013 Win64"
configuration: Release
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
target: msvc
ver: 2015
generator: "Visual Studio 14 2015 Win64"
configuration: Debug
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
target: msvc
ver: 2015
generator: "Visual Studio 14 2015 Win64"
configuration: Release
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
target: msvc
ver: 2017
generator: "Visual Studio 15 2017 Win64"
configuration: Debug
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
target: msvc
ver: 2017
generator: "Visual Studio 15 2017 Win64"
configuration: Release
matrix:
fast_finish: true
platform:
- x64
install:
- git submodule update --init --recursive
# Set PATH
- if /i "%target%" == "msys2" set PATH=C:\msys64\mingw64\bin;C:\msys64\usr\bin;%PATH%
- if /i "%target%" == "mingw32" set PATH=C:\mingw-w64\i686-6.3.0-posix-dwarf-rt_v5-rev1\mingw32\bin;%PATH:C:\Program Files\Git\usr\bin;=%
- if /i "%target%" == "mingw" set PATH=C:\MinGW-w64\x86_64-7.3.0-posix-seh-rt_v5-rev0\mingw64\bin;%PATH:C:\Program Files\Git\usr\bin;=%
- if /i "%target%" == "cygwin" set PATH=C:\cygwin64\bin;C:\cygwin64\usr\bin;%PATH%
# Install packages and show information
- if /i "%target%" == "msys2" (
gcc -v
)
- if /i "%target%" == "mingw" (
gcc -v
)
- if /i "%target%" == "cygwin" (
gcc -v
)
build_script:
- cd %APPVEYOR_BUILD_FOLDER%
- if /i "%target%" == "msvc" (
mkdir build_msvc%ver% &&
cd build_msvc%ver% &&
if /i "%generator%" == "Visual Studio 12 2013 Win64" (
cmake .. -G"%generator%" -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_CONFIGURATION_TYPES="Release;Debug;" &&
msbuild dmlc.sln
) else if /i "%generator%" == "Visual Studio 16 2019" (
cmake .. -G"%generator%" -A x64 -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_CONFIGURATION_TYPES="Release;Debug;" -DGOOGLE_TEST=ON &&
msbuild dmlc.sln
) else (
cmake .. -G"%generator%" -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_CONFIGURATION_TYPES="Release;Debug;" -DGOOGLE_TEST=ON &&
msbuild dmlc.sln
)
)
- if /i "%target%" == "msys2" (
mkdir build_msys2 &&
cd build_msys2 &&
cmake .. -G"%generator%" -DCMAKE_VERBOSE_MAKEFILE=ON -DGOOGLE_TEST=ON &&
cmake --build . -- -j2
)
- if /i "%target%" == "mingw32" (
mkdir build_mingw32 &&
cd build_mingw32 &&
cmake .. -G"%generator%" -DCMAKE_VERBOSE_MAKEFILE=ON -DGOOGLE_TEST=ON &&
cmake --build . -- -j2
)
- if /i "%target%" == "mingw" (
mkdir build_mingw &&
cd build_mingw &&
cmake .. -G"%generator%" -DCMAKE_VERBOSE_MAKEFILE=ON -DGOOGLE_TEST=ON &&
cmake --build . -- -j2
)
- if /i "%target%" == "cygwin" (
mkdir build_cygwin &&
cd build_cygwin &&
cmake .. -G"%generator%" -DCMAKE_VERBOSE_MAKEFILE=ON -DGOOGLE_TEST=ON -DOpenMP_gomp_LIBRARY:FILEPATH=-lgomp &&
cmake --build . -- -j2
)
test_script:
- cd %APPVEYOR_BUILD_FOLDER%
- if /i "%target%" == "msvc" (
if /i not "%generator%" == "Visual Studio 12 2013 Win64" (
.\build_msvc%ver%\test\unittest\%configuration%\dmlc_unit_tests.exe
)
)
- if /i "%target%" == "msys2" (
.\build_msys2\test\unittest\dmlc_unit_tests.exe
)
- if /i "%target%" == "mingw32" (
.\build_mingw32\test\unittest\dmlc_unit_tests.exe
)
- if /i "%target%" == "mingw" (
.\build_mingw\test\unittest\dmlc_unit_tests.exe
)
- if /i "%target%" == "cygwin" (
.\build_cygwin\test\unittest\dmlc_unit_tests.exe
)