aboutsummaryrefslogtreecommitdiffhomepage
path: root/System
diff options
context:
space:
mode:
authorGravatar ross <unknown>2003-10-17 16:48:45 +0000
committerGravatar ross <unknown>2003-10-17 16:48:45 +0000
commitaf8f41be147bb67ebedeac337f808c45efb897e1 (patch)
tree1ad8beee51fcc7b4857bdd77df3143ab0f8199b4 /System
parent11b9ffbbc89d4627ea2f378706e6002d60108e43 (diff)
[project @ 2003-10-17 16:48:44 by ross]
Hugs only: add most of the rest of System.Posix (I wonder why SIG_UNBLOCK and SIG_SETMASK are switched in HsBase.h)
Diffstat (limited to 'System')
-rw-r--r--System/Posix/Process.hsc8
1 files changed, 8 insertions, 0 deletions
diff --git a/System/Posix/Process.hsc b/System/Posix/Process.hsc
index 47f951e..428013e 100644
--- a/System/Posix/Process.hsc
+++ b/System/Posix/Process.hsc
@@ -17,7 +17,9 @@ module System.Posix.Process (
-- * Processes
-- ** Forking and executing
+#ifdef __GLASGOW_HASKELL__
forkProcess,
+#endif
executeFile,
-- ** Exiting
@@ -75,6 +77,10 @@ import System.Posix.Types
import System.Posix.Signals
import Control.Monad
+#ifdef __HUGS__
+{-# CBITS HsUnix.c execvpe.c #-}
+#endif
+
-- -----------------------------------------------------------------------------
-- Process environment
@@ -209,6 +215,7 @@ foreign import ccall unsafe "setpriority"
-- -----------------------------------------------------------------------------
-- Forking, execution
+#ifdef __GLASGOW_HASKELL__
{- | 'forkProcess' corresponds to the POSIX @fork@ system call.
The 'IO' action passed as an argument is executed in the child process; no other
threads will be copied to the child process.
@@ -224,6 +231,7 @@ forkProcess action = do
return $ fromIntegral pid
foreign import ccall "forkProcess" forkProcessPrim :: StablePtr (IO ()) -> IO CPid
+#endif /* __GLASGOW_HASKELL__ */
executeFile :: FilePath -- Command
-> Bool -- Search PATH?