lgtm: Build external dependencies for a more complete analysis

The build system is a bit limited, only the repository directory and
LGTM_WORKSPACE is writable.  sudo doesn't work at all, for others we
don't have enough permission.
This commit is contained in:
Tobias Brunner
2020-01-30 17:12:48 +01:00
parent 2cb4af6696
commit da9e4fa04b
2 changed files with 35 additions and 13 deletions
+23 -1
View File
@@ -6,6 +6,28 @@ queries:
extraction:
cpp:
prepare:
packages:
# for tss2
- libssl-dev
after_prepare:
- export DEPS_BUILD_DIR=$LGTM_WORKSPACE/deps
- mkdir -p $DEPS_BUILD_DIR
- export DEPS_PREFIX=$DEPS_BUILD_DIR/usr
- mkdir -p $DEPS_PREFIX
- export PKG_CONFIG_PATH="$DEPS_PREFIX/lib/pkgconfig:$PKG_CONFIG_PATH"
- export LD_LIBRARY_PATH="$DEPS_PREFIX/lib:$LD_LIBRARY_PATH"
- mkdir -p $LGTM_WORKSPACE/bin
# sudo doesn't work on the build hosts
- ln -s /usr/bin/nice $LGTM_WORKSPACE/bin/sudo
# for ldconfig we don't have enough permissions
- ln -s /bin/true $LGTM_WORKSPACE/bin/ldconfig
# likewise for apt-get
- ln -s /bin/echo $LGTM_WORKSPACE/bin/apt-get
- export PATH=$LGTM_WORKSPACE/bin:$PATH
- export TEST=all
- ./scripts/test.sh deps
- rm $LGTM_WORKSPACE/bin/*
configure:
command:
# follows the "all" build in test.sh (without custom-compiled stuff)
@@ -19,4 +41,4 @@ extraction:
--disable-kernel-wfp --disable-kernel-iph --disable-winhttp
--disable-af-alg --disable-coverage
--disable-python-eggs-install
--disable-botan --disable-wolfssl --disable-tss-tss2
--disable-monolithic --disable-leak-detective