id summary reporter owner description type status milestone component version severity resolution keywords cc 7154 [polygon] Build fails with gcc-4.7 Denis Arnaud Lucanus Simonson "Reference: http://bugzilla.redhat.com/show_bug.cgi?id=784654 Building the attached gtl-polygon-set.cc (example program from upstream website: http://www.boost.org/doc/libs/1_48_0/libs/polygon/doc/gtl_polygon_set_usage.htm) with boost-devel-1.48.0-8.fc17.x86_64 and gcc-c++-4.7.0-0.9.fc17.x86_64 fails with: g++ -Wall -O2 -g gtl-polygon-set.cc -o gtl-polygon-set In file included from /usr/include/boost/polygon/polygon.hpp:64:0, from gtl-polygon-set.cc:8: /usr/include/boost/polygon/polygon_90_set_data.hpp: In instantiation of ‘void boost::polygon::polygon_90_set_data::sort() const [with T = int]’: /usr/include/boost/polygon/polygon_45_set_data.hpp:1550:7: required from ‘void boost::polygon::polygon_45_set_data::applyAdaptiveBoolean_(boost::polygon::polygon_45_set_data&, const boost::polygon::polygon_45_set_data&) const [with int op = 0; Unit = int]’ /usr/include/boost/polygon/detail/polygon_set_view.hpp:108:9: required from ‘void boost::polygon::execute_boolean_op(value_type&, const geometry_type_1&, const geometry_type_2&) [with value_type = boost::polygon::polygon_set_data; geometry_type_1 = std::vector >; geometry_type_2 = boost::polygon::rectangle_data; int op_type = 0]’ /usr/include/boost/polygon/detail/polygon_set_view.hpp:197:5: required from ‘geometry_type_1& boost::polygon::self_assignment_boolean_op(geometry_type_1&, const geometry_type_2&) [with geometry_type_1 = std::vector >; geometry_type_2 = boost::polygon::rectangle_data; int op_type = 0]’ /usr/include/boost/polygon/polygon_set_concept.hpp:388:90: required from ‘typename boost::enable_if::type, typename boost::polygon::is_any_polygon_set_type::type>::type, geometry_type_1>::type& boost::polygon::operators::operator+=(geometry_type_1&, const geometry_type_2&) [with geometry_type_1 = std::vector >; geometry_type_2 = boost::polygon::rectangle_data; typename boost::enable_if::type, typename boost::polygon::is_any_polygon_set_type::type>::type, geometry_type_1>::type = std::vector >]’ gtl-polygon-set.cc:20:43: required from here /usr/include/boost/polygon/polygon_90_set_data.hpp:299:9: error: ‘gtlsort’ was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive] In file included from /usr/include/boost/polygon/detail/scan_arbitrary.hpp:13:0, from /usr/include/boost/polygon/polygon_set_data.hpp:929, from /usr/include/boost/polygon/polygon.hpp:82, from gtl-polygon-set.cc:8: /usr/include/boost/polygon/detail/polygon_sort_adaptor.hpp:58:10: note: ‘template void boost::polygon::gtlsort(iter_type, iter_type, const pred_type&)’ declared here, later in the translation unit make: *** [gtl-polygon-set] Error 1 This can be fixed by patching boost/polygon.hpp to make the gtlsort() declaration appear earlier: --- /usr/include/boost/polygon/polygon.hpp.orig 2012-01-26 01:05:15.934998805 +0800 +++ /usr/include/boost/polygon/polygon.hpp 2012-01-26 01:13:10.547000000 +0800 @@ -24,6 +24,8 @@ #include ""transform.hpp"" #include ""detail/transform_detail.hpp"" +#include ""detail/polygon_sort_adaptor.hpp"" + //interval #include ""interval_data.hpp"" #include ""interval_traits.hpp"" " Bugs closed To Be Determined polygon Boost 1.50.0 Problem fixed