summaryrefslogtreecommitdiff
path: root/shared/meson.build
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2021-02-17 16:11:49 +0100
committerThomas Haller <thaller@redhat.com>2021-02-18 19:46:57 +0100
commit341b6e0704daf460d823c66ee83d441c26084a94 (patch)
tree4d2ad9c23a5c948d558100058720bef7ecdd14d4 /shared/meson.build
parent243051a8a62a01dc34a89cf9b3ea4d3ad961805b (diff)
downloadNetworkManager-341b6e0704daf460d823c66ee83d441c26084a94.tar.gz
all: change G_LOG_DOMAIN to "nm"th/libnm-core-split
glib requires G_LOG_DOMAIN defined so that log messages are labeled to belong to NetworkManager or libnm. However, we don't actually want to use glib logging. Our library libnm MUST not log anything, because it spams the user's stdout/stderr. Instead, a library must report notable events via its API. Note that there is also LIBNM_CLIENT_DEBUG to explicitly enable debug logging, but that doesn't use glib logging either. Also, the daemon does not use glib logging instead it logs to syslog. When run with `--debug`. Hence, it's not useful for us to define different G_LOG_DOMAIN per library/application, because none of our libraries/applications should use glib logging. It also gets slightly confusing, because we have the static library like `src/libnm-core-impl`, which is both linked into `libnm` (the library) and `NetworkManager` (the daemon). Which logging domain should they use? Set the G_LOG_DOMAIN to "nm" everywhere. But no longer do it via `-D` arguments to the compiler. See-also: https://developer.gnome.org/glib/stable/glib-Message-Logging.html#G-LOG-DOMAIN:CAPS
Diffstat (limited to 'shared/meson.build')
-rw-r--r--shared/meson.build24
1 files changed, 0 insertions, 24 deletions
diff --git a/shared/meson.build b/shared/meson.build
index a51497000e..6d680beb1a 100644
--- a/shared/meson.build
+++ b/shared/meson.build
@@ -105,9 +105,6 @@ libnm_std_aux = static_library(
'nm-std-aux/nm-std-utils.c',
],
include_directories: top_inc,
- c_args: [
- '-DG_LOG_DOMAIN="libnm"',
- ],
)
libnm_glib_aux = static_library(
@@ -129,9 +126,6 @@ libnm_glib_aux = static_library(
'nm-glib-aux/nm-time-utils.c',
),
dependencies: glib_nm_default_dep,
- c_args: [
- '-DG_LOG_DOMAIN="libnm"',
- ],
link_with: [
libc_siphash,
libnm_std_aux,
@@ -160,9 +154,6 @@ libnm_udev_aux = static_library(
glib_nm_default_dep,
libudev_dep,
],
- c_args: [
- '-DG_LOG_DOMAIN="libnm"',
- ],
)
libnm_udev_aux_dep = declare_dependency(
@@ -176,9 +167,6 @@ libnm_base = static_library(
'nm-base/nm-ethtool-base.c',
),
dependencies: libnm_glib_aux_dep_link,
- c_args: [
- '-DG_LOG_DOMAIN="libnm"',
- ],
)
libnm_base_dep = declare_dependency(
@@ -198,9 +186,6 @@ libnm_log_core = static_library(
glib_nm_default_dep,
libsystemd_dep,
],
- c_args: [
- '-DG_LOG_DOMAIN="NetworkManager"',
- ],
)
libnm_log_core_dep = declare_dependency(
@@ -221,9 +206,6 @@ libnm_platform = static_library(
dependencies: [
glib_nm_default_dep,
],
- c_args: [
- '-DG_LOG_DOMAIN="NetworkManager"',
- ],
)
libnm_platform_dep = declare_dependency(
@@ -282,9 +264,6 @@ libnm_systemd_shared = static_library(
'systemd/src/shared',
),
dependencies: glib_nm_default_dep,
- c_args: [
- '-DG_LOG_DOMAIN="libnm"',
- ],
)
libnm_systemd_shared_dep = declare_dependency(
@@ -301,9 +280,6 @@ libnm_systemd_logging_stub = static_library(
'nm-systemd-logging-stub',
sources: 'systemd/nm-logging-stub.c',
dependencies: glib_nm_default_dep,
- c_args: [
- '-DG_LOG_DOMAIN="libnm"',
- ],
)
if enable_tests