gnash-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-dev] gnash, bsd, and pthread.h


From: Jim Garrison
Subject: [Gnash-dev] gnash, bsd, and pthread.h
Date: Mon, 20 Feb 2006 18:46:25 -0500
User-agent: Mozilla Thunderbird 1.0.7-1.1.fc4 (X11/20050929)

Hello new list!

Rob told me that my changes that migrate from array to std::vector broke gnash on BSD systems. I couldn't get on to SF's FreeBSD system, and their OpenBSD system doesn't have one of the necessary SDL header files. But the NetBSD system does in fact fail when compiling gnash.

The big issue is that there is not one pthread.h in the include path, but actually three of them:

/usr/include/pthread.h - this seems to be the real NetBSD pthread.h, which is probably what we want.

/usr/pkg/include/pthread.h - this is the pthread-like interface to GNU pth (portable threads). Unfortunately, /usr/pkg/include is added to the include path in JPEG_CFLAGS, LIBXML_CFLAGS, OGG_CFLAGS, and PNG_CFLAGS, and there seems no way around using those libraries.

/usr/pkg/pthreads/include/pthread.h - this is yet another pthread.h, last modified in 1996. Although it is not included as is, pthread.m4 actually adds this path to PTHREAD_CFLAGS. However, libbase/Makefile.am does not add PTHREAD_CFLAGS to the INCLUDES. Even if it did, it would not help anything, and including this file seems to be a mistake with pthread.m4. Where did pthread.m4 come from originally?

Somehow, the top two of these end up being included at the same time, but I haven't figured out how this actually happens. Any thoughts?

Jim





Relevant output:

g++ -DHAVE_CONFIG_H -I. -I. -I.. -I.. -I. -I/usr/pkg/include/libxml2 -I/usr/pkg/include -I/usr/X11R6/include -I.. -Wall -I/usr/pkg/include/SDL -I/usr/pkg/include -I/usr/pkg/include/SDL -I.. -I. -I/usr/pkg/include/libxml2 -I/usr/pkg/include -I/usr/X11R6/include -I.. -g -O2 -MT container.lo -MD -MP -MF .deps/container.Tpo -c container.cpp -fPIC -DPIC -o .libs/container.o
In file included from /usr/include/g++/bits/gthr-default.h:40,
                 from /usr/include/g++/bits/gthr.h:101,
                 from /usr/include/g++/bits/c++io.h:37,
                 from /usr/include/g++/bits/fpos.h:44,
                 from /usr/include/g++/iosfwd:49,
                 from /usr/include/g++/bits/stl_algobase.h:70,
                 from /usr/include/g++/vector:67,
                 from container.h:160,
                 from container.cpp:9:
/usr/pkg/include/pthread.h:285: error: conflicting types for `typedef struct
   pthread_st*pthread_t'
/usr/include/pthread_types.h:71: error: previous declaration as `typedef struct
   __pthread_st*pthread_t'




reply via email to

[Prev in Thread] Current Thread [Next in Thread]