lib: Add ot_journal_* helper macros
Rather than wrapping each instance of `sd_journal_*` with `HAVE_SYSTEMD`, let's just add some convenience macros that are just no-op if we're not compiling with systemd. Closes: #1841 Approved by: cgwalters
This commit is contained in:
1 parent
d69214ade3
commit
5464535205
4 files changed
+14
-16
No files matched your search
@@ -44,6 +44,14 @@
|
||||
} \
|
||||
} G_STMT_END;
|
||||
|
||||
#ifdef HAVE_LIBSYSTEMD
|
||||
#define ot_journal_send(...) sd_journal_send(__VA_ARGS__)
|
||||
#define ot_journal_print(...) sd_journal_print(__VA_ARGS__)
|
||||
#else
|
||||
#define ot_journal_send(...) {}
|
||||
#define ot_journal_print(...) {}
|
||||
#endif
|
||||
|
||||
#include <ot-keyfile-utils.h>
|
||||
#include <ot-gio-utils.h>
|
||||
#include <ot-fs-utils.h>
|
||||
|
||||
Reference in new issue
Block a user