From 8b48a3381c559fe6ee56aac4aeb56a97748eb0e4 Mon Sep 17 00:00:00 2001 From: UnknownShadow200 Date: Sun, 25 Aug 2019 19:51:21 +1000 Subject: [PATCH] Fix linux build --- readme.md | 2 +- src/Logger.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/readme.md b/readme.md index 4f22e259f..41d348c68 100644 --- a/readme.md +++ b/readme.md @@ -61,7 +61,7 @@ I am assuming you used the installer from https://sourceforge.net/projects/mingw I am assuming you used the installer from http://www.mingw.org/ 1. Install MinGW. You need mingw32-base-bin and msys-base-bin packages. 2. Run *msys.bat* in the *C:\MinGW\msys\1.0* folder. -3. Compile with the same flags as **MinGW-w64**, but also add ```-DUNICODE``` +3. Compile with the same flags as under **Cross Compiling for windows**, but use *gcc* instead of *i586-mingw32msvc-gcc* #### Linux diff --git a/src/Logger.c b/src/Logger.c index 8b9b55d2e..372a46414 100644 --- a/src/Logger.c +++ b/src/Logger.c @@ -22,9 +22,8 @@ /* OpenBSD doesn't provide sys/ucontext.h */ #elif defined CC_BUILD_LINUX || defined CC_BUILD_ANDROID /* Need to define this to get REG_ constants */ -#define __USE_GNU +#define _GNU_SOURCE #include -#undef __USE_GNU #include #elif defined CC_BUILD_POSIX #include