Skip to content

Commit

Permalink
Make Linux/Macos discoverable by macros.
Browse files Browse the repository at this point in the history
  • Loading branch information
antirez committed Jul 2, 2020
1 parent 806d412 commit 22cf54f
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions kilo.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,14 @@

#define KILO_VERSION "0.0.1"

#ifdef __APPLE__
#include <AvailabilityMacros.h>
#endif

#ifdef __linux__
#include <features.h>
#endif

#ifdef __GLIBC__
#define _POSIX_C_SOURCE 200809L
#endif
Expand Down

0 comments on commit 22cf54f

Please sign in to comment.