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