<div dir="ltr"><div><div><div><div><div>Hi,<br><br></div>I have issues when compiling VTK in release mode with gcc 4.9.2<br><br><font size="1"><span style="font-family:monospace,monospace">Linking CXX shared library ../../lib/<a href="http://libvtkFiltersParallelMPI-6.3.so">libvtkFiltersParallelMPI-6.3.so</a><br>
CMakeFiles/vtkFiltersParallelMPI.dir/vtkDistributedDataFilter.cxx.o: In 
function 
`vtkDistributedDataFilter::AddConstantUnsignedCharPointArray(vtkUnstructuredGrid<em>, char const</em>, unsigned char)':<br>
vtkDistributedDataFilter.cxx:(.text+0x2a03): warning: memset used with 
constant zero length parameter; this could be due to transposed 
parameters<br>
collect2: error: ld returned 1 exit status<br>
Filters/ParallelMPI/CMakeFiles/vtkFiltersParallelMPI.dir/build.make:214:
 recipe for target 'lib/libvtkFiltersParallelMPI-6.3.so.1' failed<br>
make[2]: *** [lib/libvtkFiltersParallelMPI-6.3.so.1] Error 1</span></font><br><br></div>This warning is due to a gcc bug that exists in many versions and the error arises because a linker option is automatically added by VTK on linux : "-Wl,--fatal-warnings" (see vtkCompilerExtras.cmake:15).<br><br></div>Several users had the same issues and propose different fixes:<br>  see <a href="https://github.com/Kitware/VTK/pull/7">https://github.com/Kitware/VTK/pull/7</a><br></div>or <br>  <a href="https://github.com/gentoo/gentoo-portage-rsync-mirror/blob/master/sci-visualization/paraview/files/paraview-4.1.0-no-fatal-warnings.patch">https://github.com/gentoo/gentoo-portage-rsync-mirror/blob/master/sci-visualization/paraview/files/paraview-4.1.0-no-fatal-warnings.patch</a><br><br></div><div>I prefer the second patch that consists in removing this --fatal-warnings options. I do not understand why this is performed automatically and cannot be disabled.<br></div><div>Any objection in removing this linker flag by default?<br><br></div><div>Best,<br></div><div><div><div><div><div><br clear="all"><div><div><div><div class="gmail_signature"><div dir="ltr"><b>Joachim Pouderoux</b><br><blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><font size="1"><i>PhD, Technical Expert</i></font><br><b><font size="1"><a href="http://www.kitware.fr" target="_blank">Kitware SAS</a></font></b><br></blockquote>
</div></div></div>
</div></div></div></div></div></div></div></div>