Skip to content

Commit 464d237

Browse files
committed
Fix Android bulid issue
1 parent 1904115 commit 464d237

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

ggml/src/ggml.c

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,14 @@ static int sched_yield (void) {
115115
return 0;
116116
}
117117
#else
118+
119+
#ifndef __USE_GNU
120+
#define __USE_GNU
121+
#endif
122+
118123
#include <pthread.h>
119124
#include <stdatomic.h>
125+
#include <sched.h>
120126

121127
typedef void * thread_ret_t;
122128

@@ -18779,11 +18785,6 @@ static bool __thread_priority(int32_t prio) {
1877918785

1878018786
#else // posix?
1878118787

18782-
#ifndef __USE_GNU
18783-
#define __USE_GNU
18784-
#endif
18785-
#include <sched.h>
18786-
1878718788
static bool __thread_affinity(const bool * mask) {
1878818789
cpu_set_t cpuset;
1878918790
int32_t err;

0 commit comments

Comments
 (0)