summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorJaremy Creechley <creechley@gmail.com>2021-08-12 23:57:29 -0700
committerGitHub <noreply@github.com>2021-08-13 08:57:29 +0200
commit3a1109a53be172a92c63ebc5bdb69c45e78e9ca6 (patch)
treeb5936c7e6ed5d064224148b4ca63e747219ea40d
parent883c04d444e943ba8e3d071a4dfcaca68ab300f9 (diff)
downloadNim-3a1109a53be172a92c63ebc5bdb69c45e78e9ca6.tar.gz
initial fix for compiling Nim on Zephyr RTOS (issue #18684) (#18685)
* initial fix for compiling Nim on Zephyr RTOS (issue  #18684)

Co-authored-by: Jaremy J. Creechley <jaremy.creechley@wavebaselabs.com>
-rw-r--r--lib/nimbase.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/nimbase.h b/lib/nimbase.h
index e480c55fd..a83bd3006 100644
--- a/lib/nimbase.h
+++ b/lib/nimbase.h
@@ -75,7 +75,8 @@ __AVR__
 #endif
 /* ------------------------------------------------------------------------- */
 
-#if defined(__GNUC__)
+#if defined(__GNUC__) && !defined(__ZEPHYR__)
+/* Zephyr does some magic in it's headers that override the GCC stdlib. This breaks that. */
 #  define _GNU_SOURCE 1
 #endif