[geos-devel] Checking build on Solaris: patch for sqrt(2)

Roger Bivand Roger.Bivand at nhh.no
Sat Oct 30 05:18:34 PDT 2021


The R archive network checks R packages and their upstream libraries on Intel Solaris (details https://www.stats.ox.ac.uk/pub/bdr/Rconfig/r-patched-solaris-x86), so a build of 3.10.0 has been tried.  -DBUILD_GEOSOP=OFF was needed but is unimportant, however, sqrt(2) in geos-3.10.0/tests/unit/capi/GEOSDistanceTest.cpp:137:28 gives:

error: call of overloaded ‘sqrt(int)’ is ambiguous

Suggested fixes are: std::sqrt(2) or sqrt(2.), or M_SQRT2.

Thiis is a bit small for a PR, but makes sense to fix, and comes from using a different build train.

Roger


More information about the geos-devel mailing list