logo       
Google Custom Search
    AddThis Social Bookmark Button
-->

Re: cvs commit:fptools/libraries/base/SystemCmd.hsfptools/ghc/compiler/main: msg#00167

Subject: Re: cvs commit:fptools/libraries/base/SystemCmd.hsfptools/ghc/compiler/mainSysTools.lhs
OK, I'll package up the release whenever it's deemed to be done.

--sigbjorn

----- Original Message ----- 
From: "Simon Marlow" <simonmar@xxxxxxxxxxxxx>
To: "Sigbjorn Finne" <sof@xxxxxxxxxx>
Cc: <cvs-ghc@xxxxxxxxxxx>
Sent: Monday, March 15, 2004 08:40
Subject: RE: cvs
commit:fptools/libraries/base/SystemCmd.hsfptools/ghc/compiler/mainSysTools.
lhs



> > > I'm getting my Win32 build of 6.2.1 up and running so I
> can test this.
> >
> > Indeed, after this change rawSystem on Win32 has bugs.  Strangely
> > CreateProcess() does magically cope with spaces in the
> command name even
> > if it isn't quoted, but gets confused (obviously) if there's an
> > executable with the same basename as one of the directory
> components in
> > the path.
> >
> > So, what goes wrong if the command name is quoted?  Seems
> to work fine
> > here.
> >
>
> I've run into problems with quoting under Win9x in the past (different
> project),
> which lead me to mistrust the docs; no quotes + an explicit
> ".exe" extension
> is
> what I ended up with.
>
> As is, (re-)introducing the use of command name quoting in
> ghc/compiler/ would be  fatal.

This bug:

Failed: C:\ghc\ghc 6.2.1\gcc -B"C:\ghc\ghc 6.2.1\gcc-lib/" -I. -I. -c
C:\DOCUME~1\peter\LOCALS~1\Temp\ghc536.s -o t.orawSystem: does not exist
(No such file or directory)

happens because GHC tries to split the command name into pieces with
toArgs.  The right way to fix this is to not lump command names and
arguments together in a string so that we have to unpick them later on;
so I've made that change to SysTool.lhs (attached).  I've tested here as
much as I can, and it seems to work.  But I don't have a Win98-ish
machine, and I think there might be a problem with the --mk-dll option
but that needs to be tested in a real installation.

Sorry to make more work, but I think it's worth investing a little time
in fixing this properly, given the amount of grief it's given us in the
past.  I'm holding up the release for this now.

Cheers,
Simon


<Prev in Thread] Current Thread [Next in Thread>