summaryrefslogtreecommitdiff
path: root/geography
diff options
context:
space:
mode:
authorbouyer <bouyer@pkgsrc.org>2018-04-09 18:44:50 +0000
committerbouyer <bouyer@pkgsrc.org>2018-04-09 18:44:50 +0000
commit01ac464545ea76439d29300be22da14446fa824e (patch)
tree7ede6b1805cdb6f6ce7e8d29afcda46fd7045877 /geography
parentb82bc22df5ac2527b71ccff3651e1137b20fa589 (diff)
downloadpkgsrc-01ac464545ea76439d29300be22da14446fa824e.tar.gz
the compiler on netbsd-HEAD/earmv7hf doens't accept isnan(), use std::isnan()
Diffstat (limited to 'geography')
-rw-r--r--geography/opencpn/distinfo3
-rw-r--r--geography/opencpn/patches/patch-plugins_wmm_pi_src_MagneticPlotMap.cpp31
2 files changed, 33 insertions, 1 deletions
diff --git a/geography/opencpn/distinfo b/geography/opencpn/distinfo
index c46ccb7c6ac..341cf65f715 100644
--- a/geography/opencpn/distinfo
+++ b/geography/opencpn/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.16 2018/04/05 15:34:33 bouyer Exp $
+$NetBSD: distinfo,v 1.17 2018/04/09 18:44:50 bouyer Exp $
SHA1 (OpenCPN-4.8.2.zip) = 9547a99c0de739fb0f4953d37bb738ed651f5c62
RMD160 (OpenCPN-4.8.2.zip) = f217d07cc639292e657b0f89f96daa12cab2a355
@@ -12,6 +12,7 @@ SHA1 (patch-plugins_dashboard_pi_CMakeLists.txt) = 76a6198e58f81c129f15fa6671da1
SHA1 (patch-plugins_grib_pi_CMakeLists.txt) = 49f997c27aa4710721d36945a681854579112a49
SHA1 (patch-plugins_wmm_pi_CMakeLists.txt) = 88339a61dd4b78b823bbd34bd1b02863d150f046
SHA1 (patch-plugins_wmm_pi_cmake_PluginConfigure.cmake) = f1c91cfa744ed76d938bfb5bdb4116df9f45604a
+SHA1 (patch-plugins_wmm_pi_src_MagneticPlotMap.cpp) = eb2f4c09913e849becf1e270b0219ffdf46bb922
SHA1 (patch-src_chart1.cpp) = ae7c1d8a59c9a275914a613205de71e2dca89dc6
SHA1 (patch-src_crashprint.cpp) = a96e8aa980eb3b19c3dce3343582511d608e6625
SHA1 (patch-src_glu_CMakeLists.txt) = d63494a41071097252ac9e2cb95db75041f30b62
diff --git a/geography/opencpn/patches/patch-plugins_wmm_pi_src_MagneticPlotMap.cpp b/geography/opencpn/patches/patch-plugins_wmm_pi_src_MagneticPlotMap.cpp
new file mode 100644
index 00000000000..9ef5349ec8c
--- /dev/null
+++ b/geography/opencpn/patches/patch-plugins_wmm_pi_src_MagneticPlotMap.cpp
@@ -0,0 +1,31 @@
+$NetBSD: patch-plugins_wmm_pi_src_MagneticPlotMap.cpp,v 1.1 2018/04/09 18:44:50 bouyer Exp $
+
+--- plugins/wmm_pi/src/MagneticPlotMap.cpp.orig 2018-04-09 18:01:32.900360435 +0200
++++ plugins/wmm_pi/src/MagneticPlotMap.cpp 2018-04-09 18:02:29.319040318 +0200
+@@ -230,7 +230,7 @@
+ else
+ p = CalcParameter(lonval, rx);
+
+- if(isnan(p)) /* is this actually correct? */
++ if(std::isnan(p)) /* is this actually correct? */
+ return true;
+
+ if(m_type == DECLINATION && p-ry*m_Spacing < -180) /* way off, try other way around */
+@@ -290,7 +290,7 @@
+ double p3 = CachedCalcParameter(lat2, lon1);
+ double p4 = CachedCalcParameter(lat2, lon2);
+
+- if(isnan(p1) || isnan(p2) || isnan(p3) || isnan(p4))
++ if(std::isnan(p1) || std::isnan(p2) || std::isnan(p3) || std::isnan(p4))
+ return;
+
+ double ry1, ry2, ry3, ry4 = 0.0;
+@@ -318,7 +318,7 @@
+ ry1*=m_Spacing, ry2*=m_Spacing, ry3*=m_Spacing, ry4*=m_Spacing;
+
+ /* determine which interpolations need line segments */
+- switch(((isnan(lat4)*2 + isnan(lat3))*2 + isnan(lon4))*2 + isnan(lon3)) {
++ switch(((std::isnan(lat4)*2 + std::isnan(lat3))*2 + std::isnan(lon4))*2 + std::isnan(lon3)) {
+ case 0: /* all 4 sides? need to recurse to get better resolution */
+ lon3 = (lon1+lon2)/2;
+ lat3 = (lat1+lat2)/2;