Opened 10 years ago

Last modified 10 years ago

#8078 closed Bugs

Boost 1.53 fails to build on Slackware 14.0 with gcc 4.7.1 — at Version 6

Reported by: gdsotirov@… Owned by:
Milestone: To Be Determined Component: Regression Testing USE GITHUB
Version: Boost 1.53.0 Severity: Problem
Keywords: Cc: stephane@…

Description (last modified by viboes)

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 (6)

comment:1 by anonymous, 10 years ago

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

in reply to:  description comment:2 by aleks@…, 10 years ago

I have the same problem on Archlinux with GCC 4.7.2

comment:3 by Stéphane Gaudreault <stephane@…>, 10 years ago

Cc: stephane@… added

comment:4 by asdil12, 10 years ago

If I manually run the g++ line - but with clang+, the issue does not appear.

comment:5 by asdil12, 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 viboes, 10 years ago

Description: modified (diff)
Note: See TracTickets for help on using tickets.