mirror of
https://github.com/radareorg/radare2.git
synced 2024-11-23 21:29:49 +00:00
c932d1abff
* r2pm/meson.build: install r2pm * meson.build: use system libraries when available * travis: add fedora-sys to the list of things to test * bin_nso.c: still include lz4.c when not on meson * Dockerfile.travis: add required system dependencies to dockerfile * meson.build: split zip_dep in libzip and zlib dependencies * shlr/meson.build: zip needs zlib
53 lines
2.1 KiB
Bash
53 lines
2.1 KiB
Bash
#!/bin/bash
|
|
set -x
|
|
|
|
export PATH=${TRAVIS_BUILD_DIR}/install/bin:${PATH}
|
|
export LD_LIBRARY_PATH=${TRAVIS_BUILD_DIR}/install/lib:${TRAVIS_BUILD_DIR}/install/lib64:${LD_LIBRARY_PATH}
|
|
git clone --depth 1 --branch "${R2R_BRANCH}" "${R2R_REPO}" || true # If cloning fails that's not an error: we simply fallback to master.
|
|
ls radare2-regressions >/dev/null 2>&1 || git clone --depth 1 --branch "${R2R_DEFAULT_BRANCH}" "${R2R_DEFAULT_REPO}"
|
|
|
|
if [ "${INSTALL_SYSTEM}" == "meson" ] ; then
|
|
echo "Installing with meson + ninja"
|
|
|
|
OPTS=""
|
|
if [ "${R2_SYS_CAPSTONE}" != "" ] ; then
|
|
OPTS="${OPTS} -D use_sys_capstone=${R2_SYS_CAPSTONE}"
|
|
fi
|
|
if [ "${R2_SYS_MAGIC}" != "" ] ; then
|
|
OPTS="${OPTS} -D use_sys_magic=${R2_SYS_MAGIC}"
|
|
fi
|
|
if [ "${R2_SYS_ZLIB}" != "" ] ; then
|
|
OPTS="${OPTS} -D use_sys_zlib=${R2_SYS_ZLIB}"
|
|
fi
|
|
if [ "${R2_SYS_ZIP}" != "" ] ; then
|
|
OPTS="${OPTS} -D use_sys_zip=${R2_SYS_ZIP}"
|
|
fi
|
|
if [ "${R2_SYS_LZ4}" != "" ] ; then
|
|
OPTS="${OPTS} -D use_sys_lz4=${R2_SYS_LZ4}"
|
|
fi
|
|
|
|
meson --prefix=${TRAVIS_BUILD_DIR}/install ${OPTS} build
|
|
pushd build
|
|
ninja
|
|
ninja install
|
|
popd
|
|
export PKG_CONFIG_PATH=$(pwd)/build/meson-private:${PKG_CONFIG_PATH}
|
|
else
|
|
echo "Installing with acr + make"
|
|
./configure --prefix=${TRAVIS_BUILD_DIR}/install > /dev/null || exit 1
|
|
make -s -j2 > /dev/null || exit 1
|
|
make install > /dev/null || exit 1
|
|
export PKG_CONFIG_PATH=${TRAVIS_BUILD_DIR}/pkgcfg:${PKG_CONFIG_PATH}
|
|
fi
|
|
#[ "$TRAVIS_OS_NAME" != "osx" ] && mkdir -p /tmp/kcov && pushd /tmp/kcov
|
|
#[ "$TRAVIS_OS_NAME" != "osx" ] && mkdir ${TRAVIS_BUILD_DIR}/kcov
|
|
#[ "$TRAVIS_OS_NAME" != "osx" ] && wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz && tar xzf master.tar.gz && mkdir kcov-master/build && cd kcov-master/build && cmake .. && make && make install DESTDIR=../tmp && popd
|
|
#[ "$TRAVIS_OS_NAME" != "osx" ] && export KCOV="/tmp/kcov/kcov-master/tmp/usr/local/bin/kcov --coveralls-id=$TRAVIS_JOB_ID ${TRAVIS_BUILD_DIR}/kcov"
|
|
export NOOK=1
|
|
export NOREPORT=1
|
|
cd radare2-regressions
|
|
git remote -v
|
|
git branch
|
|
git rev-parse HEAD
|
|
VERBOSE=1 make -k all
|