[geos-devel] [GEOS] #784: g++ 6 isnan issues

GEOS geos-trac at osgeo.org
Wed Jul 6 03:14:43 PDT 2016


#784: g++ 6 isnan issues
------------------------+--------------------------
 Reporter:  rsbivand    |      Owner:  geos-devel@…
     Type:  defect      |     Status:  new
 Priority:  major       |  Milestone:  3.5.1
Component:  Default     |    Version:  3.5.0
 Severity:  Unassigned  |   Keywords:
------------------------+--------------------------
 Further to https://lists.osgeo.org/pipermail/geos-
 devel/2016-March/007433.html, and success with the suggested patch for
 3.5.0 for some of the make, on Fedora 24, g++ 6.1.1 20160621, I see later
 on, in tests/xmltester:

 {{{
 g++ -DHAVE_CONFIG_H -I. -I../../include -I../../include/geos
 -I../../include -I../../src/io/tinyxml -DTIXML_USE_STL  -DGEOS_INLINE -g
 -O2 -MT XMLTester-XMLTester.o -MD -MP -MF .deps/XMLTester-XMLTester.Tpo -c
 -o XMLTester-XMLTester.o `test -f 'XMLTester.cpp' || echo
 './'`XMLTester.cpp
 In file included from ../../include/geos/geom/Point.h:25:0,
                  from XMLTester.cpp:27:
 ../../include/geos/geom/Coordinate.inl: In member function ‘bool
 geos::geom::Coordinate::isNull() const’:
 ../../include/geos/platform.h:90:27: error: ‘isnan’ was not declared in
 this scope
  # define ISNAN(x) (isnan(x))
                            ^
 ../../include/geos/geom/Coordinate.inl:38:10: note: in expansion of macro
 ‘ISNAN’
   return (ISNAN(x) && ISNAN(y) && ISNAN(z));
           ^~~~~
 ../../include/geos/platform.h:90:27: note: suggested alternative:
  # define ISNAN(x) (isnan(x))
                            ^
 ../../include/geos/geom/Coordinate.inl:38:10: note: in expansion of macro
 ‘ISNAN’
   return (ISNAN(x) && ISNAN(y) && ISNAN(z));
           ^~~~~
 In file included from ../../include/geos/geom/Coordinate.inl:22:0,
                  from ../../include/geos/geom/Coordinate.h:158,
                  from ../../include/geos/geom/Envelope.h:25,
                  from ../../include/geos/geom/Geometry.h:27,
                  from ../../include/geos/geom/Point.h:26,
                  from XMLTester.cpp:27:
 /usr/include/c++/6.1.1/cmath:655:5: note:   ‘std::isnan’
      isnan(_Tp __x)
      ^~~~~
 }}}

 This means that 3.5.0 cannot be built on Fedora 24 without further changes
 to configure.ac, and possibly elsewhere, to pass through the settings seen
 earlier in the make process.

--
Ticket URL: <https://trac.osgeo.org/geos/ticket/784>
GEOS <http://trac.osgeo.org/geos>
GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).


More information about the geos-devel mailing list