Hi,
porting my actual app from linux/gcc to windows xp/mingw gets me very strange behavior I've no explanation for. My hope is that the things I describe in that loose way triggers some feeling of deja-vu in someones head.
Basically my app uses wxwidgets, some boost stuff, pthread and a proprietary lib. It is coded as platform independent as possible. Very little parts of the code are written platform specific, mainly the code to handle runtime loading of plugin dll/so 's.
under win32 I compiled all libraries the app uses myself with the same tool chain as the app.
The windows XP used as development environment lives in a vmware virtual machine. I don't know if thats important in any way, so I better add that information
Under linux the app runs very stable, I really tried hard to crash it without luck.
But what happens under win32? Segfaults! If i backtrace them the trace always seems to end in either a pthread_mutex_lock() or _unlock() operation. I identified 2 places so far this happens (between them many locks/unlocks are done successfully). I tried the last two versions of pthreads for win32, the GC2 und GCE2 versions each time. This didn't change anything.
I am able to eliminate one of the segfaults by just changing a line of code (a silly cout). It does NOT matter if I add that cout or comment it out. Just recompiling with the modified line does the job. How strange is that?!
If you have any idea, no matter how strange it is, I'll try it. I tinkered around the last 3 days and my mind is really empty. As a last option I could try to reinstall/-build everything but I havent a good mind to do so