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