cmake: bootstrap uses cmlibuv.

This commit is contained in:
Jerome Duval
2019-09-08 13:01:40 +02:00
parent 99789357d3
commit 0a3ebfd9df

View File

@@ -129,3 +129,38 @@ index 38fa32b..3754c2f 100755
--
2.21.0
From d69150db539e8d6d50d6c171361880d3e354ac14 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Sat, 7 Sep 2019 23:46:47 +0200
Subject: bootstrap uses cmlibuv
diff --git a/Utilities/cmlibuv/src/unix/core.c b/Utilities/cmlibuv/src/unix/core.c
index 5cb3ad0..7c6fd5e 100644
--- a/Utilities/cmlibuv/src/unix/core.c
+++ b/Utilities/cmlibuv/src/unix/core.c
@@ -1351,7 +1351,9 @@ int uv_os_getpriority(uv_pid_t pid, int* priority) {
return UV_EINVAL;
errno = 0;
+#ifndef __HAIKU__
r = getpriority(PRIO_PROCESS, (int) pid);
+#endif
if (r == -1 && errno != 0)
return UV__ERR(errno);
@@ -1365,8 +1367,10 @@ int uv_os_setpriority(uv_pid_t pid, int priority) {
if (priority < UV_PRIORITY_HIGHEST || priority > UV_PRIORITY_LOW)
return UV_EINVAL;
+#ifndef __HAIKU__
if (setpriority(PRIO_PROCESS, (int) pid, priority) != 0)
return UV__ERR(errno);
+#endif
return 0;
}
--
2.21.0