From: Marcel Hollerbach Date: Mon, 23 Sep 2019 12:11:51 +0000 (+0200) Subject: eina_log: ensure that we do not spam journald with our intree binaries X-Git-Tag: submit/tizen/20190923.215628~29 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5617f6e2d1699fdf6e9e76850f59174879dab0c3;p=platform%2Fupstream%2Fefl.git eina_log: ensure that we do not spam journald with our intree binaries EFL_RUN_IN_TREE is set for all binaries that are executed during build time, and test suites. With this commit we are ensuring that we are not sending messages during that time to journald, otherwise we would waste a lot of time + we would create a lot of unneccessary log messages. (eina test suite runtime with journald hook: 11.21s without journald hook: 0.57s) Reviewed-by: Mike Blumenkrantz Differential Revision: https://phab.enlightenment.org/D10076 --- diff --git a/src/lib/eina/eina_log.c b/src/lib/eina/eina_log.c index b52f504..31bd818 100644 --- a/src/lib/eina/eina_log.c +++ b/src/lib/eina/eina_log.c @@ -1559,7 +1559,7 @@ eina_log_init(void) #endif #ifdef HAVE_SYSTEMD - if (getenv("NOTIFY_SOCKET")) + if (getenv("NOTIFY_SOCKET") && !getenv("EFL_RUN_IN_TREE")) _print_cb = eina_log_print_cb_journald; #endif