gio-launch-desktop, gmessages: Fix journald support using __BIONIC__ to skip support on Android

As per the Bionic docs, this functionality is Android, not bionic specific.

See: https://android.googlesource.com/platform/bionic/+/HEAD/docs/defines.md
This commit is contained in:
L. E. Segovia 2024-04-02 08:40:48 -03:00
parent b907e28454
commit 0da4b1bf31
3 changed files with 8 additions and 8 deletions

View File

@ -37,7 +37,7 @@
#include <sys/types.h>
#include <unistd.h>
#if defined(__linux__) && !defined(__BIONIC__)
#if defined(__linux__) && !defined(__ANDROID__)
#include <alloca.h>
#include <errno.h>
#include <stddef.h>
@ -252,7 +252,7 @@ main (int argc, char *argv[])
putenv (buf);
#if defined(__linux__) && !defined(__BIONIC__)
#if defined(__linux__) && !defined(__ANDROID__)
set_up_journal (argv[1]);
#endif

View File

@ -22,7 +22,7 @@
#include "gjournal-private.h"
#if defined(__linux__) && !defined(__BIONIC__)
#if defined(__linux__) && !defined(__ANDROID__)
#include <string.h>
#include <sys/socket.h>
#include <sys/un.h>

View File

@ -38,7 +38,7 @@
#include <locale.h>
#include <errno.h>
#if defined(__linux__) && !defined(__BIONIC__)
#if defined(__linux__) && !defined(__ANDROID__)
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/un.h>
@ -68,7 +68,7 @@
#include <syslog.h>
#endif
#if defined(__linux__) && !defined(__BIONIC__)
#if defined(__linux__) && !defined(__ANDROID__)
#include "gjournal-private.h"
#endif
@ -2053,7 +2053,7 @@ G_LOCK_DEFINE_STATIC (syslog_opened);
#endif
#endif
#if defined(__linux__) && !defined(__BIONIC__)
#if defined(__linux__) && !defined(__ANDROID__)
static int journal_fd = -1;
#ifndef SOCK_CLOEXEC
@ -2098,7 +2098,7 @@ open_journal (void)
gboolean
g_log_writer_is_journald (gint output_fd)
{
#if defined(__linux__) && !defined(__BIONIC__)
#if defined(__linux__) && !defined(__ANDROID__)
return _g_fd_is_journal (output_fd);
#else
return FALSE;
@ -2350,7 +2350,7 @@ g_log_writer_syslog (GLogLevelFlags log_level,
}
/* Enable support for the journal if we're on a recent enough Linux */
#if defined(__linux__) && !defined(__BIONIC__) && defined(HAVE_MKOSTEMP) && defined(O_CLOEXEC)
#if defined(__linux__) && !defined(__ANDROID__) && defined(HAVE_MKOSTEMP) && defined(O_CLOEXEC)
#define ENABLE_JOURNAL_SENDV
#endif