mirror of
https://github.com/irungentoo/toxcore.git
synced 2024-03-22 13:30:51 +08:00
50921070ce
This is in preparation for having multiple types of build. One of the future builds will be a hstox build, another may be frama-c or some other static analyser. It makes sense to split these up into multiple builds, because each of them can take a while, and running them in parallel will speed things up. Also, the hstox test coverage should be reported separately from the toxcore auto_test coverage.
26 lines
724 B
Bash
Executable File
26 lines
724 B
Bash
Executable File
#!/bin/sh
|
|
|
|
set -e -x
|
|
|
|
# Check if toxcore.h and toxav.h match apidsl tox.in.h and toxav.in.h.
|
|
../apidsl/_build/apigen.native ./other/apidsl/tox.in.h | $ASTYLE --options=./other/astyle/astylerc > toxcore/tox.h
|
|
../apidsl/_build/apigen.native ./other/apidsl/toxav.in.h | $ASTYLE --options=./other/astyle/astylerc > toxav/toxav.h
|
|
git diff --exit-code
|
|
|
|
# Build toxcore and run tests.
|
|
./autogen.sh
|
|
./configure \
|
|
--with-libsodium-libs=$CACHE_DIR/lib \
|
|
--with-libsodium-headers=$CACHE_DIR/include \
|
|
--enable-daemon \
|
|
--enable-logging \
|
|
--enable-ntox \
|
|
CFLAGS="-O0 -Wall -Wextra -fprofile-arcs -ftest-coverage -DTRAVIS_ENV=1"
|
|
|
|
make
|
|
make check
|
|
if [ -f build/test-suite.log ]; then
|
|
cat build/test-suite.log
|
|
fi
|
|
make dist
|