From c5c0f2cea9f7b7978170f888f9bb0cf1d33b9561 Mon Sep 17 00:00:00 2001 From: Simon Marlow Date: Thu, 18 May 2006 10:41:51 +0000 Subject: [PATCH] #define _REENTRANT 1 (needed to get the right errno on some OSs) Part 2 of the fix for threaded RTS problems on Solaris and possibly *BSD (Part 1 was the same change in ghc/includes/Rts.h). --- include/HsBase.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/HsBase.h b/include/HsBase.h index 143b29d..682d808 100644 --- a/include/HsBase.h +++ b/include/HsBase.h @@ -20,6 +20,11 @@ #undef PACKAGE_TARNAME #undef PACKAGE_VERSION +/* Needed to get the macro version of errno on some OSs (eg. Solaris). + We must do this, because these libs are only compiled once, but + must work in both single-threaded and multi-threaded programs. */ +#define _REENTRANT 1 + #include "HsFFI.h" #include -- 1.7.10.4