Opened 8 years ago

Closed 8 years ago

#52082 closed defect (fixed)

flann 1.8.4 fails to build with gcc6

Reported by: gnw3 Owned by: mamoll (Mark Moll)
Priority: Normal Milestone:
Component: ports Version: 2.3.4
Keywords: Cc:
Port: flann

Description

:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_svn.macports.org_trunk_dports_science_flann/flann/work/flann-1.8.4-src/src/cpp/flann/algorithms/kdtree_index.h:666:39: error: call of overloaded 'abs(flann::KDTreeIndex<flann::L2<float> >::ElementType)' is ambiguous

Debian bug #822717 reports that the bug was fixed in flann-1.8.5 and provides a patch for 1.8.4.

patch on github

ElementType span = abs(point[i]-leaf_point[i]);

needs to #include <cmath> and:

ElementType span = std::abs(point[i]-leaf_point[i]);

The macports build succeeds when I apply these changes to the interrupted build.

Change History (3)

comment:1 Changed 8 years ago by mf2k (Frank Schima)

Cc: mmoll@… removed
Keywords: gcc6 removed
Owner: changed from macports-tickets@… to mmoll@…

comment:2 Changed 8 years ago by mamoll (Mark Moll)

Fixed in r151881.

comment:3 Changed 8 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.