jjb: lttng-tools: Enable python bindings in most configs
authorMichael Jeanson <mjeanson@efficios.com>
Tue, 28 Nov 2017 22:03:34 +0000 (17:03 -0500)
committerMichael Jeanson <mjeanson@efficios.com>
Tue, 28 Nov 2017 22:03:34 +0000 (17:03 -0500)
The python bindings are not related to agents. They are primarily used in
regression and ust tests.

Reported-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
scripts/lttng-tools/build.sh

index d20522dfb2577c21c96205ec9f87654fddb7feef..9639fecf40f04829cbf763963555786c09e96adf 100755 (executable)
@@ -207,17 +207,21 @@ else
     NO_UST="--disable-lttng-ust"
 fi
 
+# Most build configs require the python bindings
+CONF_OPTS="--enable-python-bindings"
+export PYTHON="python3"
+export PYTHON_CONFIG="/usr/bin/python3-config"
+
 # Set configure options for each build configuration
-CONF_OPTS=""
 case "$conf" in
 static)
     echo "Static build"
-    CONF_OPTS="--enable-static --disable-shared"
+    CONF_OPTS+=" --enable-static --disable-shared"
     ;;
 
 no-ust)
     echo "Build without UST support"
-    CONF_OPTS="$NO_UST"
+    CONF_OPTS+=" $NO_UST"
     ;;
 
 agents)
@@ -229,12 +233,6 @@ agents)
     echo "Enable Python agents"
     export PYTHONPATH="$UST_PYTHON2:$UST_PYTHON3"
     CONF_OPTS+=" --enable-test-python-agent-all"
-
-    echo "Enable Python bindings"
-    # We only support bindings built with Python 3
-    export PYTHON="python3"
-    export PYTHON_CONFIG="/usr/bin/python3-config"
-    CONF_OPTS+=" --enable-python-bindings"
     ;;
 
 relayd-only)
@@ -249,7 +247,6 @@ debug-rcu)
 
 *)
     echo "Standard build"
-    CONF_OPTS=""
     ;;
 esac
 
@@ -354,17 +351,13 @@ if [ "$RUN_TESTS" = "yes" ]; then
         else
             prove --merge -v --exec '' - < "$BUILD_PATH/tests/unit_tests" --archive "$TAPDIR/unit/" || true
             prove --merge -v --exec '' - < "$BUILD_PATH/tests/fast_regression" --archive "$TAPDIR/fast_regression/" || true
+            prove --merge -v --exec '' - < "$BUILD_PATH/tests/with_bindings_regression" --archive "$TAPDIR/with_bindings_regression/" || true
         fi
     else
         # Regression is disabled for now, we need to adjust the testsuite for no ust builds.
         echo "Tests disabled for 'no-ust'."
     fi
 
-    # Run 'with_bindings_regression' test suite for 'python-bindings' config
-    if [ "$conf" = "python-bindings" ]; then
-        prove --merge -v --exec '' - < "$BUILD_PATH/tests/with_bindings_regression" --archive "$TAPDIR/with_bindings_regression/" || true
-    fi
-
     # TAP plugin is having a hard time with .yml files.
     find "$TAPDIR" -name "meta.yml" -exec rm -f {} \;
 
This page took 0.027037 seconds and 4 git commands to generate.