]> git.ipfire.org Git - thirdparty/util-linux.git/blobdiff - .travis-functions.sh
Merge branch 'dana/column-x' of https://github.com/okdana/util-linux
[thirdparty/util-linux.git] / .travis-functions.sh
index 7b20e886c24b9136f045a5e3c380d43d36d860be..684c20588d9c2349517f53e10b110bd0c031c519 100755 (executable)
@@ -36,6 +36,17 @@ function xconfigure
        return $err
 }
 
+# TODO: integrate checkusage into our regular tests and remove this function
+function make_checkusage
+{
+       local tmp
+       if ! tmp=$($MAKE checkusage 2>&1) || test -n "$tmp"; then
+               echo "$tmp"
+               echo "make checkusage failed" >&2
+               return 1
+       fi
+}
+
 function check_nonroot
 {
        local opts="$MAKE_CHECK_OPTS --show-diff"
@@ -50,12 +61,14 @@ function check_nonroot
        osx_prepare_check
        $MAKE check TS_OPTS="$opts" || return
 
+       make_checkusage || return
+
        $MAKE install DESTDIR=/tmp/dest || return
 }
 
 function check_root
 {
-       local opts="$MAKE_CHECK_OPTS --parallel=1 --show-diff"
+       local opts="$MAKE_CHECK_OPTS --show-diff"
 
        xconfigure \
                --enable-all-programs \
@@ -66,6 +79,9 @@ function check_root
        osx_prepare_check
        sudo -E $MAKE check TS_OPTS="$opts" || return
 
+       # root on osx has not enough permission for make install ;)
+       [ "$TRAVIS_OS_NAME" = "osx" ] && return
+
        # keep PATH to make sure sudo would find $CC
        sudo env "PATH=$PATH" $MAKE install || return
 }
@@ -110,7 +126,6 @@ function travis_install_script
 function osx_install_script
 {
        brew update >/dev/null
-       brew tap homebrew/dupes
 
        brew install gettext ncurses socat xz
        brew link --force gettext