[Gc] RE: GC7.0alpha9 and mingw

Boehm, Hans hans.boehm at hp.com
Mon May 21 16:53:33 PDT 2007


Thanks.  I'll check in a fix the MINGW test and the GC_need_to_lock
problem.  The latter would probably have occurred with the Microsoft
compiler as well, if I had tried the single-threaded version.

The other warnings may be mingw header issues.  Even after staring at
the code, I don't see what the problem is.  And I think this is all code
that made it through at least one other compiler/platform with no
problems.

Hans

> -----Original Message-----
> From: Romano Paolo Tenca [mailto:rotenca at telvia.it] 
> Sent: Wednesday, May 16, 2007 7:23 AM
> To: Boehm, Hans
> Cc: gc at napali.hpl.hp.com
> Subject: GC7.0alpha9 and mingw
> 
> 
> Compiled under Mingw and gcc 3.2.3 with makefile.direct with 
> no change to the makefile (no GC_THREADS) this is the failure result:
> 
> misc.c: In function `GC_write':
> misc.c:837: `GC_need_to_lock' undeclared (first use in this function)
> misc.c:837: (Each undeclared identifier is reported only once
> misc.c:837: for each function it appears in.)
> make: [misc.o] Error 1 (ignored)
> if_mach.c: In function `main':
> if_mach.c:16: warning: passing arg 2 of `execvp' from 
> incompatible pointer type
> if_not_there.c: In function `main':
> if_not_there.c:31: warning: passing arg 2 of `execvp' from 
> incompatible pointer type
> mark_rts.c: In function `GC_approx_sp':
> mark_rts.c:365: warning: function returns address of local variable
> 
> Instead with the addition of -DGC_THREADS (native win 
> threads) it compiles well (but see below) with this warnings 
> (i think they are
> negligible):
> 
> if_mach.c: In function `main':
> if_mach.c:16: warning: passing arg 2 of `execvp' from 
> incompatible pointer type
> if_not_there.c: In function `main':
> if_not_there.c:31: warning: passing arg 2 of `execvp' from 
> incompatible pointer type
> mark_rts.c: In function `GC_approx_sp':
> mark_rts.c:365: warning: function returns address of local variable
> win32_threads.c: In function `GC_beginthreadex':
> win32_threads.c:1053: warning: assignment from incompatible 
> pointer type
> win32_threads.c:1058: warning: passing arg 3 of 
> `_beginthreadex' from incompatible pointer type
> 
> The only change i did was in win32_threads.c: the line 5
> 
> #if defined( _MINGW_VER )
> 
> had to be changed with
> 
> #if defined( _MINGW_VER ) || defined(__MINGW32__)
> 
> in my Mingw system _MINGW_VER is not defined
> 
> ---
> Romano Paolo Tenca
> 



More information about the Gc mailing list