Opened 9 years ago
Closed 9 years ago
#48717 closed defect (fixed)
boost @1.59.0: explicit template instantiations don't always get exported
Reported by: | soundbastler@… | Owned by: | ryandesign (Ryan Carsten Schmidt) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.3.3 |
Keywords: | Cc: | jpdevillers@…, devernay (Frédéric Devernay), thesamprice@…, primalbuddhist@…, michaelld (Michael Dickens) | |
Port: | boost |
Description (last modified by ryandesign (Ryan Carsten Schmidt))
---
OS 10.8.5
XCODE 5.1.1
---
sudo port install uhd
Error:
:info:build Undefined symbols for architecture x86_64: :info:build "boost::archive::basic_text_iprimitive<std::istream>::~basic_text_iprimitive()", referenced from: :info:build boost::archive::text_iarchive_impl<boost::archive::text_iarchive>::~text_iarchive_impl() in rpc_client.cpp.o :info:build "boost::archive::basic_text_oprimitive<std::ostream>::~basic_text_oprimitive()", referenced from: :info:build boost::archive::text_oarchive_impl<boost::archive::text_oarchive>::~text_oarchive_impl() in rpc_client.cpp.o :info:build boost::archive::text_oarchive_impl<boost::archive::text_oarchive>::~text_oarchive_impl() in usrprio_rpc_client.cpp.o :info:build ld: symbol(s) not found for architecture x86_64 :info:build clang: error: linker command failed with exit code 1 (use -v to see invocation) :info:build make[2]: *** [lib/libuhd.003.008.dylib] Error 1 :info:build make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_science_uhd/uhd/work/build' :info:build make[1]: *** [lib/CMakeFiles/uhd.dir/all] Error 2 :info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_science_uhd/uhd/work/build' :info:build make: *** [all] Error 2 :info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_science_uhd/uhd/work/build' :info:build Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_science_uhd/uhd/work/build" && /usr/bin/make -j4 -w all VERBOSE=ON :info:build Exit code: 2 :error:build org.macports.build for port uhd returned: command execution failed
Attachments (1)
Change History (19)
Changed 9 years ago by soundbastler@…
comment:1 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Owner: | changed from macports-tickets@… to michaelld@… |
---|
Possibly an incompatibility with boost 1.59.0
comment:2 Changed 9 years ago by michaelld (Michael Dickens)
I saw this when Boost was updated to 1.59.0, too. I'm pretty sure it's an internal inconsistency in Boost, based on the old boost still being around while the new one is compiled. Removing Boost entirely and building from scratch worked for me:
sudo port -f uninstall boost sudo port clean "uhd*" sudo port selfupdate sudo port install uhd
or, whatever works for you with variants for boost, and uhd or uhd-devel plus variants. Or, something like this.
comment:3 Changed 9 years ago by soundbastler@…
systemoperators-macbook-air:~ sysop$ sudo port selfupdate ---> Updating MacPorts base sources using rsync MacPorts base version 2.3.3 installed, MacPorts base version 2.3.3 downloaded. ---> Updating the ports tree ---> MacPorts base is already the latest version
The Problem is: Yesterday I downloaded and installed for the first time xcode + command line tools, then MacPorts 2.3.3 and did nothing else then typing "sudo port install gqrx" - so this _is_ a build from scratch. As you see there are no updates avail. Anyway I tried your fix - but with same result as in Post #1.
I also tried to build uhd-devel with same result.
Any other advise on this?
Cheers, Chris
comment:4 Changed 9 years ago by michaelld (Michael Dickens)
Try building boost from source:
sudo port -f uninstall boost sudo port -s install boost
then clean and try uhd and/or uhd-devel from source again.
comment:5 Changed 9 years ago by soundbastler@…
systemoperators-macbook-air:~ sysop$ sudo port -f uninstall boost Password: ---> Deactivating boost @1.59.0_0+no_single+no_static+python27 ---> Cleaning boost ---> Uninstalling boost @1.59.0_0+no_single+no_static+python27 ---> Cleaning boost systemoperators-macbook-air:~ sysop$ sudo port clean "uhd*" ---> Cleaning uhd ---> Cleaning uhd-devel systemoperators-macbook-air:~ sysop$ sudo port selfupdate ---> Updating MacPorts base sources using rsync MacPorts base version 2.3.3 installed, MacPorts base version 2.3.3 downloaded. ---> Updating the ports tree ---> MacPorts base is already the latest version The ports tree has been updated. To upgrade your installed ports, you should run port upgrade outdated systemoperators-macbook-air:~ sysop$ port upgrade outdated Nothing to upgrade. systemoperators-macbook-air:~ sysop$ sudo port install uhd ---> Computing dependencies for uhd ---> Dependencies to be installed: boost ---> Fetching archive for boost ---> Attempting to fetch boost-1.59.0_1+no_single+no_static+python27.darwin_12.x86_64.tbz2 from http://nue.de.packages.macports.org/macports/packages/boost ---> Attempting to fetch boost-1.59.0_1+no_single+no_static+python27.darwin_12.x86_64.tbz2 from http://lil.fr.packages.macports.org/boost ---> Attempting to fetch boost-1.59.0_1+no_single+no_static+python27.darwin_12.x86_64.tbz2 from http://mse.uk.packages.macports.org/sites/packages.macports.org/boost ---> Fetching distfiles for boost ---> Verifying checksums for boost ---> Extracting boost ---> Applying patches to boost ---> Configuring boost ---> Building boost ---> Staging boost into destroot ---> Installing boost @1.59.0_1+no_single+no_static+python27 ---> Activating boost @1.59.0_1+no_single+no_static+python27 ---> Cleaning boost ---> Fetching archive for uhd ---> Attempting to fetch uhd-3.8.5_1+docs+examples+libusb+manpages+manual+orc+test.darwin_12.x86_64.tbz2 from http://nue.de.packages.macports.org/macports/packages/uhd ---> Attempting to fetch uhd-3.8.5_1+docs+examples+libusb+manpages+manual+orc+test.darwin_12.x86_64.tbz2 from http://lil.fr.packages.macports.org/uhd ---> Attempting to fetch uhd-3.8.5_1+docs+examples+libusb+manpages+manual+orc+test.darwin_12.x86_64.tbz2 from http://mse.uk.packages.macports.org/sites/packages.macports.org/uhd ---> Fetching distfiles for uhd ---> Verifying checksums for uhd ---> Extracting uhd ---> Configuring uhd ---> Building uhd Error: org.macports.build for port uhd returned: command execution failed Please see the log file for port uhd for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_science_uhd/uhd/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port uhd failed
This ends up in an endless loop with the result of post #1.
comment:6 Changed 9 years ago by michaelld (Michael Dickens)
OK; hmmm. So, for my edification can you upload a new logfile that comes after a "clean", and not just the build itself? Sometimes seeing the earlier info can be useful.
Also, what is your OS, Xcode version, and the like?
comment:7 Changed 9 years ago by soundbastler@…
Late but...
OS 10.8.5 XCODE 5.1.1
What do you mean by "after clean" ?
"/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_science_uhd/uhd/main.log" does not exist after typing sudo port clean "uhd*"
How do I generate the logfile you aksed for?
Chris
comment:8 Changed 9 years ago by michaelld (Michael Dickens)
FYI in the future: "clean", meaning:
sudo port clean uhd sudo port install uhd
and, then if the issue happens again then upload the new logfile. In this way, we get the whole log from start to error, not just the error part. Having the whole log sometimes helps us debug issues.
In your particular case our auto-build system ("buildbots") has this issue on 10.8 so I actually have a good logfile to work off of. I'm still not sure what the answer is, but I'll look into it this coming week.
comment:9 Changed 9 years ago by nrasser@…
I'm running into the same issue with uhd and boost. Build of uhd fails with main.log info identical to OP's.
Building boost with "sudo port -s install boost" did not affect the outcome.
OS 10.8.5, XCode 5.1.1
comment:11 Changed 9 years ago by devernay (Frédéric Devernay)
This is a boost/ boost port issue: all template specializations from boost_1_59_0/libs/serialization/src are stripped at link time because they are not exported.
Maybe Boost serialization should be linked without -dead-strip
Homebrew doesn't have this issue (see nm output below)
$ nm /usr/local.bak/lib/libboost_serialization-mt.dylib |fgrep basic_text_iprimitive |c++filt 0000000000004c90 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::load_binary(void*, unsigned long) 00000000000047a0 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::load(signed char&) 00000000000046d0 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::load(char&) 0000000000004870 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::load(unsigned char&) 0000000000004940 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::load(wchar_t&) 0000000000004ba0 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::basic_text_iprimitive(std::__1::basic_istream<char, std::__1::char_traits<char> >&, bool) 0000000000004a10 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::basic_text_iprimitive(std::__1::basic_istream<char, std::__1::char_traits<char> >&, bool) 0000000000004c80 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::~basic_text_iprimitive() 0000000000004bb0 T boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >::~basic_text_iprimitive() 0000000000026740 D typeinfo for boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > > 00000000000210d0 S typeinfo name for boost::archive::basic_text_iprimitive<std::__1::basic_istream<char, std::__1::char_traits<char> > >
comment:15 Changed 9 years ago by devernay (Frédéric Devernay)
I found the problem, and filed a ticket upstream https://svn.boost.org/trac/boost/ticket/11671
comment:16 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | primalbuddhist@… michaelld@… added |
---|---|
Description: | modified (diff) |
Owner: | changed from michaelld@… to ryandesign@… |
Port: | boost added; uhd removed |
Status: | new → assigned |
Summary: | uhd @ 3.8.5_1 Undefined symbols for architecture x86_64 → boost @1.59.0: explicit template instantiations don't always get exported |
comment:17 Changed 9 years ago by michaelld (Michael Dickens)
Should be fixed in r140988. I'm running 10.11 so I can't test on 10.8 right now. Hopefully others can and report back here, success or failure. I'm leaving this ticket open until we hear back successes.
comment:18 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
User reported success by email.
main.log