ci: travis: add job to build efl and run tests with address sanitizer
A first step to have addrress sanitizer coverage on our EFL build. It already catched some use after free errors and memory corruptions. Still we have some limititation how we are running this right now. We currently ignore some leaks that are exposed durign the normal build wile haveing the short living runs of edje_cc, elm_prefs_cc, etc. For now the whole leak detection is disabled on the testsuite as well. This is still very valuable, especially for all non-leak cases it finds, thus we are goign to run this on our daily build. Signed-off-by: Stefan Schmidt <s.schmidt@samsung.com> Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de> Differential Revision: https://phab.enlightenment.org/D10691
This commit is contained in:
parent
3bc0fef21c
commit
f825326750
|
@ -0,0 +1,16 @@
|
|||
# Evas
|
||||
leak:evas_module_find_type
|
||||
leak:generic_cache_new
|
||||
# Edje / cpplib
|
||||
leak:handle_directive
|
||||
# Edje_cc
|
||||
leak:edje_cc
|
||||
leak:_efl_loop_message_handler_message_send
|
||||
leak:ecore_ipc_client_add
|
||||
# Elm_prefs_cc
|
||||
leak:st_collection_page_items_item_label
|
||||
leak:st_collection_page_items_item_name
|
||||
leak:st_collection_page_items_item_string_placeholder
|
||||
leak:st_collection_page_items_item_string_default
|
||||
leak:st_collection_page_items_item_string_deny
|
||||
leak:ob_collection_page_items_item
|
|
@ -69,7 +69,13 @@ if [ "$DISTRO" != "" ] ; then
|
|||
travis_endfold cov-download
|
||||
fi
|
||||
|
||||
if [ "$1" = "mingw" ]; then
|
||||
if [ "$1" = "asan" ]; then
|
||||
travis_fold meson meson
|
||||
docker exec --env EIO_MONITOR_POLL=1 --env CC="ccache gcc" \
|
||||
--env CXX="ccache g++" --env CFLAGS="-O0 -g" --env CXXFLAGS="-O0 -g" \
|
||||
--env LD="ld.gold" $(cat $HOME/cid) sh -c "mkdir build && meson build $OPTS -Db_sanitize=address"
|
||||
travis_endfold meson
|
||||
elif [ "$1" = "mingw" ]; then
|
||||
OPTS="$OPTS $MINGW_COPTS"
|
||||
travis_fold cross-native cross-native
|
||||
docker exec $(cat $HOME/cid) sh -c '.ci/bootstrap-efl-native-for-cross.sh'
|
||||
|
|
|
@ -23,7 +23,11 @@ NUM_TRIES=5
|
|||
travis_fold check "ninja test"
|
||||
if [ "$DISTRO" != "" ] ; then
|
||||
for tries in $(seq 1 ${NUM_TRIES}); do
|
||||
(docker exec --env EINA_LOG_BACKTRACE="0" --env EIO_MONITOR_POLL=1 $(cat $HOME/cid) meson test -t 120 -C build --wrapper dbus-launch ) && break
|
||||
if [ "$1" = "asan" ]; then
|
||||
(docker exec --env EINA_LOG_BACKTRACE="0" --env EIO_MONITOR_POLL=1 --env ASAN_OPTIONS=detect_leaks=0:abort_on_error=0 $(cat $HOME/cid) meson test -t 120 -C build --wrapper dbus-launch) && break
|
||||
else
|
||||
(docker exec --env EINA_LOG_BACKTRACE="0" --env EIO_MONITOR_POLL=1 $(cat $HOME/cid) meson test -t 120 -C build --wrapper dbus-launch ) && break
|
||||
fi
|
||||
docker exec --env EIO_MONITOR_POLL=1 $(cat $HOME/cid) cat build/meson-logs/testlog-dbus-launch.txt
|
||||
if [ $tries != ${NUM_TRIES} ] ; then echo "tests failed, trying again!" ; fi
|
||||
false
|
||||
|
|
|
@ -9,6 +9,10 @@ if [ "$1" = "coverity" ] ; then
|
|||
exit 0
|
||||
fi
|
||||
travis_fold install "ninja install"
|
||||
if [ "$1" = "asan" ]; then
|
||||
docker exec --env EIO_MONITOR_POLL=1 --env ASAN_OPTIONS=abort_on_error=0 --env LSAN_OPTIONS=suppressions=/src/.ci/asan-ignore-leaks.supp $(cat $HOME/cid) ninja -C build install
|
||||
exit $?
|
||||
fi
|
||||
if [ "$DISTRO" != "" ] ; then
|
||||
docker exec --env EIO_MONITOR_POLL=1 $(cat $HOME/cid) ninja -C build install
|
||||
else
|
||||
|
|
|
@ -6,6 +6,10 @@ if [ "$1" = "release-ready" ] ; then
|
|||
exit 0
|
||||
fi
|
||||
travis_fold ninja ninja
|
||||
if [ "$1" = "asan" ]; then
|
||||
docker exec --env EIO_MONITOR_POLL=1 --env ASAN_OPTIONS=abort_on_error=0 --env LSAN_OPTIONS=suppressions=/src/.ci/asan-ignore-leaks.supp $(cat $HOME/cid) ninja -C build
|
||||
exit $?
|
||||
fi
|
||||
if [ "$DISTRO" != "" ] ; then
|
||||
if [ "$1" = "coverity" ] ; then
|
||||
docker exec --env EIO_MONITOR_POLL=1 --env PATH="/src/cov-analysis-linux64-2019.03/bin:$PATH" $(cat $HOME/cid) sh -c "cov-build --dir cov-int ninja -C build"
|
||||
|
|
|
@ -71,6 +71,9 @@ jobs:
|
|||
- os: linux
|
||||
if: type = cron
|
||||
env: DISTRO=Fedora31 CI_BUILD_TYPE=coverity
|
||||
- os: linux
|
||||
if: type = cron
|
||||
env: DISTRO=Fedora31 CI_BUILD_TYPE=asan
|
||||
|
||||
services:
|
||||
- docker
|
||||
|
|
Loading…
Reference in New Issue