This is the mail archive of the
mailing list for the pthreas-win32 project.
Rob Fanner wrote:
Great! Unless there are any problems with this, it will go into the
this might be a good alternative
if ( ReleaseSemaphore( (*sem)->sem, GREATER_THAN_MAXIMUM_SEM_VALUE,
*sval = value;
Sorry that I've not hacked this into the source and sent you a correct
patch, but I'm still not confident with VC++ builds, and
I'm still a bit clueless as to how to set up a pthreadVCE.lib (which I need)
as opposed to a pthreadVC.lib (the standard
build for the distro's .dsp file).
Re pthreadVCE.lib, if you've built the pthreadVC.lib version
successfully using the .dsp file, you should only need to add the
following compiler flags:-
/GX /TP /D__CLEANUP_CXX
to build pthreadVCE.lib/.dll (and change the names of your output
files of course). I don't recall off-hand what /TP does, but it's
included with the other flags in the Makefile. This is what I use
for the pre-built libs.
If you're using pthreadVCE.lib then you should also be defining
__CLEANUP_CXX for your application build, so that the appropriate
sections of pthread.h are included.
You may be interested in reading Q4 and Q5 in the pthreads-win32 FAQ
or the section "SNAPSHOT 2002-03-02 / Cleanup code default style" at:-
This will explain why the build defaults to pthreadVC. For
additional information, the problems/issues have been discussed on
the mailing list a couple of times, the most recent thread starts at:-