From 0a059dd4bd9195686df8e9d2892f24a3df4822e6 Mon Sep 17 00:00:00 2001 From: Michael Jeanson Date: Mon, 22 Nov 2021 11:29:09 -0500 Subject: [PATCH] jjb: lttng-tools: not all configs build liblttng-ctl Add conditionnal logic to handle configurations where we don't build liblttng-ctl. Signed-off-by: Michael Jeanson --- scripts/lttng-tools/build.sh | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/scripts/lttng-tools/build.sh b/scripts/lttng-tools/build.sh index e4a85ac..f0e4344 100755 --- a/scripts/lttng-tools/build.sh +++ b/scripts/lttng-tools/build.sh @@ -507,12 +507,16 @@ fi # Clean the build directory $MAKE clean -# Cleanup rpath in executables and shared libraries +# Cleanup rpath in executables find "$WORKSPACE/$PREFIX/bin" -type f -perm -0500 -exec chrpath --delete {} \; -find "$WORKSPACE/$PREFIX/lib" -name "*.so" -exec chrpath --delete {} \; -# Remove libtool .la files -find "$WORKSPACE/$PREFIX/lib" -name "*.la" -exec rm -f {} \; +# Some configs don't build liblttng-ctl +if [ -d "$WORKSPACE/$PREFIX/lib" ]; then + # Cleanup rpath in shared libraries + find "$WORKSPACE/$PREFIX/lib" -name "*.so" -exec chrpath --delete {} \; + # Remove libtool .la files + find "$WORKSPACE/$PREFIX/lib" -name "*.la" -exec rm -f {} \; +fi # Exit with failure if any of the tests failed exit $failed_tests -- 2.34.1