jjb: binutils-gdb: add missing workspace cleanup on macos
[lttng-ci.git] / scripts / babeltrace / build.sh
index f6bc52d516e79e9c79360f46d458be5159b094ed..91681d01e39ac4c3c918671cd0c8d5836ee5300a 100755 (executable)
@@ -106,13 +106,15 @@ SRCDIR="$WORKSPACE/src/babeltrace"
 TMPDIR="$WORKSPACE/tmp"
 PREFIX="/build"
 LIBDIR="lib"
+LIBDIR_ARCH="$LIBDIR"
 
 # RHEL and SLES both use lib64 but don't bother shipping a default autoconf
 # site config that matches this.
-if [[ ( -f /etc/redhat-release || -f /etc/SuSE-release ) && ( "$(uname -m)" == "x86_64" ) ]]; then
-    LIBDIR_ARCH="${LIBDIR}64"
-else
-    LIBDIR_ARCH="$LIBDIR"
+if [[ ( -f /etc/redhat-release || -f /etc/products.d/SLES.prod || -f /etc/yocto-release ) ]]; then
+    # Detect the userspace bitness in a distro agnostic way
+    if file -L /bin/bash | grep '64-bit' >/dev/null 2>&1; then
+        LIBDIR_ARCH="${LIBDIR}64"
+    fi
 fi
 
 # Create tmp directory
@@ -275,6 +277,11 @@ min)
     if vergte "$PACKAGE_VERSION" "2.0"; then
         CONF_OPTS+=("--enable-python-bindings" "--enable-python-plugins")
     fi
+
+    # Something is broken in docbook-xml on yocto
+    if [[ "$platform" = yocto* ]]; then
+        CONF_OPTS+=("--disable-man-pages")
+    fi
     ;;
 esac
 
@@ -366,6 +373,9 @@ if [ "$BABELTRACE_RUN_TESTS" = "yes" ]; then
        # Copy tap logs for the jenkins tap parser before cleaning the build dir
        rsync -a --exclude 'test-suite.log' --include '*/' --include '*.log' --exclude='*' tests/ "$WORKSPACE/tap"
 
+       # Copy the test suites top-level log which includes all tests failures
+       rsync -a --include 'test-suite.log' --include '*/' --exclude='*' tests/ "$WORKSPACE/log"
+
        # The test suite prior to 1.5 did not produce TAP logs
        if verlt "$PACKAGE_VERSION" "1.5"; then
            mkdir -p "$WORKSPACE/tap/no-log"
This page took 0.023541 seconds and 4 git commands to generate.