From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,aa3e315093cfd4bf,start X-Google-Attributes: gidfee84,public From: tom444792@my-dejanews.com Subject: Shared + stdcxx + no_archive = unresolved Date: 1998/11/19 Message-ID: <73233n$3c0$1@nnrp1.dejanews.com>#1/1 X-Deja-AN: 413623138 X-Http-Proxy: 1.0 x13.dejanews.com:80 (Squid/1.1.22) for client 142.39.200.51 Organization: Deja News - The Leader in Internet Discussion X-Article-Creation-Date: Thu Nov 19 20:52:29 1998 GMT Newsgroups: comp.unix.osf.osf1 X-Http-User-Agent: Mozilla/4.5 [en] (WinNT; I) Trying to create a shared library with some C++ code compiled with the new compiler in the default (-std_ansi) mode. A) With "ld -shared -no_archive [objects] -lots -lcxx -lc -lm -lc " I get ld: Warning: Unresolved: __stdnw__XUl __nwa__XUl __dla__XPv --------------------------------------- B) With "cxx -shared -no_archive ... " I get ld: Can't locate file for: -lcxxstd --------------------------------------- Case (A) occurs because the new C++ generates calls to the ANSI new operator and the cxxstd library isn't included in the ld line. --------------------------------------- Case (B) occurs because libcxxstd.so doesn't exist, only the static /usr/ccs/lib/cmplrs/cxx/libcxxstd.a exists. --------------------------------------- Now my questions: - should I remove the -no_archive flags? The Digital Unix programmer's guide (section 4.5) seems to indicate I should keep it. This is probably to avoid having 2 instances of the same function. - should I just create my own libcxxstd.so and put it in /usr/shlib ? Why wasn't this library included with the compiler in the first place? - should I just avoid ANSI new() and new[]() (by using the cxx options -nostdnew and -noglobal_array_new) ? -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own