[ci] disable samplerate when cross building on osx
[aubio.git] / .travis.yml
index 73aef64..788e206 100644 (file)
@@ -2,24 +2,25 @@ language: python
 
 matrix:
   include:
-    - python: 3.5
+    - python: 3.6
       os: linux
       compiler: gcc
-    - python: 3.4
+    - python: 3.5
       os: linux
       compiler: gcc
+      env: WAFOPTS="--build-type=debug"
     - python: 2.7
       os: linux
       compiler: gcc
-    - language: C
-      os: osx
-      osx_image: xcode8
-      compiler: clang
-    - python: 3.5
+    - python: "pypy3.5"
       os: linux
       compiler: gcc
-      env: CFLAGS="-Os" WAFOPTS="--disable-samplerate --disable-sndfile"
-    - python: 3.4
+      env: CFLAGS="-Os" WAFOPTS="--disable-avcodec"
+    - python: 3.6
+      os: linux
+      compiler: gcc
+      env: CFLAGS="-Os" WAFOPTS="--disable-samplerate"
+    - python: 3.5
       os: linux
       compiler: gcc
       env: HAVE_AUBIO_DOUBLE=1 CFLAGS="-O3" WAFOPTS="--enable-fftw3"
@@ -29,39 +30,23 @@ matrix:
       env: CFLAGS="`dpkg-buildflags --get CFLAGS`" LDFLAGS="`dpkg-buildflags --get LDFLAGS`"
     - language: C
       os: osx
-      osx_image: xcode8
-      compiler: clang
-      env: CFLAGS="-Os" HAVE_AUBIO_DOUBLE=1 WAFOPTS="--disable-accelerate"
-    - language: C
-      os: osx
-      osx_image: xcode8
-      compiler: clang
-      env: WAFOPTS="--enable-fat --disable-avcodec --disable-sndfile"
-    - language: C
-      os: osx
-      osx_image: xcode8
       compiler: clang
-      env: WAFOPTS="--with-target-platform=ios --disable-avcodec --disable-sndfile" AUBIO_NOTESTS=1
     - language: C
       os: osx
-      osx_image: xcode8
       compiler: clang
-      env: WAFOPTS="--with-target-platform=iosimulator --disable-avcodec --disable-sndfile" AUBIO_NOTESTS=1
+      env: CFLAGS="-Os" HAVE_AUBIO_DOUBLE=1 WAFOPTS="--disable-accelerate"
     - language: C
       os: osx
-      osx_image: xcode8.2
       compiler: clang
-      env: WAFOPTS="--enable-fat --disable-avcodec --disable-sndfile"
+      env: WAFOPTS="--enable-fat --disable-avcodec --disable-sndfile --disable-samplerate"
     - language: C
       os: osx
-      osx_image: xcode8.2
       compiler: clang
-      env: WAFOPTS="--with-target-platform=ios --disable-avcodec --disable-sndfile" AUBIO_NOTESTS=1
+      env: WAFOPTS="--with-target-platform=ios --disable-avcodec --disable-sndfile --disable-samplerate" AUBIO_NOTESTS=1
     - language: C
       os: osx
-      osx_image: xcode8.2
       compiler: clang
-      env: WAFOPTS="--with-target-platform=iosimulator --disable-avcodec --disable-sndfile" AUBIO_NOTESTS=1
+      env: WAFOPTS="--with-target-platform=iosimulator --disable-avcodec --disable-sndfile --disable-samplerate" AUBIO_NOTESTS=1
 
 # use trusty
 dist: trusty
@@ -81,33 +66,49 @@ addons:
     - libasound2-dev
     - libfftw3-dev
     - sox
+    - lcov
+  homebrew:
+    packages:
+    - sox
+    - ffmpeg
+    - libsndfile
+    - lcov
+    update: true
 
 before_install:
    - |
      if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
-       brew update
-       brew install sox
-       brew install ffmpeg
-       brew install libsndfile
        export PATH="$HOME/Library/Python/2.7/bin/:$PATH"
      fi;
 
 install:
+  - |
+    if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
+      alias pip=pip2
+    fi;
   - travis_retry pip install --upgrade pip
   - travis_retry make getwaf expandwaf deps_python
   - which pip
   - pip --version
+  - pip install coverage
 
 script:
   - make create_test_sounds
   - |
     if [[ -z "$AUBIO_NOTESTS" ]]; then
       make test_lib_python_clean
-      make test_python_only_clean
+      make coverage
     else
       make test_lib_only_clean
     fi;
 
+after_success:
+  - |
+    if [[ -z "$AUBIO_NOTESTS" ]]; then
+      # upload to codecov
+      bash <(curl -s https://codecov.io/bash)
+    fi
+
 notifications:
     irc:
         channels: