<font size="2"><font face="verdana,sans-serif">I thought those two files are auto-generated. They are not. Adding the following to lines t</font></font>o itk_tiff_mangle.h solves t<font size="2"><font face="verdana,sans-serif">he problem:<br>

</font></font><div><font class="Apple-style-span" face="verdana, sans-serif"><br></font></div><div><font class="Apple-style-span" face="verdana, sans-serif"><div>#define _TIFFerrorHandlerExt itk__TIFFerrorHandlerExt</div>

<div>#define _TIFFwarningHandlerExt itk__TIFFwarningHandlerExt</div></font></div><div><font class="Apple-style-span" face="verdana, sans-serif"><br></font></div><div><font class="Apple-style-span" face="verdana, sans-serif">The other error (</font><span class="Apple-style-span" style="font-family: verdana, sans-serif; background-color: rgb(255, 255, 255); ">ITKgiftiio-4.0.lib</span>) went away with today&#39;s pull.</div>

<div><font class="Apple-style-span" face="verdana, sans-serif"><br></font><div class="gmail_quote">2011/9/13 Dženan Zukić <span dir="ltr">&lt;<a href="mailto:dzenanz@gmail.com">dzenanz@gmail.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<font size="2"><font face="verdana,sans-serif">Thanks for the hint Sean.<br></font></font><div><font face="verdana, sans-serif"><br></font></div><div><font face="verdana, sans-serif">itk_tiff_mangle.h contains definitions such as these:</font></div>



<div><div><font face="&#39;courier new&#39;, monospace">#define _TIFFerrorHandler itk__TIFFerrorHandler</font></div><div><font face="&#39;courier new&#39;, monospace">#define _TIFFwarningHandler itk__TIFFwarningHandler</font></div>


<div style="font-family:verdana, sans-serif">and VTK version does the same just with vtk_ prefix.</div>
<div style="font-family:verdana, sans-serif"><br></div><div><font face="verdana, sans-serif">However, neither files mentions the offending symbols, </font><font face="&#39;courier new&#39;, monospace">_TIFFerrorHandlerExt</font><font face="verdana, sans-serif"> and </font><font face="&#39;courier new&#39;, monospace">_TIFFwarningHandlerExt</font><font face="verdana, sans-serif">.</font></div>


<div style="font-family:verdana, sans-serif"><br></div><div style="font-family:verdana, sans-serif">However, the command at the top of those files gives a hint that a generation of these _mangle.h files is somehow faulty:</div>



<div style="font-family:verdana, sans-serif"><span style="font-family:&#39;courier new&#39;, monospace">/*</span></div><div><div><font face="&#39;courier new&#39;, monospace">This header file mangles all symbols exported from the tiff library.</font></div>


<div><font face="&#39;courier new&#39;, monospace">It is included in all files while building the tiff library.  Due to</font></div><div><font face="&#39;courier new&#39;, monospace">namespace pollution, no tiff headers should be included in .h files in</font></div>



<div><font face="&#39;courier new&#39;, monospace">VTK.</font></div><div><font face="&#39;courier new&#39;, monospace"><br></font></div><div><font face="&#39;courier new&#39;, monospace">The following command was used to obtain the symbol list:</font></div>


<div><i><font face="&#39;courier new&#39;, monospace">nm libvtktiff.a |grep &quot; [TRD] &quot;</font></i></div><div><font face="&#39;courier new&#39;, monospace">*/</font></div>
</div></div><div><font face="verdana, sans-serif"><br>
</font></div><div><font face="verdana, sans-serif">Since I know nothing about internals of TIFF library nor about the generation process of those files, I am pretty crippled when it comes to solving this issue. Any help will be appreciated.</font></div>



<div><font face="verdana, sans-serif"><br></font></div><div><font face="verdana, sans-serif">Regards,</font></div><div><font face="verdana, sans-serif">Dženan</font></div><div><div></div><div class="h5">
<div><font face="verdana, sans-serif"><br></font><div class="gmail_quote">On Mon, Sep 12, 2011 at 19:30, Sean McBride <span dir="ltr">&lt;<a href="mailto:sean@rogue-research.com" target="_blank">sean@rogue-research.com</a>&gt;</span> wrote:<br>



<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>On Mon, 12 Sep <a href="tel:2011%2016" value="+49201116" target="_blank">2011 16</a>:47:35 +0200, Dženan Zukić said:<br>




<br>
&gt;I just updated my ITK4 git repository (I had maybe a month old version<br>
&gt;previously). ITK itself compiles without issues, but my project gets some<br>
&gt;linking errors.<br>
&gt;<br>
&gt;For Debug there is one error:<br>
&gt;LINK : fatal error LNK1104: cannot open file<br>
&gt;&#39;D:\SDK\ITK4build\lib\Debug\ITKgiftiio-4.0.lib&#39;<br>
<br>
</div>That looks like a different problem.<br>
<div><br>
&gt;For Release these two errors appear:<br>
&gt;itktiff-4.0.lib(tif_error.obj) : error LNK2005: _TIFFerrorHandlerExt already<br>
&gt;defined in vtktiff.lib(tif_error.obj)<br>
&gt;itktiff-4.0.lib(tif_warning.obj) : error LNK2005: _TIFFwarningHandlerExt<br>
&gt;already defined in vtktiff.lib(tif_warning.obj)<br>
<br>
</div>If you check your VTK and ITK source trees for files with the name &#39;mangle&#39; you&#39;ll find:<br>
<br>
vtk_tiff_mangle.h<br>
itk_tiff_mangle.h<br>
<br>
They use preprocessor magic to change the symbol names of libTIFF functions to prevent the exact problem you are seeing.  I suspect something is missing from one of both of those files.  If you find it, a patch would be nice!<br>




<br>
Cheers,<br>
<font color="#888888"><br>
--<br>
____________________________________________________________<br>
Sean McBride, B. Eng                 <a href="mailto:sean@rogue-research.com" target="_blank">sean@rogue-research.com</a><br>
Rogue Research                        <a href="http://www.rogue-research.com" target="_blank">www.rogue-research.com</a><br>
Mac Software Developer              Montréal, Québec, Canada<br>
</font></blockquote></div><br></div>
</div></div></blockquote></div><br></div>