From: Jon Turney Date: Thu, 1 Feb 2018 15:19:08 +0000 (+0000) Subject: travis: conditionalize building of prerequisites on if OS=linux X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7d1ec6d6a92f15a24377738f12e59d80bab96da3;p=mesa.git travis: conditionalize building of prerequisites on if OS=linux Use a '|' YAML literal block to avoid the convoluted syntax needed to put the entire conditional on a single line. Signed-off-by: Jon Turney Reviewed-by: Emil Velikov --- diff --git a/.travis.yml b/.travis.yml index 211df3ec1ef..4297de9dd62 100644 --- a/.travis.yml +++ b/.travis.yml @@ -419,62 +419,64 @@ install: # Install dependencies where we require specific versions (or where # disallowed by Travis CI's package whitelisting). - - wget $XORG_RELEASES/util/$XORGMACROS_VERSION.tar.bz2 - - tar -jxvf $XORGMACROS_VERSION.tar.bz2 - - (cd $XORGMACROS_VERSION && ./configure --prefix=$HOME/prefix && make install) + - | + if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then + wget $XORG_RELEASES/util/$XORGMACROS_VERSION.tar.bz2 + tar -jxvf $XORGMACROS_VERSION.tar.bz2 + (cd $XORGMACROS_VERSION && ./configure --prefix=$HOME/prefix && make install) - - wget $XORG_RELEASES/proto/$GLPROTO_VERSION.tar.bz2 - - tar -jxvf $GLPROTO_VERSION.tar.bz2 - - (cd $GLPROTO_VERSION && ./configure --prefix=$HOME/prefix && make install) + wget $XORG_RELEASES/proto/$GLPROTO_VERSION.tar.bz2 + tar -jxvf $GLPROTO_VERSION.tar.bz2 + (cd $GLPROTO_VERSION && ./configure --prefix=$HOME/prefix && make install) - - wget $XORG_RELEASES/proto/$DRI2PROTO_VERSION.tar.bz2 - - tar -jxvf $DRI2PROTO_VERSION.tar.bz2 - - (cd $DRI2PROTO_VERSION && ./configure --prefix=$HOME/prefix && make install) + wget $XORG_RELEASES/proto/$DRI2PROTO_VERSION.tar.bz2 + tar -jxvf $DRI2PROTO_VERSION.tar.bz2 + (cd $DRI2PROTO_VERSION && ./configure --prefix=$HOME/prefix && make install) - - wget $XCB_RELEASES/$XCBPROTO_VERSION.tar.bz2 - - tar -jxvf $XCBPROTO_VERSION.tar.bz2 - - (cd $XCBPROTO_VERSION && ./configure --prefix=$HOME/prefix && make install) + wget $XCB_RELEASES/$XCBPROTO_VERSION.tar.bz2 + tar -jxvf $XCBPROTO_VERSION.tar.bz2 + (cd $XCBPROTO_VERSION && ./configure --prefix=$HOME/prefix && make install) - - wget $XCB_RELEASES/$LIBXCB_VERSION.tar.bz2 - - tar -jxvf $LIBXCB_VERSION.tar.bz2 - - (cd $LIBXCB_VERSION && ./configure --prefix=$HOME/prefix && make install) + wget $XCB_RELEASES/$LIBXCB_VERSION.tar.bz2 + tar -jxvf $LIBXCB_VERSION.tar.bz2 + (cd $LIBXCB_VERSION && ./configure --prefix=$HOME/prefix && make install) - - wget $XORG_RELEASES/lib/$LIBPCIACCESS_VERSION.tar.bz2 - - tar -jxvf $LIBPCIACCESS_VERSION.tar.bz2 - - (cd $LIBPCIACCESS_VERSION && ./configure --prefix=$HOME/prefix && make install) + wget $XORG_RELEASES/lib/$LIBPCIACCESS_VERSION.tar.bz2 + tar -jxvf $LIBPCIACCESS_VERSION.tar.bz2 + (cd $LIBPCIACCESS_VERSION && ./configure --prefix=$HOME/prefix && make install) - - wget http://dri.freedesktop.org/libdrm/$LIBDRM_VERSION.tar.bz2 - - tar -jxvf $LIBDRM_VERSION.tar.bz2 - - (cd $LIBDRM_VERSION && ./configure --prefix=$HOME/prefix --enable-vc4 --enable-freedreno --enable-etnaviv-experimental-api && make install) + wget http://dri.freedesktop.org/libdrm/$LIBDRM_VERSION.tar.bz2 + tar -jxvf $LIBDRM_VERSION.tar.bz2 + (cd $LIBDRM_VERSION && ./configure --prefix=$HOME/prefix --enable-vc4 --enable-freedreno --enable-etnaviv-experimental-api && make install) - - wget $XORG_RELEASES/lib/$LIBXSHMFENCE_VERSION.tar.bz2 - - tar -jxvf $LIBXSHMFENCE_VERSION.tar.bz2 - - (cd $LIBXSHMFENCE_VERSION && ./configure --prefix=$HOME/prefix && make install) + wget $XORG_RELEASES/lib/$LIBXSHMFENCE_VERSION.tar.bz2 + tar -jxvf $LIBXSHMFENCE_VERSION.tar.bz2 + (cd $LIBXSHMFENCE_VERSION && ./configure --prefix=$HOME/prefix && make install) - - wget http://people.freedesktop.org/~aplattner/vdpau/$LIBVDPAU_VERSION.tar.bz2 - - tar -jxvf $LIBVDPAU_VERSION.tar.bz2 - - (cd $LIBVDPAU_VERSION && ./configure --prefix=$HOME/prefix && make install) + wget http://people.freedesktop.org/~aplattner/vdpau/$LIBVDPAU_VERSION.tar.bz2 + tar -jxvf $LIBVDPAU_VERSION.tar.bz2 + (cd $LIBVDPAU_VERSION && ./configure --prefix=$HOME/prefix && make install) - - wget http://www.freedesktop.org/software/vaapi/releases/libva/$LIBVA_VERSION.tar.bz2 - - tar -jxvf $LIBVA_VERSION.tar.bz2 - - (cd $LIBVA_VERSION && ./configure --prefix=$HOME/prefix --disable-wayland --disable-dummy-driver && make install) + wget http://www.freedesktop.org/software/vaapi/releases/libva/$LIBVA_VERSION.tar.bz2 + tar -jxvf $LIBVA_VERSION.tar.bz2 + (cd $LIBVA_VERSION && ./configure --prefix=$HOME/prefix --disable-wayland --disable-dummy-driver && make install) - - wget $WAYLAND_RELEASES/$LIBWAYLAND_VERSION.tar.xz - - tar -axvf $LIBWAYLAND_VERSION.tar.xz - - (cd $LIBWAYLAND_VERSION && ./configure --prefix=$HOME/prefix --enable-libraries --without-host-scanner --disable-documentation --disable-dtd-validation && make install) + wget $WAYLAND_RELEASES/$LIBWAYLAND_VERSION.tar.xz + tar -axvf $LIBWAYLAND_VERSION.tar.xz + (cd $LIBWAYLAND_VERSION && ./configure --prefix=$HOME/prefix --enable-libraries --without-host-scanner --disable-documentation --disable-dtd-validation && make install) - - wget $WAYLAND_RELEASES/$WAYLAND_PROTOCOLS_VERSION.tar.xz - - tar -axvf $WAYLAND_PROTOCOLS_VERSION.tar.xz - - (cd $WAYLAND_PROTOCOLS_VERSION && ./configure --prefix=$HOME/prefix && make install) + wget $WAYLAND_RELEASES/$WAYLAND_PROTOCOLS_VERSION.tar.xz + tar -axvf $WAYLAND_PROTOCOLS_VERSION.tar.xz + (cd $WAYLAND_PROTOCOLS_VERSION && ./configure --prefix=$HOME/prefix && make install) - # Meson requires ninja >= 1.6, but trusty has 1.3.x - - wget https://github.com/ninja-build/ninja/releases/download/v1.6.0/ninja-linux.zip; - - unzip ninja-linux.zip - - mv ninja $HOME/prefix/bin/ + # Meson requires ninja >= 1.6, but trusty has 1.3.x + wget https://github.com/ninja-build/ninja/releases/download/v1.6.0/ninja-linux.zip + unzip ninja-linux.zip + mv ninja $HOME/prefix/bin/ - # Generate the header since one is missing on the Travis instance - - mkdir -p linux - - printf "%s\n" \ + # Generate this header since one is missing on the Travis instance + mkdir -p linux + printf "%s\n" \ "#ifndef _LINUX_MEMFD_H" \ "#define _LINUX_MEMFD_H" \ "" \ @@ -485,6 +487,7 @@ install: "#define MFD_ALLOW_SEALING 0x0002U" \ "" \ "#endif /* _LINUX_MEMFD_H */" > linux/memfd.h + fi script: - if test "x$BUILD" = xmake; then