私はここに私のコードを持っています:
#define _GNU_SOURCE
#include "lib-ult.h"
#include <stdio.h>
#include <stdlib.h>
#include <ucontext.h>
#include <semaphore.h>
#define TRUE 1
#define FALSE 0
#define FAILURE -1
typedef struct Node {
ucontext_t* context;
int priority;
struct Node* next;
struct Node* prev;
} Node;
int STACK_SIZE = 16384;
sem_t queueLock;
sem_t threadsLock;
そして、プロジェクトをビルドしようとするとError 1 error C1083: Cannot open include file: 'ucontext.h': No such file or directory
(およびsemaphore.hでも)得られます。
どうしてこれなの?どうすれば修正できますか?Windows マシンを使用しているという事実と関係がありますか?
ありがとうございました!