Update ccpp.yml
[ACE_TAO.git] / azure-pipelines.yml
blobddca4e85fa4c3d71b5e30a772590fb9414f77172
1 variables:
2    ACE_ROOT: $(Build.SourcesDirectory)/ACE
3    TAO_ROOT: $(Build.SourcesDirectory)/TAO
4    MPC_ROOT: $(Build.SourcesDirectory)/ACE/MPC
5    system.prefergit: true
7 schedules:
8 - cron: "0 7 * * SUN"
9   displayName: Weekly Sunday
10   branches:
11     include:
12     - master
13   always: true
15 resources:
16 - repo: self
17   fetchDepth: 1
19 jobs:
20 - job: VisualStudio2019
21   timeoutInMinutes: 120
22   pool:
23     vmImage: windows-2019
24   strategy:
25     matrix:
26       WChar:
27         BuildPlatform: x64
28         BuildConfiguration: Debug
29         vcpkgarch: x64-windows
30         vcpkglibdir: debug\lib
31         vcpkgpackages: 'openssl xerces-c[xmlch_wchar]'
32         OptionalFeatures: uses_wchar=1
33       Debug64:
34         BuildPlatform: x64
35         BuildConfiguration: Debug
36         vcpkgarch: x64-windows
37         vcpkglibdir: debug\lib
38         vcpkgpackages: openssl xerces-c
39       Release64:
40         BuildPlatform: x64
41         BuildConfiguration: Release
42         vcpkgarch: x64-windows
43         vcpkglibdir: lib
44         vcpkgpackages: openssl xerces-c
45       Debug32:
46         BuildPlatform: Win32
47         BuildConfiguration: Debug
48         vcpkgarch: x86-windows
49         vcpkglibdir: debug\lib
50         vcpkgpackages: openssl xerces-c
51       Release32:
52         BuildPlatform: Win32
53         BuildConfiguration: Release
54         vcpkgarch: x86-windows
55         vcpkglibdir: lib
56         vcpkgpackages: openssl xerces-c
57   variables:
58     VCPKG_ROOT: $(Build.SourcesDirectory)\vcpkg
59     XERCESC_INCDIR: $(VCPKG_ROOT)\installed\$(vcpkgarch)\include
60     XERCESC_LIBDIR: $(VCPKG_ROOT)\installed\$(vcpkgarch)\$(vcpkglibdir)
61     SSL_INCDIR: $(VCPKG_ROOT)\installed\$(vcpkgarch)\include
62     SSL_LIBDIR: $(VCPKG_ROOT)\installed\$(vcpkgarch)\$(vcpkglibdir)
63   steps:
64   - powershell: |
65       git clone -q --depth 1 git://github.com/Microsoft/vcpkg.git $(VCPKG_ROOT)
66       $(VCPKG_ROOT)\bootstrap-vcpkg.bat
67       $(VCPKG_ROOT)\vcpkg install --recurse --triplet $(vcpkgarch) $(vcpkgpackages)
68     displayName: Install additional packages using vcpkg
69   - powershell: |
70       '#include "ace/config-win32.h"' > $(ACE_ROOT)/ace/config.h
71     displayName: Create config.h file
72   - powershell: |
73       echo "xerces3=1" | out-file -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
74       echo "ssl=1" | out-file -append -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
75       echo "versioned_namespace=1" | out-file -append -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
76     displayName: Create default.features file
77   - powershell: |
78       echo $(OptionalFeatures) | out-file -append -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
79     displayName: Add optional features ($(OptionalFeatures))
80     condition: and(succeeded(), ne(variables['OptionalFeatures'], ''))
81   - powershell: git clone -q --depth 1 git://github.com/DOCGroup/MPC.git $(MPC_ROOT)
82     displayName: git clone MPC
83   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type vs2019 $(TAO_ROOT)/TAO_ACE.mwc -workers 4
84     displayName: Run script mwc.pl on $(TAO_ROOT)/TAO_ACE.mwc
85   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type vs2019 $(ACE_ROOT)/tests/tests.mwc -workers 4
86     displayName: Run script mwc.pl on $(ACE_ROOT)/tests/tests.mwc
87   - task: VSBuild@1
88     displayName: Build solution TAO/TAO_ACE.sln
89     inputs:
90       solution: TAO/TAO_ACE.sln
91       platform: $(BuildPlatform)
92       configuration: $(BuildConfiguration)
93       maximumCpuCount: true
94   - task: VSBuild@1
95     displayName: Build solution ACE/tests/tests.sln
96     inputs:
97       solution: ACE/tests/tests.sln
98       platform: $(BuildPlatform)
99       configuration: $(BuildConfiguration)
100       maximumCpuCount: true
102 - job: VisualStudio2017
103   timeoutInMinutes: 120
104   pool:
105     vmImage: vs2017-win2016
106   strategy:
107     matrix:
108       WChar:
109         BuildPlatform: x64
110         BuildConfiguration: Debug
111         vcpkgarch: x64-windows
112         vcpkglibdir: debug\lib
113         vcpkgpackages: 'openssl xerces-c[xmlch_wchar]'
114         OptionalFeatures: uses_wchar=1
115       Debug64:
116         BuildPlatform: x64
117         BuildConfiguration: Debug
118         vcpkgarch: x64-windows
119         vcpkglibdir: debug\lib
120         vcpkgpackages: openssl xerces-c
121       Release64:
122         BuildPlatform: x64
123         BuildConfiguration: Release
124         vcpkgarch: x64-windows
125         vcpkglibdir: lib
126         vcpkgpackages: openssl xerces-c
127   variables:
128     VCPKG_ROOT: $(Build.SourcesDirectory)\vcpkg
129     XERCESC_INCDIR: $(VCPKG_ROOT)\installed\$(vcpkgarch)\include
130     XERCESC_LIBDIR: $(VCPKG_ROOT)\installed\$(vcpkgarch)\$(vcpkglibdir)
131     SSL_INCDIR: $(VCPKG_ROOT)\installed\$(vcpkgarch)\include
132     SSL_LIBDIR: $(VCPKG_ROOT)\installed\$(vcpkgarch)\$(vcpkglibdir)
133   steps:
134   - powershell: |
135       git clone --depth 1 git://github.com/Microsoft/vcpkg.git $(VCPKG_ROOT)
136       $(VCPKG_ROOT)\bootstrap-vcpkg.bat
137       $(VCPKG_ROOT)\vcpkg install --recurse --triplet $(vcpkgarch) $(vcpkgpackages)
138     displayName: Install additional packages using vcpkg
139   - powershell: |
140       '#include "ace/config-win32.h"' > $(ACE_ROOT)/ace/config.h
141     displayName: Create config.h file
142   - powershell: |
143       echo "xerces3=1" | out-file -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
144       echo "ssl=1" | out-file -append -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
145       echo "versioned_namespace=1" | out-file -append -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
146     displayName: Create default.features file
147   - powershell: |
148       echo $(OptionalFeatures) | out-file -append -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
149     displayName: Add optional features ($(OptionalFeatures))
150     condition: and(succeeded(), ne(variables['OptionalFeatures'], ''))
151   - powershell: git clone --depth 1 git://github.com/DOCGroup/MPC.git $(MPC_ROOT)
152     displayName: git clone MPC
153   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type vs2017 $(TAO_ROOT)/TAO_ACE.mwc -workers 4
154     displayName: Run script mwc.pl on $(TAO_ROOT)/TAO_ACE.mwc
155   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type vs2017 $(ACE_ROOT)/tests/tests.mwc -workers 4
156     displayName: Run script mwc.pl on $(ACE_ROOT)/tests/tests.mwc
157   - task: VSBuild@1
158     displayName: Build solution TAO/TAO_ACE.sln
159     inputs:
160       solution: TAO/TAO_ACE.sln
161       platform: $(BuildPlatform)
162       configuration: $(BuildConfiguration)
163       maximumCpuCount: true
164   - task: VSBuild@1
165     displayName: Build solution ACE/tests/tests.sln
166     inputs:
167       solution: ACE/tests/tests.sln
168       platform: $(BuildPlatform)
169       configuration: $(BuildConfiguration)
170       maximumCpuCount: true
172 - job: VisualStudio2015
173   timeoutInMinutes: 90
174   pool:
175     vmImage: vs2015-win2012r2
176   strategy:
177     matrix:
178       Debug64:
179         BuildPlatform: x64
180         BuildConfiguration: Debug
181         vcpkgarch: x64-windows
182         vcpkglibdir: debug\lib
183       Release64:
184         BuildPlatform: x64
185         BuildConfiguration: Release
186         vcpkgarch: x64-windows
187         vcpkglibdir: lib
188   variables:
189     XERCESCROOT: $(Build.SourcesDirectory)\vcpkg\packages\xerces-c_$(vcpkgarch)
190     SSL_ROOT: $(Build.SourcesDirectory)\vcpkg\packages\openssl-windows_$(vcpkgarch)
191     SSL_LIBDIR: $(SSL_ROOT)\$(vcpkglibdir)
192     XERCESC_LIBDIR: $(XERCESCROOT)\$(vcpkglibdir)
193     VCPKG_ROOT: $(Build.SourcesDirectory)\vcpkg
194   steps:
195   - powershell: |
196       git clone --depth 1 git://github.com/Microsoft/vcpkg.git $(VCPKG_ROOT)
197       $(VCPKG_ROOT)\bootstrap-vcpkg.bat
198       $(VCPKG_ROOT)\vcpkg.exe install --recurse --triplet $(vcpkgarch) openssl xerces-c
199     displayName: vcpkg
200   - powershell: |
201       '#include "ace/config-win32.h"' > $(ACE_ROOT)/ace/config.h
202     displayName: Create config.h file
203   - powershell: |
204       echo "xerces3=1" | out-file -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
205       echo "ssl=1" | out-file -append -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
206       echo "versioned_namespace=1" | out-file -append -encoding ASCII $(ACE_ROOT)\bin\MakeProjectCreator\config\default.features
207     displayName: Create default.features file
208   - powershell: git clone --depth 1 git://github.com/DOCGroup/MPC.git $(MPC_ROOT)
209     displayName: git clone MPC
210   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type vc14 $(TAO_ROOT)/TAO_ACE.mwc -workers 4
211     displayName: Run script mwc.pl on $(TAO_ROOT)/TAO_ACE.mwc
212   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type vc14 $(ACE_ROOT)/tests/tests.mwc -workers 4
213     displayName: Run script mwc.pl on $(ACE_ROOT)/tests/tests.mwc
214   - task: VSBuild@1
215     displayName: Build solution TAO\TAO_ACE.sln
216     inputs:
217       solution: TAO\TAO_ACE.sln
218       platform: $(BuildPlatform)
219       configuration: $(BuildConfiguration)
220       maximumCpuCount: true
221   - task: VSBuild@1
222     displayName: Build solution ACE\tests\tests.sln
223     inputs:
224       solution: ACE\tests\tests.sln
225       platform: $(BuildPlatform)
226       configuration: $(BuildConfiguration)
227       maximumCpuCount: true
229 - job: Linux
230   timeoutInMinutes: 90
231   pool:
232     vmImage: ubuntu-16.04
233   strategy:
234     matrix:
235       GCC4:
236         CC: gcc
237         CXX: g++
238         platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
239       GCC6:
240         CC: gcc-6
241         CXX: g++-6
242         PackageDeps: g++-6
243         platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
244       GCC7:
245         CC: gcc-7
246         CXX: g++-7
247         PackageDeps: g++-7
248         platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
249       GCC8:
250         CC: gcc-8
251         CXX: g++-8
252         PackageDeps: g++-8
253         platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
254       CLANG5:
255         CC: clang-5.0
256         CXX: clang++-5.0
257         PackageDeps: clang-5.0
258         Repo: llvm-toolchain-$(lsb_release -cs)-5.0
259         platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
260       CLANG6:
261         CC: clang-6.0
262         CXX: clang++-6.0
263         PackageDeps: clang-6.0
264         Repo: llvm-toolchain-$(lsb_release -cs)-6.0
265         platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
266       CLANG7:
267         CC: clang-7
268         CXX: clang++-7
269         PackageDeps: clang-7
270         Repo: llvm-toolchain-$(lsb_release -cs)-7
271         platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
272       CLANG8:
273         CC: clang-8
274         CXX: clang++-8
275         PackageDeps: clang-8
276         Repo: llvm-toolchain-$(lsb_release -cs)-8
277         platform_file: include $(ACE_ROOT)/include/makeinclude/platform_linux_clang.GNU
278   steps:
279   - script: |
280       wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key|sudo apt-key add -
281       sudo apt-add-repository "deb http://apt.llvm.org/$(lsb_release -cs)/ $(Repo) main"
282     displayName: Add repository ($(Repo))
283     condition: and(succeeded(), ne(variables['Repo'], ''))
284   - script: |
285       sudo add-apt-repository ppa:ubuntu-toolchain-r/test -y
286       sudo apt-get --yes update
287       sudo apt-get --yes install libxerces-c-dev libssl-dev $(PackageDeps)
288     displayName: install system package dependencies
289   - powershell: |
290       '#include "ace/config-linux.h"' > $(ACE_ROOT)/ace/config.h
291     displayName: Create config.h file
292   - powershell: |
293       'xerces3=1' > $(ACE_ROOT)/bin/MakeProjectCreator/config/default.features
294       'ssl=1' >> $(ACE_ROOT)/bin/MakeProjectCreator/config/default.features
295       'versioned_namespace=1' >> $(ACE_ROOT)/bin/MakeProjectCreator/config/default.features
296     displayName: Create default.features file
297   - powershell: |
298       'xerces3=1' > $(ACE_ROOT)/include/makeinclude/platform_macros.GNU
299       'ssl=1' >> $(ACE_ROOT)/include/makeinclude/platform_macros.GNU
300       "$(platform_file)" >> $(ACE_ROOT)/include/makeinclude/platform_macros.GNU
301     displayName: Create platform_macros file
302   - powershell: git clone --depth 1 git://github.com/DOCGroup/MPC.git $(MPC_ROOT)
303     displayName: git clone MPC
304   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type gnuace $(TAO_ROOT)/TAO_ACE.mwc -workers 4
305     displayName: Run mwc.pl on $(TAO_ROOT)/TAO_ACE.mwc
306   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type gnuace $(ACE_ROOT)/tests/tests.mwc -workers 4
307     displayName: Run mwc.pl on $(ACE_ROOT)/tests/tests.mwc
308   - bash: make -j 6 -C TAO
309     displayName: Build TAO project
310   - bash: make -j 6 -C ACE/tests
311     displayName: Build tests project
313 - job: MacOSX
314   timeoutInMinutes: 90
315   pool:
316     vmImage: macOS-10.14
317   steps:
318   - powershell: |
319       '#include "ace/config-macosx.h"' > $(ACE_ROOT)/ace/config.h
320     displayName: Create config.h file
321   - powershell: |
322       'include $(ACE_ROOT)/include/makeinclude/platform_macosx.GNU' > $(ACE_ROOT)/include/makeinclude/platform_macros.GNU;
323     displayName: Create platform_macros file
324   - powershell: git clone --depth 1 git://github.com/DOCGroup/MPC.git $(MPC_ROOT)
325     displayName: git clone MPC
326   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type gnuace $(TAO_ROOT)/TAO_ACE.mwc -workers 4
327     displayName: Run mwc.pl on $(TAO_ROOT)/TAO_ACE.mwc
328   - powershell: perl $(ACE_ROOT)/bin/mwc.pl -type gnuace $(ACE_ROOT)/tests/tests.mwc -workers 4
329     displayName: Run mwc.pl on $(ACE_ROOT)/tests/tests.mwc
330   - bash: make -j 6 -C TAO
331     displayName: Build TAO project
332   - bash: make -j 6 -C ACE/tests
333     displayName: Build tests project