3d49c90572
GHC: The Glasgow Haskell Compiler. The Glasgow Haskell Compiler is a robust, fully-featured, optimising compiler for the functional programming language Haskell 98 (http://www.haskell.org). GHC compiles Haskell to either native code or C. It implements numerous experimental language extensions to Haskell, including concurrency, a foreign language interface, several type-system extensions, exceptions, and so on. GHC comes with a generational garbage collector, a space and time profiler, and a comprehensive set of libraries. This package provides the 8.10.x release series.
23 lines
825 B
Haskell
23 lines
825 B
Haskell
$NetBSD: patch-libraries_base_System_Environment.hs,v 1.1 2021/02/09 13:16:24 ryoon Exp $
|
|
|
|
Suppress linker warnings about compatibility syscall wrappers by using
|
|
"capi" instead of "ccall".
|
|
|
|
--- libraries/base/System/Environment.hs.orig 2018-02-25 20:02:28.000000000 +0000
|
|
+++ libraries/base/System/Environment.hs
|
|
@@ -1,5 +1,6 @@
|
|
{-# LANGUAGE Safe #-}
|
|
{-# LANGUAGE CPP #-}
|
|
+{-# LANGUAGE CApiFFI #-}
|
|
|
|
-----------------------------------------------------------------------------
|
|
-- |
|
|
@@ -246,7 +247,7 @@ putEnv keyvalue = do
|
|
-- environment.
|
|
throwErrnoIf_ (/= 0) "putenv" (c_putenv s)
|
|
|
|
-foreign import ccall unsafe "putenv" c_putenv :: CString -> IO CInt
|
|
+foreign import capi unsafe "stdlib.h putenv" c_putenv :: CString -> IO CInt
|
|
#endif
|
|
|
|
-- | @unsetEnv name@ removes the specified environment variable from the
|