i'm trying to get a product of ours to work on HP-UX. we are using gcc.
it seems to build fine but:
1) when i link to a libboost_*.a i get unresolved symbols like this:
prompt> g++ -I/home/mgarriss/dev/tp-compiled/include/boost-1_31_0 test.cxx
-L/home/mgarriss/dev/tp-compiled/lib/boost-1_31_0 -lboost_regex-gcc -pthread
/usr/bin/ld: Unsatisfied symbols:
std::allocator<char>::allocate(unsigned long, void const*)(first
referenced in
/home/mgarriss/dev/tp-compiled/lib/boost-1_31_0/libboost_regex-gcc.a(instances.o))
(code)
std::__default_alloc_template<(bool)1, (int)0>::allocate(unsigned
long)(first referenced in
/home/mgarriss/dev/tp-compiled/lib/boost-1_31_0/libboost_regex-gcc.a(instances.o))
(code)
std::allocator<char>::deallocate(char*, unsigned long)(first
referenced in
/home/mgarriss/dev/tp-compiled/lib/boost-1_31_0/libboost_regex-gcc.a(instances.o))
(code)
std::basic_string ::_Rep::_S_create(unsigned long, std::allocator<char> const&)(first
referenced in /home/mgarriss/dev/tp-compiled/lib/boost-1_3
1_0/libboost_regex-gcc.a(instances.o)) (code)
std::__default_alloc_template<(bool)1, (int)0>::deallocate(void*,
unsigned long)(first referenced in
/home/mgarriss/dev/tp-compiled/lib/boost-1_31_0/libboost_regex-gcc.a(instances.o)) (code)
collect2: ld returned 1 exit status
2) when i link to a .sl (which i get by just renaming the .so, not sure
if that's right), i get this after running the executable:
prompt> g++ -I/home/mgarriss/dev/tp-compiled/include/boost-1_31_0
test.cxx -L/home/mgarriss/dev/tp-compiled/lib/boost-1_31_0
-lboost_regex-gcc -pthread
prompt> ./a.out
/usr/lib/dld.sl: Unresolved symbol: _ZNSs4_Rep9_S_createEmRKSaIcE (code)
from /home/mgarriss/dev/tp-compiled/lib/boost-1_31_0/libboost_regex-gcc.sl
ABORT instruction (core dumped)
AH! can anyone offer any hints, leads, or advice?
INFO:
prompt> uname -a
HP-UX unknown B.11.11 U 9000/800 180901557 unlimited-user license
prompt> gcc -v
Reading specs from
/opt/gcc-3.3.2/lib/gcc-lib/hppa2.0w-hp-hpux11.11/3.3.2/specs
Configured with: ../gcc-3.3.2/configure --prefix=/opt/gcc-3.3.2
--disable-nls --disable-libgcj --disable-shared --enable-languages=c,c++
--with-gnu-as --with-gnu-ld --with-as=/usr/local/bin/as
--with-ld=/usr/bin/ld --enable-threads=posix
Thread model: posix
gcc version 3.3.2
Thanks in advance,
Mike
El Tue, 14 Dec 2004 09:22:35 -0700
Michael Garriss
i'm trying to get a product of ours to work on HP-UX. we are using gcc. it seems to build fine but:
1) when i link to a libboost_*.a i get unresolved symbols like this: ... collect2: ld returned 1 exit status
Did you use -lstdc++ when you link?
2) when i link to a .sl (which i get by just renaming the .so, not sure if that's right), i get this after running the executable:
...
AH! can anyone offer any hints, leads, or advice?
Try to do a 'ldd' (/usr/ccs/bin/ldd) on the executable. That will show you the dependencies. We successfully use Boost with gcc in HP-UX, but our gcc is like this: LANG=C gcc -v Reading specs from /opt/gcc-3.3.3/lib/gcc-lib/hppa64-hp-hpux11.11/3.3.3/specs Configured with: /home/jroman/gcc-fuentes/gcc-3.3.3/configure --prefix=/opt/gcc-3.3.3 --with-local-prefix=/usr/local/gcc-3.3.3 --enable-shared --with-gnu-as --with-as=/usr/local/pa20_64/bin/as --with-gnu-ld --with-ld=/usr/local/pa20_64/bin/ld --enable-threads=posix --enable-languages=c,c++ --with-dwarf2 --enable-nls --host=hppa64-hp-hpux11.11 Thread model: posix gcc version 3.3.3 So we use --with-ld=/usr/local/pa20_64/bin/ld. Don't know if that could be your problem. -- Raúl Huertas Díaz TCP Sistemas e Ingenieria rhuertas@tcpsi.es http://www.tcpsi.es Tfno.: 91.406.27.11 ************************************************************************************************************************************************ *La información contenida en este mensaje de correo electrónico es confidencial y puede revestir el carácter de reservada. * *Está dirigida exclusivamente a la persona destinataria. * *El acceso o cualquier uso por parte de cualquier otra persona de este mensaje no están autorizados y pueden ser ilegales.* *Si no es Ud. la persona destinataria, le rogamos que proceda a borrarlo. * *The information in this e-mail is confidential and may be legally privileged. * *It is intended solely for the addressee. * *Access or any use by any other person to this Internet e-mail is not authorised and may be unlawful. * *If you are not the intended recipient, please delete this e-mail. * ************************************************************************************************************************************************
i'm trying to get a product of ours to work on HP-UX. we are using gcc. it seems to build fine but:
1) when i link to a libboost_*.a i get unresolved symbols like this:
prompt> g++ -I/home/mgarriss/dev/tp-compiled/include/boost-1_31_0 test.cxx -L/home/mgarriss/dev/tp-compiled/lib/boost-1_31_0 -lboost_regex-gcc -pthread /usr/bin/ld: Unsatisfied symbols: std::allocator<char>::allocate(unsigned long, void const*)(first referenced in /home/mgarriss/dev/tp-compiled/lib/boost-1_31_0/libboost_regex-gcc.a(instances.o)) prompt> uname -a HP-UX unknown B.11.11 U 9000/800 180901557 unlimited-user license
I've no idea really, but the messages at http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=221587 indicate that you may have a gcc version built for HP-UX 11.10, which apparently can lead to these problems, Don't know if this will help, John.
participants (3)
-
John Maddock
-
Michael Garriss
-
Raul Huertas Diaz