Hello! I just installed the latest unstable version of Debian on Saturday and am either doing something wrong or I have found a bug. On top of this, I have followed the mini-howto for upgrading from libc5 to libc6 and installed all of the suggested packages.
I've narrowed the problem down to compiling the following code with g++: #include <stdio.h> #include <unistd.h> #include <pthread.h> void dummy_function() { pthread_mutexattr_t mutexattr; pthread_mutexattr_init(&mutexattr); } int main() { int childpid; childpid = fork(); printf("After fork.. childpid = %d\n", childpid); return 0; } Now, normally this should run with the following expected output: After fork.. childpid = 9909 After fork.. childpid = 0 But, when I run it I only get After fork.. childpid = 9909 >From this, it is obvious that the child process is not actually running and the child dumps a core file. I've been compiling this as follows: g++ -c file.c g++ -o file file.o -lpthread Now, my understanding was that pthread was supposed to be for libc5, but, it doesn't seem to compile at all if I don't include this. I played a little more with this and have found that the following does work: gcc -o file file.o -lpthread -lg++ but, the instant I add in: gcc -o file file.o -lpthread -lg++ -lstdc++ (which is what the g++ expands to) and then the same problem occurs. Any ideas? I tried adding the -D_REENTRANT option as well as suggested by the pthreads FAQ but still no success. And yes, my actual code is C++ (though this snipit isn't) so compiling it without the g++ and stdc++ libraries must be done. Oh, and I should mention some of my current configuration: Linux 2.0.29 libc6 2.0.5c-0.1 libc6-dev 2.0.5c-0.1 libg++272 2.7.2.8-0.1 ldso 1.9.6-2 libc5 5.4.33-7 libreadlineg 2.1-7 libreadline2 2.1-7 Any help or suggestions would be appreciated because otherwise I'm stuck and can't continue on with my software development. Cheers! Richard.. --------------------------------------------------------------------- Richard Dansereau Email: [EMAIL PROTECTED] Home page: http://pobox.com/~rdanse Electrical and Computer Engineering - University of Manitoba - Canada --------------------------------------------------------------------- -- TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to [EMAIL PROTECTED] . Trouble? e-mail to [EMAIL PROTECTED] .