[591] in Pthreads mailing list archive
pthreads under HP-UX 9.05
daemon@ATHENA.MIT.EDU (Mark-Andrew Hartinger)
Mon Mar 10 11:41:50 1997
From: Mark-Andrew Hartinger <hartingm@informatik.tu-muenchen.de>
To: pthreads@MIT.EDU
Date: Mon, 10 Mar 97 17:24:43 MEZ
Cc: proven@MIT.EDU
Hello Mr. Provenzano !
I am using pthreads-1_60_beta6 in a C++ (g++ 2.7.x) context on a HP 9000/720
running HP-UX 09.05. Calls to stdio or stdlib functions provided by
libpthread.a result in the following linker error (g++ option -static):
/bin/ld: Duplicate symbol "__iob", files [...]/libpthread.a(findfp.o) and
/lib/libc.a(data.o)
/bin/ld: Found 1 duplicate symbol(s)
collect2: ld returned 1 exit status
*** Error code 1
This problem occurres under Linux 2.0.X (libc 5.3.12) also. There, a way to
solve it, is to use dynamic linking. Under HP-UX 9.05 this is not possible
(runtime error: illegal instruction).
To reproduce the problem, extend tests/test_stdio_1.c with:
#include <iostream.h>
// ...
main()
{
// ...
cerr << "Hello world !!!" << endl;
// ...
}
Is there a patch for the pthreads library, make make it dymanically work
under HP-UX ? Or am I totally wrong in my doings ? (But, I think this is not
a very unusual way of using pthreads. Someones else could had have the
problem(s) before.)
I am very thankful to any help, as getting a solution to my problem is very
important to my final years project.
Regards,
Mark
----------------------------------------------------------------------
Mark-Andrew Hartinger
Senior Student of Computer Science
Munich University of Technology (TUM)
eMail: Mark-Andrew.Hartinger@Informatik.TU-Muenchen.DE
URL: http://www.informatik.tu-muenchen.de/~hartingm/