[PATCH] for MinGW Re: [Libvir] Pthreads error in windows compilation

Atsushi SAKAI sakaia at jp.fujitsu.com
Thu Feb 7 09:13:42 UTC 2008


Hi,

I tested and build virsh.exe successfully on MinGW.
Only src/internal.h is the place which requires to add pthread.h.

c.f
Anyway libintl is need to write on configure.in. for MinGW
Is there any option to write configure script?

c.f.2
Pthread-win32 is seems general one.
http://www.straightrunning.com/XmingNotes/

Thanks
Atsushi SAKAI


"Daniel P. Berrange" <berrange at redhat.com> wrote:

> On Wed, Feb 06, 2008 at 06:26:04PM +0000, Richard W.M. Jones wrote:
> > Atsushi SAKAI wrote:
> > >Hi,
> > >
> > >???Today I recognized.
> > >It would be better to write #include <pthread.h> in hash.h than hash.c.
> > >And compilation works if configure.in changes in MINGW?
> > >Would you apply this patch?
> > 
> > I think actually it's better to push the '#include <pthread.h>' all the 
> > way up into src/internal.h.  It's required in other places, eg. in 
> > src/libvirt.c.
> 
> Yep, I agree - internal.h is the best place.
> 
> Dan.
> -- 
> |=- Red Hat, Engineering, Emerging Technologies, Boston.  +1 978 392 2496 -=|
> |=-           Perl modules: http://search.cpan.org/~danberr/              -=|
> |=-               Projects: http://freshmeat.net/~danielpb/               -=|
> |=-  GnuPG: 7D3B9505   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505  -=| 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: add_pthread_h_mingw.patch
Type: application/octet-stream
Size: 249 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20080207/6c22ded2/attachment-0002.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: configurein_mingw.patch
Type: application/octet-stream
Size: 320 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20080207/6c22ded2/attachment-0003.obj>


More information about the libvir-list mailing list