[commit: ghc] master: fix compilation failure on Solaris 11 (91b96e1)

git at git.haskell.org git at git.haskell.org
Tue Mar 29 09:09:28 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/91b96e1ccce6a642d710ce40211e1795d01abf04/ghc

>---------------------------------------------------------------

commit 91b96e1ccce6a642d710ce40211e1795d01abf04
Author: Karel Gardas <karel.gardas at centrum.cz>
Date:   Tue Mar 29 00:06:48 2016 +0200

    fix compilation failure on Solaris 11
    
    Summary:
    Solaris is quite picky about C and POSIX version combination.
    For recent change to C99 we need to switch _XPG6 on which means
    _XOPEN_SOURCE should be defined to 600
    
    Reviewers: austin, bgamari, erikd
    
    Subscribers: thomie
    
    Differential Revision: https://phabricator.haskell.org/D2053


>---------------------------------------------------------------

91b96e1ccce6a642d710ce40211e1795d01abf04
 rts/PosixSource.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/rts/PosixSource.h b/rts/PosixSource.h
index 6659cfe..6246e3e 100644
--- a/rts/PosixSource.h
+++ b/rts/PosixSource.h
@@ -11,7 +11,7 @@
 
 #include <ghcplatform.h>
 
-#if defined(freebsd_HOST_OS) || defined(dragonfly_HOST_OS)
+#if defined(freebsd_HOST_OS) || defined(dragonfly_HOST_OS) || defined(solaris2_HOST_OS)
 #define _POSIX_C_SOURCE 200112L
 #define _XOPEN_SOURCE   600
 #else



More information about the ghc-commits mailing list