Fix compiler errors.

- Some platforms don't expose kill() unless _POSIX_C_SOURCE is defined.
- fork(), execl(), and setsid() need unistd.h on some platforms.

Basically, this fixes some platform-specific build errors.
This commit is contained in:
Geoff Greer 2018-08-05 00:24:42 -07:00
parent 0016f77440
commit 208831aec6
2 changed files with 2 additions and 0 deletions

View file

@ -1,3 +1,4 @@
#define _POSIX_C_SOURCE 200809L
#include <fcntl.h> #include <fcntl.h>
#include <signal.h> #include <signal.h>
#include <stdbool.h> #include <stdbool.h>

View file

@ -3,6 +3,7 @@
#include <assert.h> #include <assert.h>
#include <sys/stat.h> #include <sys/stat.h>
#include <sys/wait.h> #include <sys/wait.h>
#include <unistd.h>
#include <wayland-client.h> #include <wayland-client.h>
#include <wayland-cursor.h> #include <wayland-cursor.h>
#include "log.h" #include "log.h"