#35118 closed defect (fixed)
mongodb: incompatible with boost >= 1.50.0
Reported by: | hapaguy (Brian Kurt Fujikawa) | Owned by: | ryandesign (Ryan Carsten Schmidt) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.1.1 |
Keywords: | Cc: | jeremy.benoist@…, teemu.ikonen@…, k3house@…, prinzdezibel@…, nicolas.jessel@…, aguynamedryan+macports@…, srogers (Steve Rogers), m@…, dyoung155@…, sommertm@…, RonnieRocket147, heapifyman@…, hobbut@…, robertread@…, macports@…, brandon@…, smitty1e@…, george@…, takashi.obara@…, francisdb@…, kinergy@…, vkuznet (Valentin Kuznetsov), dave@…, jpr5@…, lucian303@…, m.swain@…, evandrix (Lee Wei Yeong), macports@…, jendave@…, chad@…, jcvernaleo (John C. Vernaleo), m99@… | |
Port: | mongodb |
Description
OS X 10.7.4, Xcode 4.3.3, I had installed mongodb a few weeks ago and it was running without problems. After performing a recent macports update:
$sudo port -v selfupdate;sudo port -sv upgrade outdated;
mongodb started to fail with the following error:
$ port installed |grep mongodb mongodb @2.0.6_0 (active) $ port installed |grep boost boost @1.50.0_0 (active) $ mongo dyld: Symbol not found: __ZNK5boost15program_options16validation_error4whatEv Referenced from: /opt/local/bin/mongo Expected in: /opt/local/lib/libboost_program_options-mt.dylib in /opt/local/bin/mongo
A clean re-install of mongodb also now fails:
$ sudo port uninstall mongodb $ sudo port clean --all mongodb $ sudo port -sv install mongodb ---> Computing dependencies for mongodb. ---> Fetching distfiles for mongodb ---> mongodb-src-r2.0.6.tar.gz doesn't seem to exist in /opt/local/var/macports/distfiles/mongodb ---> Attempting to fetch mongodb-src-r2.0.6.tar.gz from http://distfiles.macports.org/mongodb % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2903k 100 2903k 0 0 1369k 0 0:00:02 0:00:02 --:--:-- 1655k ---> Verifying checksum(s) for mongodb ---> Checksumming mongodb-src-r2.0.6.tar.gz ---> Extracting mongodb ---> Extracting mongodb-src-r2.0.6.tar.gz ---> Applying patches to mongodb ---> Applying patch-SConstruct.diff patching file SConstruct ---> Applying patch-distsrc-client-SConstruct.diff patching file distsrc/client/SConstruct ---> Applying patch-util-compress.cpp.diff patching file util/compress.cpp ---> Configuring mongodb ---> Building mongodb scons: Reading SConscript files ... scons version: 2.0.1 python version: 2 7 3 'final' 0 using system version of: pcre using system version of: sm using system version of: snappy Checking whether the C++ compiler worksyes Checking for C library stdc++... yes Checking for C++ header file boost/filesystem/operations.hpp... yes Checking for C library boost_system-mt... yes Checking for C library boost_thread-mt... yes Checking for C library boost_filesystem-mt... yes Checking for C library boost_program_options-mt... yes Checking for C++ header file execinfo.h... yes Checking for C library pcap... yes Checking whether the C++ compiler worksyes Checking for C++ header file boost/filesystem/operations.hpp... yes Checking for C library boost_system-mt... yes Checking for C library boost_thread-mt... yes Checking for C library boost_filesystem-mt... yes Checking for C library boost_program_options-mt... yes Checking for C++ header file execinfo.h... yes Checking for C library pcap... yes scons: done reading SConscript files. scons: Building targets ... /usr/bin/clang++ -o pch.o -c -arch x86_64 -Wnon-virtual-dtor -I/opt/local/include/js -fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch -O3 -D_SCONS -DMONGO_EXPOSE_MACROS -D_FILE_OFFSET_BITS=64 -DXP_UNIX -I. -I/opt/local/include pch.cpp clang: warning: argument unused during compilation: '-ggdb' /usr/bin/clang++ -o buildinfo.o -c -arch x86_64 -Wnon-virtual-dtor -I/opt/local/include/js -fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch -O3 -D_SCONS -DMONGO_EXPOSE_MACROS -D_FILE_OFFSET_BITS=64 -DXP_UNIX -I. -I/opt/local/include buildinfo.cpp clang: warning: argument unused during compilation: '-ggdb' In file included from pch.cpp:18: In file included from ./pch.h:83: In file included from /opt/local/include/boost/filesystem/convenience.hpp:22: In file included from /opt/local/include/boost/filesystem/operations.hpp:24: /opt/local/include/boost/filesystem/config.hpp:16:5: error: #error Compiling Filesystem version 3 file with BOOST_FILESYSTEM_VERSION defined != 3 In file included from buildinfo.cpp:1: In file included from ./pch.h:83: In file included from /opt/local/include/boost/filesystem/convenience.hpp:22: In file included from /opt/local/include/boost/filesystem/operations.hpp:24: /opt/local/include/boost/filesystem/config.hpp:16:5: error: #error Compiling Filesystem version 3 file with BOOST_FILESYSTEM_VERSION defined != 3 # error Compiling Filesystem version 3 file with BOOST_FILESYSTEM_VERSION defined != 3 ^ # error Compiling Filesystem version 3 file with BOOST_FILESYSTEM_VERSION defined != 3 ^ In file included from pch.cpp:18: In file included from ./pch.h:161: In file included from ./util/goodies.h:22: ./util/concurrency/mutex.h:32:38: error: no member named 'TIME_UTC' in namespace 'boost'; did you mean 'TIME_UTC_'? boost::xtime_get(&xt, boost::TIME_UTC); ~~~~~~~^~~~~~~~ TIME_UTC_ /opt/local/include/boost/thread/xtime.hpp:23:5: note: 'TIME_UTC_' declared here TIME_UTC_=1 ^ In file included from buildinfo.cpp:1: In file included from ./pch.h:161: In file included from ./util/goodies.h:22: ./util/concurrency/mutex.h:32:38: error: no member named 'TIME_UTC' in namespace 'boost'; did you mean 'TIME_UTC_'? boost::xtime_get(&xt, boost::TIME_UTC); ~~~~~~~^~~~~~~~ TIME_UTC_ /opt/local/include/boost/thread/xtime.hpp:23:5: note: 'TIME_UTC_' declared here TIME_UTC_=1 ^ 2 errors generated. 2 errors generated. scons: *** [buildinfo.o] Error 1 scons: *** [pch.o] Error 1 scons: building terminated because of errors. Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_databases_mongodb/mongodb/work/mongodb-src-r2.0.6" && scons -j2 all mongobridge mongosniff --cxx=/usr/bin/clang++ --full --use-system-all --usesm Exit code: 2 Error: org.macports.build for port mongodb returned: command execution failed Warning: targets not executed for mongodb: org.macports.activate org.macports.build org.macports.destroot org.macports.install Please see the log file for port mongodb for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_databases_mongodb/mongodb/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port mongodb failed
Attachments (1)
Change History (53)
Changed 12 years ago by hapaguy (Brian Kurt Fujikawa)
Attachment: | mongodb.log added |
---|
comment:3 follow-up: 12 Changed 12 years ago by teemu.ikonen@…
For anybody who lands here from Google searching for solution, quick remedy is to downgrade Boost.
$ sudo port activate boost @1.49.0_0 ---> Computing dependencies for boost ---> Deactivating boost @1.50.0_0 ---> Cleaning boost ---> Activating boost @1.49.0_0 ---> Cleaning boost $ mongo MongoDB shell version: 2.0.5 connecting to: test
comment:4 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | brian.fujikawa@… removed |
---|---|
Owner: | changed from macports-tickets@… to ryandesign@… |
You should Cc the maintainer of a port so he becomes aware of your ticket...
You should also report such non-MacPorts-specific problems directly to the developers in the mongodb bug tracker.
comment:6 Changed 12 years ago by Liontooth (David Liontooth)
Looks like a problem in boost --
$ cclive -F http://www.youtube.com/watch?v=Q3Kvu6Kgp88 dyld: Symbol not found: __ZNK5boost15program_options16validation_error4whatEv Referenced from: /opt/local/bin/cclive Expected in: /opt/local/lib/libboost_program_options-mt.dylib in /opt/local/bin/cclive Trace/BPT trap: 5
comment:7 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Boost frequently changes its API in incompatible ways. Unless you have evidence that this change in boost was unintentional and will be reverted in the next version of boost, you should report the problem to the developers of each affected program so the affected programs can be fixed to be compatible with the newer boost.
comment:8 Changed 12 years ago by ecronin (Eric Cronin)
Boost removed the long (in boost release terms) deprecated version 2 of Boost::Filesystem in the 1.50 release but mongo is still using it. There is a ticket in mongo's tracker to update to using version 3 but it is still open. Until that happens unless there is a way to disable the parts of mongo requiring boost::filesystem the only possible fix is to install an older boost.
comment:9 Changed 12 years ago by ecronin (Eric Cronin)
https://jira.mongodb.org/browse/SERVER-4314 is the ticket "mongo won't build with boost 1.50" tickets are being marked as dups of if you want to track progress
comment:11 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | nicolas.jessel@… added |
---|
Has duplicate #35174.
comment:12 Changed 12 years ago by andreas@…
If you are lacking the old port version you have to install it:
$ svn co -r 93341 'http://svn.macports.org/repository/macports/trunk/dports/devel/boost/' A boost/files A boost/files/patch-boost-foreach.diff A boost/files/patch-thread_visibility.diff A boost/files/patch-libs-mpi-build-Jamfile.v2.diff A boost/files/patch-tools-build-v2-tools-python-2.jam.diff A boost/files/patch-tools-build-v2-tools-python.jam.diff A boost/files/patch-bootstrap.sh.diff A boost/files/patch-tools_build_v2_engine_src_build.jam.diff A boost/files/patch-libs-python-src-converter-builtin_converters.cpp A boost/files/patch-tools_build_v2_engine_src_build.sh.diff A boost/Portfile Checked out revision 93341. $ cd boost $ sudo port install ---> Computing dependencies for boost ---> Fetching archive for boost ---> Attempting to fetch boost-1.49.0_0.darwin_10.x86_64.tbz2 from http://packages.macports.org/boost ---> Attempting to fetch boost-1.49.0_0.darwin_10.x86_64.tbz2.rmd160 from http://packages.macports.org/boost ---> Installing boost @1.49.0_0 ---> Deactivating boost @1.50.0_0 ---> Cleaning boost ---> Activating boost @1.49.0_0 ---> Cleaning boost
comment:13 Changed 12 years ago by aguynamedryan+macports@…
Cc: | aguynamedryan+macports@… added |
---|
Cc Me!
comment:33 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | kinergy@… vkuznet@… added |
---|
Has duplicate #35726. In r96549 I made the port detect too-new versions of boost and print an error message explaining to the user how to downgrade boost. In r97033 I expanded that message to include instructions on how to install mongodb without upgrading dependencies (so that boost doesn't get re-upgraded to an incompatible version).
comment:34 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Summary: | mongodb @2.0.6_0 broken after boost @1.50.0_0 update → mongodb: incompatible with boost >= 1.50.0 |
---|
Replying to francisdb@…:
thanks, so where is the bug/improvement ticket to make this process more user-friendly?
I apologize that this process is a bit involved right now, but I hope that it is only a short-term problem. There are no plans to modify MacPorts to make it easier to install older version of ports; that would be a major rearchitecting of MacPorts. The correct long-term solution is to fix mongodb so that it works with newer versions of boost. It is the responsibility of the developers of mongodb to do this. When they do so, we will update the mongodb port to include this fix. You can help encourage the developers of mongodb to fix this problem by voting on the issue in their issue tracker.
comment:35 Changed 12 years ago by francisdb@…
for reference, this is how I removed boost 1.5 and reverted to 1.49
svn co -r 93341 http://svn.macports.org/repository/macports/trunk/dports/devel/boost cd boost/ sudo port install sudo port -n install mongodb
comment:38 follow-up: 39 Changed 12 years ago by lucian303@…
I'm getting this even though files are 0777 permission. Tried using sudo and directly as root. Makes no sense. No additional info in the log either.
/Desktop/boost$ sudo port install ---> Computing dependencies for boost could not read "/Users/me/Desktop/boost/Portfile": permission denied Please see the log file for port boost for details: /opt/local/var/macports/logs/_Users_me_Desktop_boost/boost/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port boost failed
Log:
:msg:main ---> Computing dependencies for boost:info:main .:debug:main boost has no conflicts :debug:main Searching for dependency: zlib :debug:main Found Dependency: receipt exists for zlib :debug:main Searching for dependency: expat :debug:main Found Dependency: receipt exists for expat :debug:main Searching for dependency: bzip2 :debug:main Found Dependency: receipt exists for bzip2 :debug:main Searching for dependency: libiconv :debug:main Found Dependency: receipt exists for libiconv :debug:main Searching for dependency: icu :debug:main Found Dependency: receipt exists for icu :msg:main :debug:main Executing org.macports.main (boost) :debug:main changing euid/egid - current euid: 0 - current egid: 0 :debug:main egid changed to: 501 :debug:main euid changed to: 502 :info:main Warning: targets not executed for boost: org.macports.activate org.macports.archivefetch org.macports.fetch org.macports.checksum org.macports.extract org.macports.patch org.macports.configure org.macports.build org.macports.destroot org.macports.install :notice:main Please see the log file for port boost for details: /opt/local/var/macports/logs/_Users_me_Desktop_boost/boost/main.log
comment:39 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | lucian303@… added |
---|
Replying to lucian303@…:
I'm getting this even though files are 0777 permission.
Not only must the Portfile be readable, but every directory leading up to it, including in your case /Users/me, must also have execute permission for the macports user.
comment:48 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:49 Changed 12 years ago by heapifyman@…
After this issue has been fixed I tried to upgrade mongodb to the latest version but I get a build error.
I uninstalled boost befor upgrading as I assumed that mongodb port now comes with its own boost version, right?
Both upgrade and complete uninstall and re-install of mongodb failed. See error message below.
I'm still using Mac OS X 10.5 (I know it's ancient...). Is Leopard not supported anymore?
error message in log file:
:info:build /usr/bin/g++-4.0 -o build/darwin/cc__usr_bin_gcc-4.0/cxx__usr_bin_g++-4.0/extralib_pcre_pcrecpp_js_snappy/use-system-pcre/use-system-sm/use-system-snappy/mongo/platform/atomic_word_test.o -c -Wnon-virtual-dtor -Woverloaded-virtual -arch i386 -fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch -O3 -DBOOST_ALL_NO_LIB -D_SCONS -DMONGO_EXPOSE_MACROS -DSUPPORT_UTF8 -D_FILE_OFFSET_BITS=64 -DJS_C_STRINGS_ARE_UTF8 -DMONGO_HAVE_HEADER_UNISTD_H -DMONGO_HAVE_EXECINFO_BACKTRACE -DXP_UNIX -Ibuild/darwin/cc__usr_bin_gcc-4.0/cxx__usr_bin_g++-4.0/extralib_pcre_pcrecpp_js_snappy/use-system-pcre/use-system-sm/use-system-snappy/third_party/boost -Isrc/third_party/boost -Ibuild/darwin/cc__usr_bin_gcc-4.0/cxx__usr_bin_g++-4.0/extralib_pcre_pcrecpp_js_snappy/use-system-pcre/use-system-sm/use-system-snappy -Isrc -Ibuild/darwin/cc__usr_bin_gcc-4.0/cxx__usr_bin_g++-4.0/extralib_pcre_pcrecpp_js_snappy/use-system-pcre/use-system-sm/use-system-snappy/mongo -Isrc/mongo -I/opt/local/include -I/opt/local/include/js src/mongo/platform/atomic_word_test.cpp :info:build /var/tmp//cchCLoXM.s:3481:invalid character '%' in mnemonic :info:build /var/tmp//cchCLoXM.s:3650:invalid character '%' in mnemonic :info:build /var/tmp//cchCLoXM.s:3824:invalid character '%' in mnemonic :info:build /var/tmp//cchCLoXM.s:3999:invalid character '%' in mnemonic :info:build /var/tmp//cchCLoXM.s:7780:invalid character '%' in mnemonic :info:build scons: *** [build/darwin/cc__usr_bin_gcc-4.0/cxx__usr_bin_g++-4.0/extralib_pcre_pcrecpp_js_snappy/use-system-pcre/use-system-sm/use-system-snappy/mongo/platform/atomic_word_test.o] Error 1 :info:build scons: building terminated because of errors. :info:build Command failed: cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_databases_mongodb/mongodb/work/mongodb-src-r2.2.0" && /opt/local/bin/scons -j2 all mongobridge mongosniff --cc=/usr/bin/gcc-4.0 --cxx=/usr/bin/g++-4.0 --full --use-system-pcre --use-system-sm --use-system-snappy --extralib=pcre,pcrecpp,js,snappy :info:build Exit code: 2 :error:build org.macports.build for port mongodb returned: command execution failed :debug:build Error code: CHILDSTATUS 41904 2 :debug:build Backtrace: command execution failed while executing "system -nice 0 $fullcmdstring" ("eval" body line 1) invoked from within "eval system $notty $nice \$fullcmdstring" invoked from within "command_exec build" (procedure "portbuild::build_main" line 8) invoked from within "$procedure $targetname" :info:build Warning: targets not executed for mongodb: org.macports.activate org.macports.build org.macports.destroot org.macports.install :notice:build Please see the log file for port mongodb for details: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_databases_mongodb/mongodb/main.log
comment:50 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
That's a new problem; please file a new ticket.
comment:52 Changed 12 years ago by gabipetrovay (Gabriel Petrovay)
Cc: | gabipetrovay@… removed |
---|
Cc Me!
mongodb build log