lib/util: add syslog.h for ot_journal_print()
authorChristian Hergert <chergert@redhat.com>
Fri, 11 Feb 2022 22:31:12 +0000 (14:31 -0800)
committerChristian Hergert <chergert@redhat.com>
Fri, 11 Feb 2022 23:40:19 +0000 (15:40 -0800)
If we aren't including sd-journal, we may need this too.

src/libotutil/otutil.h

index 1b543062bf4c2fa838bb24246ce889db9f2b3983..4279bc150459598580ad4016c31ee4d9d09485f4 100644 (file)
 
 #include <gio/gio.h>
 #include <string.h> /* Yeah...let's just do that here. */
+#include <syslog.h>
 #include <libglnx.h>
 
+#ifdef HAVE_LIBSYSTEMD
+#include <systemd/sd-journal.h>
+#endif
+
 /* https://bugzilla.gnome.org/show_bug.cgi?id=766370 */
 #if !GLIB_CHECK_VERSION(2, 49, 3)
 #define OT_VARIANT_BUILDER_INITIALIZER {{0,}}