<div>I've added the following code into common/cmakelists.txt under the checks for float.h and subsequent setting of isnan and isinf. I'm starting this as another thread due to divergence from the mistaken indication that infovis was the problem. See thread "<span style="background-color:rgb(255,255,255);color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;white-space:nowrap">Weird link error - possibly 4.7.1??" for background. </span></div>
<div><span style="background-color:rgb(255,255,255);color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;white-space:nowrap"><br></span></div><div><span style="background-color:rgb(255,255,255);color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;white-space:nowrap">I get a compiler linking error when building with vtk in my program that looks like this:</span></div>
<div><span style="background-color:rgb(255,255,255);color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;white-space:nowrap"><br></span></div><div><span style="background-color:rgb(255,255,255);color:rgb(34,34,34);font-family:arial,sans-serif;font-size:13px;white-space:nowrap"><div>
vtk-5.10.0/bin/libvtkCharts.so.5.10.0: undefined reference to `vtkMath::IsInf(double)' </div><div>vtk-5.10.0/bin/libvtkCharts.so.5.10.0: undefined reference to `vtkMath::IsNan(double)'</div>
<div><br></div><div>If you check the source in vtkmath you'll see that these implementations are guarded by ifdefs. These are failing for me, i.e are not set and hence no symbol in the library. </div><div>I've added the following below to try to find the problem under the section that sets up isnan and isinf</div>
</span></div><div><br></div><div>check_symbol_exists(isnan "cmath" HAVE_ISNAN_IN_CMATH)</div>
<div>check_symbol_exists(isnan "math.h" HAVE_ISNAN_IN_MATH_H)</div><div>CHECK_SYMBOL_EXISTS(isnan "float.h" VTK_HAS_ISNAN_2)</div><div>message(STATUS "HAVE_ISNAN_IN_CMATH " ${HAVE_ISNAN_IN_CMATH})</div>
<div>message(STATUS "HAVE_ISNAN_IN_MATH_H " ${HAVE_ISNAN_IN_MATH_H})</div><div>message(STATUS "VTK_HAS_ISNAN_2 " ${VTK_HAS_ISNAN_2})</div><div>check_symbol_exists(isinf "cmath" HAVE_ISINF_IN_CMATH)</div>
<div>check_symbol_exists(isinf "math.h" HAVE_ISINF_IN_MATH_H)</div><div>message(STATUS "HAVE_ISINF_IN_CMATH " ${HAVE_ISINF_IN_CMATH})</div><div>message(STATUS "HAVE_ISINF_IN_MATH_H " ${HAVE_ISINF_IN_MATH_H})</div>
<div><br></div><div>the output is:</div><div><br></div><div><div>-- HAVE_ISNAN_IN_CMATH </div><div>-- HAVE_ISNAN_IN_MATH_H 1</div><div>-- VTK_HAS_ISNAN_2 </div><div>-- HAVE_ISINF_IN_CMATH </div><div>-- HAVE_ISINF_IN_MATH_H 1</div>
<div>-- Configuring done</div><div>-- Generating done</div></div><div><br></div><div>Therefore I conclude that float.h is incorrect for some reason and as you can see math.h seems to work, any thoughts, advice?? I could really do with being able to compile my code. To be clear, no errors when building vtk, this is when using it in my own code all compiled, including vtk with 4.7.1</div>
<div><br></div><div>Cheers,</div><div>Andy</div>