* Don't use clock_nanosleep on PASE
PASE exports this AIX syscall so autoconf detects it, but using it
will trigger SIGILL (for unimplemented syscall), which emits a LIC
log entry type of 4700-000F.
* Change ifdef guard for clock_nanosleep in threads
It only used clock_nanosleep on Linux, but enable it for all except
PASE. Android used to be guarded against, but the reasoning was
unknown, so @akoeplinger requested to have that guard removed.
Commit migrated from https://github.com/mono/mono/commit/
9ea07610ee4c2879f5d598aa6f34b6df79401047
void
g_usleep (gulong microseconds)
{
-#ifdef HAVE_CLOCK_NANOSLEEP
+#if defined(HAVE_CLOCK_NANOSLEEP) && !defined(__PASE__)
struct timespec target;
/*
* makes very little sense as we can only use nanosleep () to sleep on
* real time.
*/
-#ifdef HAVE_CLOCK_NANOSLEEP
+#if defined(HAVE_CLOCK_NANOSLEEP) && !defined(__PASE__)
struct timespec ts = { 0 };
/*
static void
clock_sleep_ns_abs (guint64 ns_abs)
{
-#ifdef HAVE_CLOCK_NANOSLEEP
+#if defined(HAVE_CLOCK_NANOSLEEP) && !defined(__PASE__)
int ret;
struct timespec then;
} while (1);
} else {
int ret;
-#if defined (__linux__) && !defined(HOST_ANDROID)
+#if defined (HAVE_CLOCK_NANOSLEEP) && !defined(__PASE__)
struct timespec start, target;
/* Use clock_nanosleep () to prevent time drifting problems when nanosleep () is interrupted by signals */