From adf3048247c51158bfc2545856a3fc93c2b4eb37 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20W=C3=A4ckerlin?= Date: Wed, 5 Apr 2017 14:44:23 +0000 Subject: [PATCH] build improvements and a logging fix --- configure.ac | 34 +++++++++++++++++++++++++++++++- src/autofunctiontracelog4cxx.cxx | 12 +++++------ 2 files changed, 39 insertions(+), 7 deletions(-) diff --git a/configure.ac b/configure.ac index 9e4db77..bd00c4c 100644 --- a/configure.ac +++ b/configure.ac @@ -9,7 +9,8 @@ PROJECT_URL="https://dev.marc.waeckerlin.org/projects/mrw-c++" m4_define(x_package_name, mrw-c++) # project's name m4_define(x_major, 4) # project's major version -m4_define(x_minor, 4) # project's minor version +m4_define(x_minor, 5) # project's minor version +m4_define(x_least_diff, 469) # diff in minor m4_include(ax_init_standard_project.m4) AC_INIT(x_package_name, x_version, x_bugreport, x_package_name) AM_INIT_AUTOMAKE([1.9 tar-pax]) @@ -186,6 +187,36 @@ AC_SUBST(THREADS) AX_OUTPUT # infos and warnings +if test "$have_valgrind" != "yes"; then + AC_MSG_WARN([Feature Valgrind is disabled, to use it --enable-valgrind]) +fi +if test "$with_threads" != "yes"; then + AC_MSG_WARN([Feature Threads is disabled, to use it --enable-threads]) +fi +if test "$with_autofntrace" != "yes"; then + AC_MSG_WARN([Feature Automatic Function Trace is disabled, to use it --enable-autofntrace]) +fi +if test "$have_dir" != "yes"; then + AC_MSG_WARN([Feature POSIX Directory Access is disabled, to use it --enable-dir]) +fi +if test "$have_exec" != "yes"; then + AC_MSG_WARN([Feature UNIX Fork Execute is disabled, to use it --enable-exec]) +fi +if test "$have_regex" != "yes"; then + AC_MSG_WARN([Feature Regular Expressions is disabled, to use it --enable-regex]) +fi +if test "$have_log4cxx" != "yes"; then + AC_MSG_WARN([Feature Log4cxx Logging is disabled, to use it --enable-log4cxx]) +fi +if test "$have_ltdl" != "yes"; then + AC_MSG_WARN([Feature LibTool Library is disabled, to use it --enable-ltdl]) +fi +if test "$have_dynamicstack" != "yes"; then + AC_MSG_WARN([Feature Dynamic Stack is disabled, to use it --enable-dynamicstack]) +fi +if test "$have_stacktrace" != "yes"; then + AC_MSG_WARN([Feature Stack Trace is disabled, to use it --enable-stacktrace]) +fi if test "$with_threads" = "no"; then AC_MSG_WARN([Multithreading support is disabled! - use --enable-threads to enable it @@ -225,3 +256,4 @@ stacktrace is disabled or ltdl is disabled. --enable-dynamic-stack should always be used together with options --enable-stacktrace and --enable-ltdl]);fi +AC_MSG_NOTICE([configuration done for ${PACKAGE_STRING}]) diff --git a/src/autofunctiontracelog4cxx.cxx b/src/autofunctiontracelog4cxx.cxx index f024a69..62e2e14 100644 --- a/src/autofunctiontracelog4cxx.cxx +++ b/src/autofunctiontracelog4cxx.cxx @@ -197,9 +197,9 @@ extern "C" void __cyg_profile_func_enter(void *this_fn, void*) { (hierarchy.rfind(' ', std::min(hierarchy.find('<'), hierarchy.find("operator")))); if (p!=std::string::npos) hierarchy.erase(0, p+1); -// hierarchy.erase -// (hierarchy.find_first_not_of -// ("qwertzuiopasdfghjklyxcvbnmQWERTZUIOPASDFGHJKLYXCVBNM1234567890_.")); + hierarchy.erase + (hierarchy.find_first_not_of + ("qwertzuiopasdfghjklyxcvbnmQWERTZUIOPASDFGHJKLYXCVBNM1234567890_.")); if (hierarchy=="") hierarchy = "global"; std::string name("mrw.fn."+hierarchy); log4cxx::Logger* logger @@ -238,9 +238,9 @@ extern "C" void __cyg_profile_func_exit(void *this_fn, void*) { (hierarchy.rfind(' ', std::min(hierarchy.find('<'), hierarchy.find("operator")))); if (p!=std::string::npos) hierarchy.erase(0, p+1); -// hierarchy.erase -// (hierarchy.find_first_not_of -// ("qwertzuiopasdfghjklyxcvbnmQWERTZUIOPASDFGHJKLYXCVBNM1234567890_.")); + hierarchy.erase + (hierarchy.find_first_not_of + ("qwertzuiopasdfghjklyxcvbnmQWERTZUIOPASDFGHJKLYXCVBNM1234567890_.")); if (hierarchy=="") hierarchy = "global"; std::string name("mrw.fn."+hierarchy); log4cxx::Logger* logger