#8078 closed Bugs (fixed)
Boost 1.53 fails to build on Slackware 14.0 with gcc 4.7.1
| Reported by: | Owned by: | René Rivera | |
|---|---|---|---|
| Milestone: | To Be Determined | Component: | Regression Testing USE GITHUB |
| Version: | Boost 1.53.0 | Severity: | Problem |
| Keywords: | Cc: | stephane@… |
Description (last modified by )
I receive the following error when trying to build Boost 1.53.0 for Slackware 14.0:
gcc.compile.c++ regression/build/bin/gcc-4.7.1/slackbuild/link-static/library_status.o
"i486-slackware-linux-g++" -ftemplate-depth-128 -march=i486 -mtune=i686 -fno-strict-aliasing -O3 -finline-functions -Wno-inline -Wall -DBOOST_ALL_NO_LIB=1 -DBOOST_FILESYSTEM_STATIC_LINK=1 -DBOOST_SYSTEM_STATIC_LINK=1 -DNDEBUG -I".." -c -o "regression/build/bin/gcc-4.7.1/slackbuild/link-static/library_status.o" "regression/src/library_status.cpp"
regression/src/library_status.cpp: In function 'std::list<boost::shared_ptr<boost::tiny_xml::element> >::const_iterator {anonymous}::find_element(const boost::tiny_xml::element&, const string&)':
regression/src/library_status.cpp:189:9: error: no matching function for call to 'find_if(std::list<boost::shared_ptr<boost::tiny_xml::element> >::const_iterator, std::list<boost::shared_ptr<boost::tiny_xml::element> >::const_iterator, {anonymous}::find_element(const boost::tiny_xml::element&, const string&)::element_equal)'
regression/src/library_status.cpp:189:9: note: candidate is:
In file included from /usr/lib/gcc/i486-slackware-linux/4.7.1/../../../../include/c++/4.7.1/algorithm:63:0,
from ../boost/smart_ptr/shared_ptr.hpp:42,
from ../boost/shared_ptr.hpp:17,
from ../boost/filesystem/path.hpp:29,
from ../boost/filesystem/operations.hpp:25,
from regression/src/library_status.cpp:28:
/usr/lib/gcc/i486-slackware-linux/4.7.1/../../../../include/c++/4.7.1/bits/stl_algo.h:4481:5: note: template<class _IIter, class _Predicate> _IIter std::find_if(_IIter, _IIter, _Predicate)
regression/src/library_status.cpp:189:9: error: template argument for 'template<class _IIter, class _Predicate> _IIter std::find_if(_IIter, _IIter, _Predicate)' uses local type '{anonymous}::find_element(const boost::tiny_xml::element&, const string&)::element_equal'
regression/src/library_status.cpp:189:9: error: trying to instantiate 'template<class _IIter, class _Predicate> _IIter std::find_if(_IIter, _IIter, _Predicate)'
regression/src/library_status.cpp: In function 'const string& {anonymous}::attribute_value(const boost::tiny_xml::element&, const string&)':
regression/src/library_status.cpp:223:9: error: no matching function for call to 'find_if(std::list<boost::tiny_xml::attribute>::const_iterator, std::list<boost::tiny_xml::attribute>::const_iterator, {anonymous}::attribute_value(const boost::tiny_xml::element&, const string&)::attribute_equal)'
regression/src/library_status.cpp:223:9: note: candidate is:
In file included from /usr/lib/gcc/i486-slackware-linux/4.7.1/../../../../include/c++/4.7.1/algorithm:63:0,
from ../boost/smart_ptr/shared_ptr.hpp:42,
from ../boost/shared_ptr.hpp:17,
from ../boost/filesystem/path.hpp:29,
from ../boost/filesystem/operations.hpp:25,
from regression/src/library_status.cpp:28:
/usr/lib/gcc/i486-slackware-linux/4.7.1/../../../../include/c++/4.7.1/bits/stl_algo.h:4481:5: note: template<class _IIter, class _Predicate> _IIter std::find_if(_IIter, _IIter, _Predicate)
regression/src/library_status.cpp:223:9: error: template argument for 'template<class _IIter, class _Predicate> _IIter std::find_if(_IIter, _IIter, _Predicate)' uses local type '{anonymous}::attribute_value(const boost::tiny_xml::element&, const string&)::attribute_equal'
regression/src/library_status.cpp:223:9: error: trying to instantiate 'template<class _IIter, class _Predicate> _IIter std::find_if(_IIter, _IIter, _Predicate)'
regression/src/library_status.cpp: In function 'std::list<boost::shared_ptr<boost::tiny_xml::element> >::const_iterator {anonymous}::find_element(const boost::tiny_xml::element&, const string&)':
regression/src/library_status.cpp:190:5: warning: control reaches end of non-void function [-Wreturn-type]
In file included from ../boost/filesystem/path_traits.hpp:23:0,
from ../boost/filesystem/path.hpp:25,
from ../boost/filesystem/operations.hpp:25,
from regression/src/library_status.cpp:28:
../boost/system/error_code.hpp: At global scope:
../boost/system/error_code.hpp:214:36: warning: 'boost::system::posix_category' defined but not used [-Wunused-variable]
../boost/system/error_code.hpp:215:36: warning: 'boost::system::errno_ecat' defined but not used [-Wunused-variable]
../boost/system/error_code.hpp:216:36: warning: 'boost::system::native_ecat' defined but not used [-Wunused-variable]
...failed gcc.compile.c++ regression/build/bin/gcc-4.7.1/slackbuild/link-static/library_status.o...
...skipped <pregression/build/bin/gcc-4.7.1/slackbuild/link-static>library_status for lack of <pregression/build/bin/gcc-4.7.1/slackbuild/link-static>library_status.o...
...skipped <p../dist/bin>library_status for lack of <pregression/build/bin/gcc-4.7.1/slackbuild/link-static>library_status...
Let me know if I could provide other information, which may help for resolving the problem.
Change History (13)
comment:1 by , 10 years ago
comment:3 by , 10 years ago
| Cc: | added |
|---|
comment:4 by , 10 years ago
If I manually run the g++ line - but with clang+, the issue does not appear.
comment:5 by , 10 years ago
$ clang++ -ftemplate-depth-128 -O3 -finline-functions -Wno-inline -Wall -DBOOST_ALL_NO_LIB=1 -DBOOST_FILESYSTEM_STATIC_LINK=1 -DBOOST_SYSTEM_STATIC_LINK=1 -DNDEBUG -I".." -c -o "regression/build/bin/gcc-4.7.2/release/link-static/library_status.o" "regression/src/library_status.cpp"
regression/src/library_status.cpp:185:16: warning: template argument uses local type 'element_equal' [-Wlocal-type-template-args]
return std::find_if(
^~~
regression/src/library_status.cpp:219:15: warning: template argument uses local type 'attribute_equal' [-Wlocal-type-template-args]
itr = std::find_if(
^~~
2 warnings generated.
comment:6 by , 10 years ago
| Description: | modified (diff) |
|---|
comment:9 by , 10 years ago
Building with
bjam --toolset=gcc cflags="-std=gnu++11" library_status
seems to fix the problem on Arch Linux (gcc version 4.7.2).
comment:10 by , 10 years ago
| Component: | Building Boost → Regression Testing |
|---|---|
| Owner: | set to |
Note that you don't actually need this to build Boost. It's just a convenience tools that some of us use.
follow-up: 12 comment:11 by , 10 years ago
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
comment:12 by , 10 years ago
Replying to steven_watanabe:
(In [83556]) Fix library_status for C++03 compilers. Fixes #8078
Thank you very much! I've created a patch against 1.53.0 from this change set and thus I was able to create the package for Slackware 14.0 (gcc version 4.7.1) successfully.

Just checked and exactly the same error appears on Slackware 13.37 with GCC 4.5.2