gitlab-ci: add meson gallium ST Clover (LLVM 5.0) build
[mesa.git] / .travis.yml
1 language: c
2
3 dist: xenial
4
5 cache:
6 apt: true
7 ccache: true
8
9 env:
10 global:
11 - XORG_RELEASES=https://xorg.freedesktop.org/releases/individual
12 - XCB_RELEASES=https://xcb.freedesktop.org/dist
13 - WAYLAND_RELEASES=https://wayland.freedesktop.org/releases
14 - XORGMACROS_VERSION=util-macros-1.19.0
15 - GLPROTO_VERSION=glproto-1.4.17
16 - DRI2PROTO_VERSION=dri2proto-2.8
17 - LIBPCIACCESS_VERSION=libpciaccess-0.13.4
18 - LIBDRM_VERSION=libdrm-2.4.97
19 - XCBPROTO_VERSION=xcb-proto-1.13
20 - RANDRPROTO_VERSION=randrproto-1.3.0
21 - LIBXRANDR_VERSION=libXrandr-1.3.0
22 - LIBXCB_VERSION=libxcb-1.13
23 - LIBXSHMFENCE_VERSION=libxshmfence-1.2
24 - LIBVDPAU_VERSION=libvdpau-1.1
25 - LIBVA_VERSION=libva-1.7.0
26 - LIBWAYLAND_VERSION=wayland-1.15.0
27 - WAYLAND_PROTOCOLS_VERSION=wayland-protocols-1.8
28 - PKG_CONFIG_PATH=$HOME/prefix/lib/pkgconfig:$HOME/prefix/share/pkgconfig
29 - LD_LIBRARY_PATH="$HOME/prefix/lib:$LD_LIBRARY_PATH"
30 - PATH="$HOME/prefix/bin:$PATH"
31
32 matrix:
33 include:
34 - env:
35 - LABEL="make loaders/classic DRI"
36 - BUILD=make
37 - MAKEFLAGS="-j4"
38 - MAKE_CHECK_COMMAND="make check"
39 - DRI_LOADERS="--enable-glx --enable-gbm --enable-egl --with-platforms=x11,drm,surfaceless,wayland --enable-osmesa"
40 - DRI_DRIVERS="i915,i965,radeon,r200,swrast,nouveau"
41 - GALLIUM_ST="--enable-dri --disable-opencl --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
42 - GALLIUM_DRIVERS=""
43 - VULKAN_DRIVERS=""
44 - LIBUNWIND_FLAGS="--disable-libunwind"
45 addons:
46 apt:
47 packages:
48 - xz-utils
49 - x11proto-xf86vidmode-dev
50 - libxxf86vm-dev
51 - libexpat1-dev
52 - libx11-xcb-dev
53 - libxdamage-dev
54 - libxfixes-dev
55 - python3-pip
56 - python3-setuptools
57 - env:
58 - LABEL="meson Gallium ST Clover LLVM-6.0"
59 - BUILD=meson
60 - UNWIND="true"
61 - DRI_LOADERS="-Dglx=disabled -Degl=false -Dgbm=false"
62 - GALLIUM_ST="-Ddri3=false -Dgallium-vdpau=false -Dgallium-xvmc=false -Dgallium-omx=disabled -Dgallium-va=false -Dgallium-xa=false -Dgallium-nine=false -Dgallium-opencl=icd"
63 - GALLIUM_DRIVERS="r600"
64 - LLVM_VERSION=6.0
65 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
66 addons:
67 apt:
68 packages:
69 - libclc-dev
70 - llvm-6.0-dev
71 - clang-6.0
72 - libclang-6.0-dev
73 # Common
74 - xz-utils
75 - libexpat1-dev
76 - libx11-xcb-dev
77 - libelf-dev
78 - libunwind8-dev
79 - python3.5
80 - python3-pip
81 - python3-setuptools
82 - env:
83 - LABEL="meson Gallium ST Clover LLVM-7"
84 - BUILD=meson
85 - UNWIND="true"
86 - DRI_LOADERS="-Dglx=disabled -Degl=false -Dgbm=false"
87 - GALLIUM_ST="-Ddri3=false -Dgallium-vdpau=false -Dgallium-xvmc=false -Dgallium-omx=disabled -Dgallium-va=false -Dgallium-xa=false -Dgallium-nine=false -Dgallium-opencl=icd"
88 - GALLIUM_DRIVERS="r600,radeonsi"
89 - LLVM_VERSION=7
90 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
91 addons:
92 apt:
93 sources:
94 - sourceline: 'deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main'
95 key_url: https://apt.llvm.org/llvm-snapshot.gpg.key
96 packages:
97 - libclc-dev
98 # From sources above
99 - llvm-7-dev
100 - clang-7
101 - libclang-7-dev
102 # Common
103 - xz-utils
104 - libexpat1-dev
105 - libx11-xcb-dev
106 - libelf-dev
107 - libunwind8-dev
108 - python3.5
109 - python3-pip
110 - python3-setuptools
111 - env:
112 - LABEL="meson Gallium ST Other"
113 - BUILD=meson
114 - UNWIND="true"
115 - DRI_LOADERS="-Dglx=disabled -Degl=false -Dgbm=false"
116 - GALLIUM_ST="-Ddri3=true -Dgallium-vdpau=true -Dgallium-xvmc=true -Dgallium-omx=bellagio -Dgallium-va=true -Dgallium-xa=true -Dgallium-nine=true -Dgallium-opencl=disabled -Dosmesa=gallium"
117 # We need swrast for osmesa and nine.
118 # Nouveau supports, or builds at least against all ST.
119 - GALLIUM_DRIVERS="nouveau,swrast"
120 - LLVM_VERSION=5.0
121 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
122 addons:
123 apt:
124 packages:
125 - llvm-5.0-dev
126 # LLVM packaging is broken and misses these dependencies
127 - libedit-dev
128 # Nine requires gcc 4.6... which is the one we have right ?
129 - libxvmc-dev
130 # Build locally, for now.
131 #- libvdpau-dev
132 #- libva-dev
133 - libomxil-bellagio-dev
134 # Common
135 - xz-utils
136 - libexpat1-dev
137 - libx11-xcb-dev
138 - libelf-dev
139 - libunwind8-dev
140 - python3.5
141 - python3-pip
142 - python3-setuptools
143 - env:
144 # NOTE: Building SWR is 2x (yes two) times slower than all the other
145 # gallium drivers combined.
146 # Start this early so that it doesn't hunder the run time.
147 - LABEL="make Gallium Drivers SWR"
148 - BUILD=make
149 - MAKEFLAGS="-j4"
150 - MAKE_CHECK_COMMAND="true"
151 - LLVM_VERSION=6.0
152 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
153 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
154 - DRI_DRIVERS=""
155 - GALLIUM_ST="--enable-dri --disable-opencl --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
156 - GALLIUM_DRIVERS="swr"
157 - VULKAN_DRIVERS=""
158 - LIBUNWIND_FLAGS="--enable-libunwind"
159 addons:
160 apt:
161 packages:
162 - llvm-6.0-dev
163 # Common
164 - xz-utils
165 - libexpat1-dev
166 - libx11-xcb-dev
167 - libelf-dev
168 - libunwind8-dev
169 - python3-pip
170 - python3-setuptools
171 - env:
172 - LABEL="make Gallium Drivers RadeonSI"
173 - BUILD=make
174 - MAKEFLAGS="-j4"
175 - MAKE_CHECK_COMMAND="true"
176 - LLVM_VERSION=7
177 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
178 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
179 - DRI_DRIVERS=""
180 - GALLIUM_ST="--enable-dri --disable-opencl --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
181 - GALLIUM_DRIVERS="radeonsi"
182 - VULKAN_DRIVERS=""
183 - LIBUNWIND_FLAGS="--enable-libunwind"
184 addons:
185 apt:
186 sources:
187 - sourceline: 'deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main'
188 key_url: https://apt.llvm.org/llvm-snapshot.gpg.key
189 packages:
190 # From sources above
191 - llvm-7-dev
192 # Common
193 - xz-utils
194 - libexpat1-dev
195 - libx11-xcb-dev
196 - libelf-dev
197 - libunwind8-dev
198 - python3-pip
199 - python3-setuptools
200 - env:
201 - LABEL="make Gallium Drivers Other"
202 - BUILD=make
203 - MAKEFLAGS="-j4"
204 - MAKE_CHECK_COMMAND="true"
205 - LLVM_VERSION=3.9
206 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
207 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
208 - DRI_DRIVERS=""
209 - GALLIUM_ST="--enable-dri --disable-opencl --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
210 - GALLIUM_DRIVERS="i915,nouveau,kmsro,r300,r600,freedreno,svga,swrast,v3d,vc4,virgl,etnaviv"
211 - VULKAN_DRIVERS=""
212 - LIBUNWIND_FLAGS="--enable-libunwind"
213 addons:
214 apt:
215 packages:
216 # LLVM packaging is broken and misses these dependencies
217 - libedit-dev
218 - llvm-3.9-dev
219 # Common
220 - xz-utils
221 - libexpat1-dev
222 - libx11-xcb-dev
223 - libelf-dev
224 - libunwind8-dev
225 - python3-pip
226 - python3-setuptools
227 - env:
228 - LABEL="make Gallium ST Clover LLVM-3.9"
229 - BUILD=make
230 - MAKEFLAGS="-j4"
231 - MAKE_CHECK_COMMAND="true"
232 - LLVM_VERSION=3.9
233 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
234 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
235 - DRI_DRIVERS=""
236 - GALLIUM_ST="--disable-dri --enable-opencl --enable-opencl-icd --enable-llvm --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
237 - GALLIUM_DRIVERS="r600"
238 - VULKAN_DRIVERS=""
239 - LIBUNWIND_FLAGS="--enable-libunwind"
240 addons:
241 apt:
242 packages:
243 - libclc-dev
244 # LLVM packaging is broken and misses these dependencies
245 - libedit-dev
246 - llvm-3.9-dev
247 - clang-3.9
248 - libclang-3.9-dev
249 # Common
250 - xz-utils
251 - libexpat1-dev
252 - libx11-xcb-dev
253 - libelf-dev
254 - libunwind8-dev
255 - python3-pip
256 - python3-setuptools
257 - env:
258 - LABEL="make Gallium ST Clover LLVM-4.0"
259 - BUILD=make
260 - MAKEFLAGS="-j4"
261 - MAKE_CHECK_COMMAND="true"
262 - LLVM_VERSION=4.0
263 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
264 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
265 - DRI_DRIVERS=""
266 - GALLIUM_ST="--disable-dri --enable-opencl --enable-opencl-icd --enable-llvm --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
267 - GALLIUM_DRIVERS="r600"
268 - VULKAN_DRIVERS=""
269 - LIBUNWIND_FLAGS="--enable-libunwind"
270 addons:
271 apt:
272 packages:
273 - libclc-dev
274 # LLVM packaging is broken and misses these dependencies
275 - libedit-dev
276 - llvm-4.0-dev
277 - clang-4.0
278 - libclang-4.0-dev
279 # Common
280 - xz-utils
281 - libexpat1-dev
282 - libx11-xcb-dev
283 - libelf-dev
284 - libunwind8-dev
285 - python3-pip
286 - python3-setuptools
287 - env:
288 - LABEL="make Gallium ST Clover LLVM-5.0"
289 - BUILD=make
290 - MAKEFLAGS="-j4"
291 - MAKE_CHECK_COMMAND="true"
292 - LLVM_VERSION=5.0
293 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
294 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
295 - DRI_DRIVERS=""
296 - GALLIUM_ST="--disable-dri --enable-opencl --enable-opencl-icd --enable-llvm --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
297 - GALLIUM_DRIVERS="r600"
298 - VULKAN_DRIVERS=""
299 - LIBUNWIND_FLAGS="--enable-libunwind"
300 addons:
301 apt:
302 packages:
303 - libclc-dev
304 # LLVM packaging is broken and misses these dependencies
305 - libedit-dev
306 - llvm-5.0-dev
307 - clang-5.0
308 - libclang-5.0-dev
309 # Common
310 - xz-utils
311 - libexpat1-dev
312 - libx11-xcb-dev
313 - libelf-dev
314 - libunwind8-dev
315 - python3-pip
316 - python3-setuptools
317 - env:
318 - LABEL="make Gallium ST Clover LLVM-6.0"
319 - BUILD=make
320 - MAKEFLAGS="-j4"
321 - MAKE_CHECK_COMMAND="true"
322 - LLVM_VERSION=6.0
323 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
324 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
325 - DRI_DRIVERS=""
326 - GALLIUM_ST="--disable-dri --enable-opencl --enable-opencl-icd --enable-llvm --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
327 - GALLIUM_DRIVERS="r600"
328 - VULKAN_DRIVERS=""
329 - LIBUNWIND_FLAGS="--enable-libunwind"
330 addons:
331 apt:
332 packages:
333 - libclc-dev
334 - llvm-6.0-dev
335 - clang-6.0
336 - libclang-6.0-dev
337 # Common
338 - xz-utils
339 - libexpat1-dev
340 - libx11-xcb-dev
341 - libelf-dev
342 - libunwind8-dev
343 - python3-pip
344 - python3-setuptools
345 - env:
346 - LABEL="make Gallium ST Clover LLVM-7"
347 - BUILD=make
348 - MAKEFLAGS="-j4"
349 - MAKE_CHECK_COMMAND="true"
350 - LLVM_VERSION=7
351 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
352 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
353 - DRI_DRIVERS=""
354 - GALLIUM_ST="--disable-dri --enable-opencl --enable-opencl-icd --enable-llvm --disable-xa --disable-nine --disable-xvmc --disable-vdpau --disable-va --disable-omx-bellagio --disable-gallium-osmesa"
355 - GALLIUM_DRIVERS="r600,radeonsi"
356 - VULKAN_DRIVERS=""
357 - LIBUNWIND_FLAGS="--enable-libunwind"
358 addons:
359 apt:
360 sources:
361 - sourceline: 'deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main'
362 key_url: https://apt.llvm.org/llvm-snapshot.gpg.key
363 packages:
364 - libclc-dev
365 # From sources above
366 - llvm-7-dev
367 - clang-7
368 - libclang-7-dev
369 # Common
370 - xz-utils
371 - libexpat1-dev
372 - libx11-xcb-dev
373 - libelf-dev
374 - libunwind8-dev
375 - env:
376 - LABEL="make Gallium ST Other"
377 - BUILD=make
378 - MAKEFLAGS="-j4"
379 - MAKE_CHECK_COMMAND="true"
380 - LLVM_VERSION=3.5
381 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
382 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
383 - DRI_DRIVERS=""
384 - GALLIUM_ST="--enable-dri --disable-opencl --enable-xa --enable-nine --enable-xvmc --enable-vdpau --enable-va --enable-omx-bellagio --enable-gallium-osmesa"
385 # We need swrast for osmesa and nine.
386 # i915 most likely doesn't work with most ST.
387 # Regardless - we're doing a quick build test here.
388 - GALLIUM_DRIVERS="i915,swrast"
389 - VULKAN_DRIVERS=""
390 - LIBUNWIND_FLAGS="--enable-libunwind"
391 addons:
392 apt:
393 packages:
394 # We actually want to test against llvm-3.3, yet 3.5 is available
395 - llvm-3.5-dev
396 # Nine requires gcc 4.6... which is the one we have right ?
397 - libxvmc-dev
398 # Build locally, for now.
399 #- libvdpau-dev
400 #- libva-dev
401 - libomxil-bellagio-dev
402 # LLVM packaging is broken and misses these dependencies
403 - libedit-dev
404 # Common
405 - xz-utils
406 - libexpat1-dev
407 - libx11-xcb-dev
408 - libelf-dev
409 - libunwind8-dev
410 - python3-pip
411 - python3-setuptools
412 - env:
413 - LABEL="macOS make"
414 - BUILD=make
415 - MAKEFLAGS="-j4"
416 - MAKE_CHECK_COMMAND="make check"
417 - DRI_LOADERS="--with-platforms=x11 --disable-egl"
418 os: osx
419 - env:
420 - LABEL="macOS meson"
421 - BUILD=meson
422 - UNWIND="false"
423 - DRI_LOADERS="-Dglx=dri -Dgbm=false -Degl=false -Dplatforms=x11 -Dosmesa=none"
424 - GALLIUM_ST="-Ddri3=true -Dgallium-vdpau=false -Dgallium-xvmc=false -Dgallium-omx=disabled -Dgallium-va=false -Dgallium-xa=false -Dgallium-nine=false -Dgallium-opencl=disabled"
425 os: osx
426
427 before_install:
428 - |
429 if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
430 HOMEBREW_NO_AUTO_UPDATE=1 brew install python3 ninja expat gettext
431 # Set PATH for homebrew pip3 installs
432 PATH="$HOME/Library/Python/3.6/bin:${PATH}"
433 # Set PKG_CONFIG_PATH for keg-only expat
434 PKG_CONFIG_PATH="/usr/local/opt/expat/lib/pkgconfig:${PKG_CONFIG_PATH}"
435 # Set PATH for keg-only gettext
436 PATH="/usr/local/opt/gettext/bin:${PATH}"
437
438 # Install xquartz for prereqs ...
439 XQUARTZ_VERSION="2.7.11"
440 wget -nv https://dl.bintray.com/xquartz/downloads/XQuartz-${XQUARTZ_VERSION}.dmg
441 hdiutil attach XQuartz-${XQUARTZ_VERSION}.dmg
442 sudo installer -pkg /Volumes/XQuartz-${XQUARTZ_VERSION}/XQuartz.pkg -target /
443 hdiutil detach /Volumes/XQuartz-${XQUARTZ_VERSION}
444 # ... and set paths
445 PATH="/opt/X11/bin:${PATH}"
446 PKG_CONFIG_PATH="/opt/X11/share/pkgconfig:/opt/X11/lib/pkgconfig:${PKG_CONFIG_PATH}"
447 ACLOCAL="aclocal -I /opt/X11/share/aclocal -I /usr/local/share/aclocal"
448 fi
449
450 install:
451 # Install a more modern meson from pip, since the version in the
452 # ubuntu repos is often quite old.
453 - if test "x$BUILD" = xmeson; then
454 pip3 install --user meson;
455 pip3 install --user mako;
456 fi
457
458 # Install autotools build dependencies
459 - if test "x$BUILD" = xmake; then
460 pip2 install --user mako;
461 fi
462
463 # Install a more modern scons from pip.
464 - if test "x$BUILD" = xscons; then
465 pip2 install --user "scons>=2.4";
466 pip2 install --user mako;
467 fi
468
469 # Install dependencies where we require specific versions (or where
470 # disallowed by Travis CI's package whitelisting).
471
472 - |
473 if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then
474 wget $XORG_RELEASES/util/$XORGMACROS_VERSION.tar.bz2
475 tar -jxvf $XORGMACROS_VERSION.tar.bz2
476 (cd $XORGMACROS_VERSION && ./configure --prefix=$HOME/prefix && make install)
477
478 wget $XORG_RELEASES/proto/$GLPROTO_VERSION.tar.bz2
479 tar -jxvf $GLPROTO_VERSION.tar.bz2
480 (cd $GLPROTO_VERSION && ./configure --prefix=$HOME/prefix && make install)
481
482 wget $XORG_RELEASES/proto/$DRI2PROTO_VERSION.tar.bz2
483 tar -jxvf $DRI2PROTO_VERSION.tar.bz2
484 (cd $DRI2PROTO_VERSION && ./configure --prefix=$HOME/prefix && make install)
485
486 wget $XCB_RELEASES/$XCBPROTO_VERSION.tar.bz2
487 tar -jxvf $XCBPROTO_VERSION.tar.bz2
488 (cd $XCBPROTO_VERSION && ./configure --prefix=$HOME/prefix && make install)
489
490 wget $XCB_RELEASES/$LIBXCB_VERSION.tar.bz2
491 tar -jxvf $LIBXCB_VERSION.tar.bz2
492 (cd $LIBXCB_VERSION && ./configure --prefix=$HOME/prefix && make install)
493
494 wget $XORG_RELEASES/lib/$LIBPCIACCESS_VERSION.tar.bz2
495 tar -jxvf $LIBPCIACCESS_VERSION.tar.bz2
496 (cd $LIBPCIACCESS_VERSION && ./configure --prefix=$HOME/prefix && make install)
497
498 wget https://dri.freedesktop.org/libdrm/$LIBDRM_VERSION.tar.bz2
499 tar -jxvf $LIBDRM_VERSION.tar.bz2
500 (cd $LIBDRM_VERSION && ./configure --prefix=$HOME/prefix --enable-vc4 --enable-freedreno --enable-etnaviv-experimental-api && make install)
501
502 wget $XORG_RELEASES/proto/$RANDRPROTO_VERSION.tar.bz2
503 tar -jxvf $RANDRPROTO_VERSION.tar.bz2
504 (cd $RANDRPROTO_VERSION && ./configure --prefix=$HOME/prefix && make install)
505
506 wget $XORG_RELEASES/lib/$LIBXRANDR_VERSION.tar.bz2
507 tar -jxvf $LIBXRANDR_VERSION.tar.bz2
508 (cd $LIBXRANDR_VERSION && ./configure --prefix=$HOME/prefix && make install)
509
510 wget $XORG_RELEASES/lib/$LIBXSHMFENCE_VERSION.tar.bz2
511 tar -jxvf $LIBXSHMFENCE_VERSION.tar.bz2
512 (cd $LIBXSHMFENCE_VERSION && ./configure --prefix=$HOME/prefix && make install)
513
514 wget https://people.freedesktop.org/~aplattner/vdpau/$LIBVDPAU_VERSION.tar.bz2
515 tar -jxvf $LIBVDPAU_VERSION.tar.bz2
516 (cd $LIBVDPAU_VERSION && ./configure --prefix=$HOME/prefix && make install)
517
518 wget https://www.freedesktop.org/software/vaapi/releases/libva/$LIBVA_VERSION.tar.bz2
519 tar -jxvf $LIBVA_VERSION.tar.bz2
520 (cd $LIBVA_VERSION && ./configure --prefix=$HOME/prefix --disable-wayland --disable-dummy-driver && make install)
521
522 wget $WAYLAND_RELEASES/$LIBWAYLAND_VERSION.tar.xz
523 tar -axvf $LIBWAYLAND_VERSION.tar.xz
524 (cd $LIBWAYLAND_VERSION && ./configure --prefix=$HOME/prefix --enable-libraries --without-host-scanner --disable-documentation --disable-dtd-validation && make install)
525
526 wget $WAYLAND_RELEASES/$WAYLAND_PROTOCOLS_VERSION.tar.xz
527 tar -axvf $WAYLAND_PROTOCOLS_VERSION.tar.xz
528 (cd $WAYLAND_PROTOCOLS_VERSION && ./configure --prefix=$HOME/prefix && make install)
529
530 # Meson requires ninja >= 1.6, but xenial has 1.3.x
531 wget https://github.com/ninja-build/ninja/releases/download/v1.6.0/ninja-linux.zip
532 unzip ninja-linux.zip
533 mv ninja $HOME/prefix/bin/
534
535 # Generate this header since one is missing on the Travis instance
536 mkdir -p linux
537 printf "%s\n" \
538 "#ifndef _LINUX_MEMFD_H" \
539 "#define _LINUX_MEMFD_H" \
540 "" \
541 "#define MFD_CLOEXEC 0x0001U" \
542 "#define MFD_ALLOW_SEALING 0x0002U" \
543 "" \
544 "#endif /* _LINUX_MEMFD_H */" > linux/memfd.h
545
546 # Generate this header, including the missing SYS_memfd_create
547 # macro, which is not provided by the header in the Travis
548 # instance
549 mkdir -p sys
550 printf "%s\n" \
551 "#ifndef _SYSCALL_H" \
552 "#define _SYSCALL_H 1" \
553 "" \
554 "#include <asm/unistd.h>" \
555 "" \
556 "#ifndef _LIBC" \
557 "# include <bits/syscall.h>" \
558 "#endif" \
559 "" \
560 "#ifndef __NR_memfd_create" \
561 "# define __NR_memfd_create 319 /* Taken from <asm/unistd_64.h> */" \
562 "#endif" \
563 "" \
564 "#ifndef SYS_memfd_create" \
565 "# define SYS_memfd_create __NR_memfd_create" \
566 "#endif" \
567 "" \
568 "#endif" > sys/syscall.h
569 fi
570
571 script:
572 - if test "x$BUILD" = xmake; then
573 export CFLAGS="$CFLAGS -isystem`pwd`";
574
575 mkdir build &&
576 cd build &&
577 ../autogen.sh
578 --enable-autotools
579 --enable-debug
580 $LIBUNWIND_FLAGS
581 $DRI_LOADERS
582 --with-dri-drivers=$DRI_DRIVERS
583 $GALLIUM_ST
584 --with-gallium-drivers=$GALLIUM_DRIVERS
585 --with-vulkan-drivers=$VULKAN_DRIVERS
586 --disable-llvm-shared-libs
587 &&
588 make && eval $MAKE_CHECK_COMMAND;
589 fi
590
591 - if test "x$BUILD" = xscons; then
592 scons $SCONS_TARGET && eval $SCONS_CHECK_COMMAND;
593 fi
594
595 - |
596 if test "x$BUILD" = xmeson; then
597 if test -n "$LLVM_CONFIG"; then
598 # We need to control the version of llvm-config we're using, so we'll
599 # generate a native file to do so. This requires meson >=0.49
600 #
601 echo -e "[binaries]\nllvm-config = '`which $LLVM_CONFIG`'" > native.file
602
603 $LLVM_CONFIG --version
604 else
605 : > native.file
606 fi
607
608 export CFLAGS="$CFLAGS -isystem`pwd`"
609 meson _build \
610 --native-file=native.file \
611 -Dbuild-tests=true \
612 -Dlibunwind=${UNWIND} \
613 ${DRI_LOADERS} \
614 -Ddri-drivers=${DRI_DRIVERS:-[]} \
615 ${GALLIUM_ST} \
616 -Dgallium-drivers=${GALLIUM_DRIVERS:-[]} \
617 -Dvulkan-drivers=${VULKAN_DRIVERS:-[]}
618 meson configure _build
619 ninja -C _build
620 ninja -C _build test
621 fi