cvs commit: fptools/ghc/compiler/cbits rawSystem.c
fptools/ghc/compiler/main SysTools.lhs fptools/ghc/compiler Makefile
fptools/libraries/base/cbits rawSystem.c fptools/libraries/base/System
Cmd.hs fptools/libraries/base/include HsBase.h
Simon Marlow
simonmar@glass.cse.ogi.edu
Thu, 12 Jun 2003 09:06:07 -0700
simonmar 2003/06/12 09:06:07 PDT
Modified files:
ghc/compiler/main SysTools.lhs
ghc/compiler Makefile
libraries/base/cbits rawSystem.c
libraries/base/System Cmd.hs
libraries/base/include HsBase.h
Added files:
ghc/compiler/cbits rawSystem.c
Log:
Change the type of System.Cmd.rawSystem:
rawSystem :: FilePath -> [String] -> IO ExitCode
and implement it properly on both Windows & Unix. The intended
meaning is that the program is executed with *exactly* these
arguments.
We now re-use this rawSystem in the compiler itself (using it directly
from the library if __GLASGOW_HASKELL__ >= 601).
The previous implementation of SysTools.runSomething was broken on
4.08, because Posix.executeFile was broken. However, implementing the
new rawSystem on 4.08 is tricky, because it uses the FFI marshalling
libraries which weren't present on 4.08. Hence, bootstrapping from
4.08 is now not possible (it was already not possible on Windows). It
could be made possible by importing enough FFI marshalling support,
but I won't bother doing that unless/until it is needed.
Revision Changes Path
1.96 +61 -56 fptools/ghc/compiler/main/SysTools.lhs
1.246 +1 -1 fptools/ghc/compiler/Makefile
1.2 +22 -10 fptools/libraries/base/cbits/rawSystem.c
1.12 +39 -9 fptools/libraries/base/System/Cmd.hs
1.22 +6 -2 fptools/libraries/base/include/HsBase.h