-#!/bin/bash -exu
+#!/bin/bash
#
# Copyright (C) 2015, Jonathan Rajotte-Julien <jonathan.rajotte-julien@efficios.com>
# 2016, Michael Jeanson <mjeanson@efficios.com>
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+set -exu
+
SRCDIR="$WORKSPACE/src/$PROJECT_NAME"
# Create build directory
mkdir -p "$WORKSPACE/build"
PYTHON3=python3
-P3_VERSION=$($PYTHON3 -c "import sys;print(sys.version[:3])")
+P3_VERSION=$($PYTHON3 -c 'import sys;v = sys.version.split()[0].split("."); print("{}.{}".format(v[0], v[1]))')
# liburcu
URCU_INCS="$WORKSPACE/deps/liburcu/build/include/"
TOOLS_PY="$WORKSPACE/deps/lttng-tools/build/lib/python$P3_VERSION/site-packages/"
rm -rf "$WORKSPACE/deps/lttng-modules"
-git clone git://github.com/lttng/lttng-modules.git "$WORKSPACE/deps/lttng-modules"
+git clone https://github.com/lttng/lttng-modules.git "$WORKSPACE/deps/lttng-modules"
export CFLAGS="-I$URCU_INCS -I$UST_INCS"
export LDFLAGS="-L$URCU_LIBS -L$UST_LIBS"
export PYTHONPATH="$TOOLS_PY:$BABEL_PY:${PYTHONPATH:-}"
export PATH="$TOOLS_BINS:$UST_BINS:$PATH"
export LTTNG_MODULES_DIR="$WORKSPACE/deps/lttng-modules/"
+export PKG_CONFIG_PATH="$UST_LIBS/pkgconfig"
export LTTNG_SESSION_CONFIG_XSD_PATH="$WORKSPACE/deps/lttng-tools/build/share/xml/lttng"
export LTTNG_CONSUMERD64_BIN="$WORKSPACE/deps/lttng-tools/build/lib/lttng/libexec/lttng-consumerd"