MSYS build - stage 2 problem
Gour
gour at mail.inet.hr
Thu Mar 18 17:22:58 EST 2004
Simon Peyton-Jones (simonpj at microsoft.com) wrote:
> Then 'make'. And it successfully built the entire tree. No problem
> with hsc2hs.
Here is the result with latest 6.2.1 binary and yesterday's CVS code.
Earleir I reported that I get the same error with hsc2hs and I did a slight
change in hsc2hs' Main.hs, namely:
l.812:
#if defined(mingw32_HOST_OS)
subst a b ls = map (\ x -> if x == a then b else x) ls
unDosifyPath xs = subst '\\' '/' xs
-- fix for msys build
-- dosifyPath xs = subst '/' '\\' xs
dosifyPath xs = xs
In that way, when hsc2hs is invoked I get:
------------------------------------------------------------------------
../../ghc/utils/hsc2hs/hsc2hs-inplace -Iinclude -I../../ghc/includes -Icbits/regex -I. System/CPUTime.hsc
Executing: c:/MinGW/bin/gcc -c -mno-cygwin -D__GLASGOW_HASKELL__=602 -Ic:/ghc/fptools/ghc/includes -Iinclude -I../../ghc/includes -Icbits/regex -I. System/CPUTime_hsc_make.c -o System/CPUTime_hsc_make.o
Executing: c:/MinGW/bin/gcc System/CPUTime_hsc_make.o -o System/CPUTime_hsc_make.exe
Fail: System/CPUTime_hsc_make.o: removeFile: does not exist (No such file or directory)
As you can see, now there is correct parameter, i.e. System/CPUTime.hsc
However, closer look at the process (after manually creating
CPUTime_hsc_make.c) reveals the problem:
unknown at GAURA-GOUR /ghc/fptools/libraries/base
$ ../../ghc/utils/hsc2hs/hsc2hs -v -Iinclude -I../../ghc/includes -Icbits/regex
-I. System/CPUTime.hsc
Executing: ghc -c -Iinclude -I../../ghc/includes -Icbits/regex -I. System/CPUTime_hsc_make.c -o System/CPUTime_hsc_make.o
CPUTime.hsc: In function `main':
CPUTime.hsc:141: warning: implicit declaration of function `hsc_line'
CPUTime.hsc:92: warning: implicit declaration of function `hsc_const'
CPUTime.hsc:106: warning: implicit declaration of function `hsc_peek'
CPUTime.hsc:106: parse error before "FILETIME"
CPUTime.hsc:107: parse error before "FILETIME"
Executing: ghc System/CPUTime_hsc_make.o -o System/CPUTime_hsc_make.exe
gcc: System/CPUTime_hsc_make.o: No such file or directory
Fail: System/CPUTime_hsc_make.o: removeFile: does not exist (No such file or directory)
Similar thing when invoking next *.hsc:
unknown at GAURA-GOUR /ghc/fptools/libraries/base
$ c:/MinGW/bin/gcc -c -mno-cygwin -D__GLASGOW_HASKELL__=602 -Ic:/ghc/fptools/gh
c/includes -Iinclude -I../../ghc/includes -Icbits/regex -I. System/Posix/Signal
s_hsc_make.c -o System/Posix/Signals_hsc_make.o
In file included from Signals.hsc:90:
c:/ghc/fptools/ghc/includes/Signals.h:19: error: parse error before "StgStablePtr"
Signals.hsc: In function `main':
Signals.hsc:125: error: `stdout' undeclared (first use in this function)
Signals.hsc:125: error: (Each undeclared identifier is reported only once
Signals.hsc:125: error: for each function it appears in.)
What is this?
Is it a step forward or backward?
Sincerely,
Gour
--
Gour
gour at mail.inet.hr
Registered Linux User #278493
More information about the Cvs-ghc
mailing list