ci: Mark the rest of compswap as flaky on freedreno.
[mesa.git] / .travis.yml
index dd0502950fcb002b2cfad5d5873a564aea801e58..ab8e67e74bdbbd4ab0c740ec6851a69ea068fb9d 100644 (file)
 language: c
 
-dist: xenial
+os: osx
 
 cache:
   ccache: true
 
 env:
   global:
-    - PKG_CONFIG_PATH="$PKG_CONFIG_PATH"
+    - PKG_CONFIG_PATH=""
 
 matrix:
   include:
     - env:
-        - LABEL="macOS make"
-        - BUILD=make
-        - MAKEFLAGS="-j4"
-        - MAKE_CHECK_COMMAND="make check"
-        - DRI_LOADERS="--with-platforms=x11 --disable-egl"
-      os: osx
+      - BUILD=meson
     - env:
-        - LABEL="macOS meson"
-        - BUILD=meson
-        - UNWIND="false"
-        - DRI_LOADERS="-Dplatforms=x11"
-      os: osx
+      - BUILD=scons
 
 before_install:
-  - |
-    if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
-      HOMEBREW_NO_AUTO_UPDATE=1 brew install python3 ninja expat gettext
-      # Set PATH for homebrew pip3 installs
-      PATH="$HOME/Library/Python/3.6/bin:${PATH}"
-      # Set PKG_CONFIG_PATH for keg-only expat
-      PKG_CONFIG_PATH="/usr/local/opt/expat/lib/pkgconfig:${PKG_CONFIG_PATH}"
-      # Set PATH for keg-only gettext
-      PATH="/usr/local/opt/gettext/bin:${PATH}"
-
-      # Install xquartz for prereqs ...
-      XQUARTZ_VERSION="2.7.11"
-      wget -nv https://dl.bintray.com/xquartz/downloads/XQuartz-${XQUARTZ_VERSION}.dmg
-      hdiutil attach XQuartz-${XQUARTZ_VERSION}.dmg
-      sudo installer -pkg /Volumes/XQuartz-${XQUARTZ_VERSION}/XQuartz.pkg -target /
-      hdiutil detach /Volumes/XQuartz-${XQUARTZ_VERSION}
-      # ... and set paths
-      PATH="/opt/X11/bin:${PATH}"
-      PKG_CONFIG_PATH="/opt/X11/share/pkgconfig:/opt/X11/lib/pkgconfig:${PKG_CONFIG_PATH}"
-      ACLOCAL="aclocal -I /opt/X11/share/aclocal -I /usr/local/share/aclocal"
+  - HOMEBREW_NO_AUTO_UPDATE=1 brew install expat gettext
+  - if test "x$BUILD" = xmeson; then
+      HOMEBREW_NO_AUTO_UPDATE=1 brew install ninja;
+    fi
+  - if test "x$BUILD" = xscons; then
+      HOMEBREW_NO_AUTO_UPDATE=1 brew install scons;
     fi
 
+  # Set PATH for homebrew pip3 installs
+  - PYTHON_VERSION=$(python3 -V | awk '{print $2}' | cut -d. -f1-2)
+  - PATH="$HOME/Library/Python/$PYTHON_VERSION/bin:${PATH}"
+  # Set PKG_CONFIG_PATH for keg-only expat
+  - PKG_CONFIG_PATH="/usr/local/opt/expat/lib/pkgconfig:${PKG_CONFIG_PATH}"
+  # Set PATH for keg-only gettext
+  - PATH="/usr/local/opt/gettext/bin:${PATH}"
+
+  # Install xquartz for prereqs ...
+  - XQUARTZ_VERSION="2.7.11"
+  - wget -nv https://dl.bintray.com/xquartz/downloads/XQuartz-${XQUARTZ_VERSION}.dmg
+  - hdiutil attach XQuartz-${XQUARTZ_VERSION}.dmg
+  - sudo installer -pkg /Volumes/XQuartz-${XQUARTZ_VERSION}/XQuartz.pkg -target /
+  - hdiutil detach /Volumes/XQuartz-${XQUARTZ_VERSION}
+  # ... and set paths
+  - PKG_CONFIG_PATH="/opt/X11/share/pkgconfig:/opt/X11/lib/pkgconfig:${PKG_CONFIG_PATH}"
+
 install:
-  # Install a more modern meson from pip, since the version in the
-  # ubuntu repos is often quite old.
   - if test "x$BUILD" = xmeson; then
       pip3 install --user meson;
       pip3 install --user mako;
     fi
-
-  # Install autotools build dependencies
-  - if test "x$BUILD" = xmake; then
+  - if test "x$BUILD" = xscons; then
       pip2 install --user mako;
     fi
 
-  # Install dependencies where we require specific versions (or where
-  # disallowed by Travis CI's package whitelisting).
-
 script:
-  - if test "x$BUILD" = xmake; then
-      export CFLAGS="$CFLAGS -isystem`pwd`";
-
-      mkdir build &&
-      cd build &&
-      ../autogen.sh
-        --enable-autotools
-        --enable-debug
-        $LIBUNWIND_FLAGS
-        $DRI_LOADERS
-        --with-dri-drivers=$DRI_DRIVERS
-        $GALLIUM_ST
-        --with-gallium-drivers=$GALLIUM_DRIVERS
-        --with-vulkan-drivers=$VULKAN_DRIVERS
-        --disable-llvm-shared-libs
-        &&
-      make && eval $MAKE_CHECK_COMMAND;
+  - if test "x$BUILD" = xmeson; then
+      meson _build -Dbuild-tests=true;
+      ninja -C _build || travis_terminate 1;
+      ninja -C _build test || travis_terminate 1;
+      ninja -C _build install || travis_terminate 1;
     fi
-
-  - |
-    if test "x$BUILD" = xmeson; then
-      if test -n "$LLVM_CONFIG"; then
-        # We need to control the version of llvm-config we're using, so we'll
-        # generate a native file to do so. This requires meson >=0.49
-        #
-        echo -e "[binaries]\nllvm-config = '`which $LLVM_CONFIG`'" > native.file
-
-        $LLVM_CONFIG --version
-      else
-        : > native.file
-      fi
-
-      export CFLAGS="$CFLAGS -isystem`pwd`"
-      meson _build \
-                   --native-file=native.file \
-                   -Dbuild-tests=true \
-                   -Dlibunwind=${UNWIND} \
-                   ${DRI_LOADERS} \
-                   -Ddri-drivers=${DRI_DRIVERS:-[]} \
-                   ${GALLIUM_ST} \
-                   -Dgallium-drivers=${GALLIUM_DRIVERS:-[]} \
-                   -Dvulkan-drivers=${VULKAN_DRIVERS:-[]}
-      meson configure _build
-      ninja -C _build
-      ninja -C _build test
+  - if test "x$BUILD" = xscons; then
+      scons force_scons=1 || travis_terminate 1;
+      scons force_scons=1 check || travis_terminate 1;
     fi