logo       

Sponsor
FREE Network Mapping Tool for Microsoft® Office Visio® Professional 2007
Don't map your network by hand - let LANsurveyor Exx press for Microsoft Visio Professional 2007 automatically create network diagrams for you!

Problems using log4cxx built on Solaris 8!: msg#00012

apache.logging.log4cxx.user

Subject: Problems using log4cxx built on Solaris 8!

Hello everybody,
 I have compiled the log4cxx and built the shared library on Solaris 8 platform.
While I link this library dynamically to build my executable, I see the following error:
---------------------------------------------------------------------
Undefined                       first referenced
 symbol                             in file
long __rwstd::InterlockedDecrement(long*)        /home/hatinm/projects/c++_logging/log4cxx-0.9.7/lib/liblogcxx.so
long __rwstd::InterlockedIncrement(long*)          /home/hatinm/projects/c++_logging/log4cxx-0.9.7/lib/liblogcxx.so
long __rwstd::InterlockedExchange(long*,long)   /home/hatinm/projects/c++_logging/log4cxx-0.9.7/lib/liblogcxx.so
ld: fatal: Symbol referencing errors. No output written
----------------------------------------------------------------------

The following is the output of nm -o -C liblogcxx.so | grep Interlocked
---------------------------------------------------------------------
[14131] |000000000000|000000000000|NOTY |GLOB |0    |UNDEF  |long __rwstd::InterlockedDecrement(long*)
                                                       [__1cH__rwstdUInterlockedDecrement6Fpl_l_]
[13326] |000000000000|000000000000|NOTY |GLOB |0    |UNDEF  |long __rwstd::InterlockedExchange(long*,long)
                                                       [__1cH__rwstdTInterlockedExchange6Fpll_l_]
[15089] |000000000000|000000000000|NOTY |GLOB |0    |UNDEF  |long __rwstd::InterlockedIncrement(long*)
                                                       [__1cH__rwstdUInterlockedIncrement6Fpl_l_]
[14430] |000007275110|000000000140|FUNC |GLOB |0    |11     |long log4cxx::helpers::Thread::InterlockedDecrement(volatile lon\

g*)
                                                       [__1cHlog4cxxHhelpersGThreadUInterlockedDecrement6Fpol_l_]
[14672] |000007274730|000000000140|FUNC |GLOB |0    |11     |long log4cxx::helpers::Thread::InterlockedIncrement(volatile lon\

g*)
                                                       [__1cHlog4cxxHhelpersGThreadUInterlockedIncrement6Fpol_l_]
--------------------------------------------------------------------

1) How is the scope for the undefined symbols being resolved to __rwstd:: ??
2) Another thing I notice is that these functions (Interlocked*) occur only in 3 source files: condition.cpp, thread.cpp, objectimpl.cpp.

    The references in the last file objectimpl.cpp are to the functions Thread::Interlocked*. Hence, these are being resolved.

    In the other 2 files, condition.cpp thread.cpp, whatever references exist (barring the definition of the member version of Thread class), they should've

    been EXCLUDED out by the pre-processor (controlled by pre-processor macros like HAVE_MS_THREAD) !!! I have duly defined the macro

    HAVE_PTHREAD.

I would greatly appreciate your suggestions/ ideas on how to resolve this.

Regards,
Hatinder

<Prev in Thread] Current Thread [Next in Thread>
Sponsor
FREE Network Mapping Tool for Microsoft® OfficeVisio Professional 2007
Don't map your network by hand - let LANsurveyor Express for Microsoft Visio Professional 2007
automatically create network diagrams for you!
Google Custom Search

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation

Home | sitemap | advertise | OSDir is an inevitable website. super tiny logo