Re: [Boost-bugs] [Boost C++ Libraries] #9500: Undefined symbols for architecture x86_64

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #9500: Undefined symbols for architecture x86_64
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2013-12-17 17:50:00


#9500: Undefined symbols for architecture x86_64
-------------------------------+---------------------
  Reporter: prasadmaiya@… | Owner:
      Type: Bugs | Status: new
 Milestone: To Be Determined | Component: None
   Version: Boost 1.55.0 | Severity: Problem
Resolution: | Keywords:
-------------------------------+---------------------

Comment (by anonymous):

 OS : MAC OS X 10.9 (Mavericks)
 Compiler : MacPorts gcc47 4.7.3_3
 Boost version : 1.55 ( BOOST_LIB_VERSION "1_55")

 I installed boost using macports:
 sudo port install boost +universal

 $ ar -tv libboost_thread-mt.a
 rw-r--r-- 502/501 21776 Dec 1 22:44 2013 __.SYMDEF
 rw-r--r-- 502/80 925520 Dec 1 22:44 2013 thread.o
 rw-r--r-- 502/80 18248 Dec 1 22:44 2013 once.o
 rw-r--r-- 502/80 51216 Dec 1 22:44 2013 future.o

 $ nm -a once.o
 0000000000003168 s EH_frame0
 0000000000003080 s GCC_except_table0
 00000000000030cc s GCC_except_table1
 0000000000003118 s GCC_except_table2
              U __Unwind_Resume
 0000000000000000 T
 __ZN5boost13thread_detail17enter_once_regionERNS_9once_flagE
 0000000000003188 S
 __ZN5boost13thread_detail17enter_once_regionERNS_9once_flagE.eh
 0000000000000130 T
 __ZN5boost13thread_detail18commit_once_regionERNS_9once_flagE
 00000000000031c0 S
 __ZN5boost13thread_detail18commit_once_regionERNS_9once_flagE.eh
 00000000000001a0 T
 __ZN5boost13thread_detail20rollback_once_regionERNS_9once_flagE
 00000000000031f0 S
 __ZN5boost13thread_detail20rollback_once_regionERNS_9once_flagE.eh
 0000000000003010 d __ZN5boost13thread_detailL10once_mutexE
 0000000000003050 d __ZN5boost13thread_detailL7once_cvE
              U __ZN5boost7atomics6detail8lockpool12get_lock_forEPVKv
              U __ZSt9terminatev
              U ___gxx_personality_v0
              U _pthread_cond_broadcast
              U _pthread_cond_wait
              U _pthread_mutex_lock
              U _pthread_mutex_unlock

 One can notice the line "U
 __ZN5boost7atomics6detail8lockpool12get_lock_forEPVKv"

 indicating get_lock_for is not defined. This is causing the issue.

 How to get rid of this error?

 I am using cmake and the following line is the verbose output of the make.

 /opt/local/bin/g++ -fPIC -m64 -arch x86_64 -Wall -dynamiclib
 -L/opt/local/lib <all my .o files> -L/opt/local/lib/libboost_thread-mt.a
 â€¦..

 This is resulting in the error.

 But the main concern is the undefined symbols after installing boost.

 why libbbost_thread-mt.a has undefined symbol of get_lock_for.

 Is there any other way/variant of boost which I need to install through
 macports to get rid of this error?

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/9500#comment:2>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:15 UTC