jjb: lttng-ust-benchmarks: move amd64 jobs to deb12
[lttng-ci.git] / scripts / lttng-ust-benchmarks / build.sh
CommitLineData
51c9c62d 1#!/bin/bash
b3fc12e8
MJ
2#
3# Copyright (C) 2015, Jonathan Rajotte-Julien <jonathan.rajotte-julien@efficios.com>
4# 2016, Michael Jeanson <mjeanson@efficios.com>
5#
6# This program is free software: you can redistribute it and/or modify
7# it under the terms of the GNU General Public License as published by
8# the Free Software Foundation, either version 3 of the License, or
9# (at your option) any later version.
10#
11# This program is distributed in the hope that it will be useful,
12# but WITHOUT ANY WARRANTY; without even the implied warranty of
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14# GNU General Public License for more details.
15#
16# You should have received a copy of the GNU General Public License
17# along with this program. If not, see <http://www.gnu.org/licenses/>.
18
51c9c62d
MJ
19set -exu
20
b3fc12e8
MJ
21SRCDIR="$WORKSPACE/src/$PROJECT_NAME"
22
23# Create build directory
24rm -rf "$WORKSPACE/build"
25mkdir -p "$WORKSPACE/build"
26
27PYTHON3=python3
b8a93ea3 28P3_VERSION=$($PYTHON3 -c 'import sys;v = sys.version.split()[0].split("."); print("{}.{}".format(v[0], v[1]))')
b3fc12e8
MJ
29
30# liburcu
31URCU_INCS="$WORKSPACE/deps/liburcu/build/include/"
32URCU_LIBS="$WORKSPACE/deps/liburcu/build/lib/"
33
34# lttng-ust
35UST_INCS="$WORKSPACE/deps/lttng-ust/build/include/"
36UST_LIBS="$WORKSPACE/deps/lttng-ust/build/lib/"
37UST_BINS="$WORKSPACE/deps/lttng-ust/build/bin/"
38
39# babeltrace
40BABEL_INCS="$WORKSPACE/deps/babeltrace/build/include/"
41BABEL_LIBS="$WORKSPACE/deps/babeltrace/build/lib/"
42BABEL_PY="$WORKSPACE/deps/babeltrace/build/lib/python$P3_VERSION/site-packages/"
43
44# lttng-tools
45TOOLS_INCS="$WORKSPACE/deps/lttng-tools/build/include/"
46TOOLS_LIBS="$WORKSPACE/deps/lttng-tools/build/lib/"
47TOOLS_BINS="$WORKSPACE/deps/lttng-tools/build/bin/"
48TOOLS_PY="$WORKSPACE/deps/lttng-tools/build/lib/python$P3_VERSION/site-packages/"
49
50rm -rf "$WORKSPACE/deps/lttng-modules"
bf492de3 51git clone https://github.com/lttng/lttng-modules.git "$WORKSPACE/deps/lttng-modules"
b3fc12e8
MJ
52
53export CFLAGS="-I$URCU_INCS -I$UST_INCS"
54export LDFLAGS="-L$URCU_LIBS -L$UST_LIBS"
55export LD_LIBRARY_PATH="$URCU_LIBS:$UST_LIBS:$BABEL_LIBS:$TOOLS_LIBS:${LD_LIBRARY_PATH:-}"
56export PYTHONPATH="$TOOLS_PY:$BABEL_PY:${PYTHONPATH:-}"
57export PATH="$TOOLS_BINS:$UST_BINS:$PATH"
58export LTTNG_MODULES_DIR="$WORKSPACE/deps/lttng-modules/"
352b773c 59export PKG_CONFIG_PATH="$UST_LIBS/pkgconfig"
b3fc12e8
MJ
60
61export LTTNG_SESSION_CONFIG_XSD_PATH="$WORKSPACE/deps/lttng-tools/build/share/xml/lttng"
62export LTTNG_CONSUMERD64_BIN="$WORKSPACE/deps/lttng-tools/build/lib/lttng/libexec/lttng-consumerd"
63
64cd "$SRCDIR"
65
d9e3cd99 66make PYTHON="$PYTHON3"
b3fc12e8 67
d9e3cd99 68"$PYTHON3" ./benchmarks.py
b3fc12e8
MJ
69
70# EOF
This page took 0.032814 seconds and 4 git commands to generate.