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"
35 - LABEL="make loaders/classic DRI"
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"
44 - LIBUNWIND_FLAGS="--disable-libunwind"
49 - x11proto-xf86vidmode-dev
58 - LABEL="meson Gallium ST Clover LLVM-6.0"
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"
65 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
83 - LABEL="meson Gallium ST Clover LLVM-7"
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"
90 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
94 - sourceline: 'deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main'
95 key_url: https://apt.llvm.org/llvm-snapshot.gpg.key
112 - LABEL="meson Gallium ST Other"
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"
121 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
126 # LLVM packaging is broken and misses these dependencies
128 # Nine requires gcc 4.6... which is the one we have right ?
130 # Build locally, for now.
133 - libomxil-bellagio-dev
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"
150 - MAKE_CHECK_COMMAND="true"
152 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
153 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
158 - LIBUNWIND_FLAGS="--enable-libunwind"
172 - LABEL="make Gallium Drivers RadeonSI"
175 - MAKE_CHECK_COMMAND="true"
177 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
178 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
183 - LIBUNWIND_FLAGS="--enable-libunwind"
187 - sourceline: 'deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main'
188 key_url: https://apt.llvm.org/llvm-snapshot.gpg.key
201 - LABEL="make Gallium Drivers Other"
204 - MAKE_CHECK_COMMAND="true"
206 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
207 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
212 - LIBUNWIND_FLAGS="--enable-libunwind"
216 # LLVM packaging is broken and misses these dependencies
228 - LABEL="make Gallium ST Clover LLVM-3.9"
231 - MAKE_CHECK_COMMAND="true"
233 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
234 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
239 - LIBUNWIND_FLAGS="--enable-libunwind"
244 # LLVM packaging is broken and misses these dependencies
258 - LABEL="make Gallium ST Clover LLVM-4.0"
261 - MAKE_CHECK_COMMAND="true"
263 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
264 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
269 - LIBUNWIND_FLAGS="--enable-libunwind"
274 # LLVM packaging is broken and misses these dependencies
288 - LABEL="make Gallium ST Clover LLVM-5.0"
291 - MAKE_CHECK_COMMAND="true"
293 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
294 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
299 - LIBUNWIND_FLAGS="--enable-libunwind"
304 # LLVM packaging is broken and misses these dependencies
318 - LABEL="make Gallium ST Clover LLVM-6.0"
321 - MAKE_CHECK_COMMAND="true"
323 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
324 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
329 - LIBUNWIND_FLAGS="--enable-libunwind"
346 - LABEL="make Gallium ST Clover LLVM-7"
349 - MAKE_CHECK_COMMAND="true"
351 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
352 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
357 - LIBUNWIND_FLAGS="--enable-libunwind"
361 - sourceline: 'deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main'
362 key_url: https://apt.llvm.org/llvm-snapshot.gpg.key
376 - LABEL="make Gallium ST Other"
379 - MAKE_CHECK_COMMAND="true"
381 - LLVM_CONFIG="llvm-config-${LLVM_VERSION}"
382 - DRI_LOADERS="--disable-glx --disable-gbm --disable-egl"
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"
390 - LIBUNWIND_FLAGS="--enable-libunwind"
394 # We actually want to test against llvm-3.3, yet 3.5 is available
396 # Nine requires gcc 4.6... which is the one we have right ?
398 # Build locally, for now.
401 - libomxil-bellagio-dev
402 # LLVM packaging is broken and misses these dependencies
416 - MAKE_CHECK_COMMAND="make check"
417 - DRI_LOADERS="--with-platforms=x11 --disable-egl"
420 - LABEL="macOS meson"
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"
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}"
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}
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"
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;
458 # Install autotools build dependencies
459 - if test "x$BUILD" = xmake; then
460 pip2 install --user mako;
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;
469 # Install dependencies where we require specific versions (or where
470 # disallowed by Travis CI's package whitelisting).
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)
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)
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)
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)
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)
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)
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)
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)
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)
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)
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)
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)
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)
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)
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/
535 # Generate this header since one is missing on the Travis instance
538 "#ifndef _LINUX_MEMFD_H" \
539 "#define _LINUX_MEMFD_H" \
541 "#define MFD_CLOEXEC 0x0001U" \
542 "#define MFD_ALLOW_SEALING 0x0002U" \
544 "#endif /* _LINUX_MEMFD_H */" > linux/memfd.h
546 # Generate this header, including the missing SYS_memfd_create
547 # macro, which is not provided by the header in the Travis
551 "#ifndef _SYSCALL_H" \
552 "#define _SYSCALL_H 1" \
554 "#include <asm/unistd.h>" \
557 "# include <bits/syscall.h>" \
560 "#ifndef __NR_memfd_create" \
561 "# define __NR_memfd_create 319 /* Taken from <asm/unistd_64.h> */" \
564 "#ifndef SYS_memfd_create" \
565 "# define SYS_memfd_create __NR_memfd_create" \
568 "#endif" > sys/syscall.h
572 - if test "x$BUILD" = xmake; then
573 export CFLAGS="$CFLAGS -isystem`pwd`";
582 --with-dri-drivers=$DRI_DRIVERS
584 --with-gallium-drivers=$GALLIUM_DRIVERS
585 --with-vulkan-drivers=$VULKAN_DRIVERS
586 --disable-llvm-shared-libs
588 make && eval $MAKE_CHECK_COMMAND;
591 - if test "x$BUILD" = xscons; then
592 scons $SCONS_TARGET && eval $SCONS_CHECK_COMMAND;
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
601 echo -e "[binaries]\nllvm-config = '`which $LLVM_CONFIG`'" > native.file
603 $LLVM_CONFIG --version
608 export CFLAGS="$CFLAGS -isystem`pwd`"
610 --native-file=native.file \
612 -Dlibunwind=${UNWIND} \
614 -Ddri-drivers=${DRI_DRIVERS:-[]} \
616 -Dgallium-drivers=${GALLIUM_DRIVERS:-[]} \
617 -Dvulkan-drivers=${VULKAN_DRIVERS:-[]}
618 meson configure _build