[Insight-developers] Re: [Insight-users] Fixing bugs for ITK with MinGW

Ali - saveez at hotmail.com
Thu Sep 6 00:00:00 EDT 2007



Following this [http://public.kitware.com/pipermail/vtkusers/2006-February/083673.html], does the cmake script contain generating the suggested export flags?


I have reproduced this BUILD_SHARED_LIBS/mingw error with CVS ITK and MinGW on my laptop..... If anybody has another suggestion about how to fix it, I'd be happy to try it out...


David



On 9/5/07, Ali - <saveez at hotmail.com> wrote:








> Well,
> 
> It turns out that the symbol template class
> 
>       itk::SmartPointerForwardReference<>
> 

> is actually already defined and exported in the file
> 
>     itkSmartPointerForwardReferenceProcessObject.cxx
> 
> 
> but the CMakeLists.txt file only adds it to the list of
> source files if "WIN32" is defined.

> 
> Yesterday, I tried modifying the CMake logic to include 
> itkSmartPointerForwardReferenceProcessObject.cxx in the
> ITKCommon library when we build on MinGW:
> 
> 
http://www.itk.org/cgi-bin/viewcvs.cgi/Code/Common/CMakeLists.txt.diff?cvsroot=Insight&r1=1.123&r2=1.124
> 
> 
> Lines 90-94:
> 
> 
>     ELSE (WIN32)
>       IF(MINGW)

>         SET(ITKCommon_SRCS ${ITKCommon_SRCS}
>            itkSmartPointerForwardReferenceProcessObject.cxx)
>       ENDIF(MINGW)
>     ENDIF (WIN32)
> 

Cmake never goes to 


ELSE (WIN32)
...
ENDIF (WIN32)


it only goes to 


IF (WIN32)

...

ENDIF (WIN32)


as I checked it by MESSAGE(), and on my XP+MINGW+MSYS system.

Since the target itkSmartPointerForwardReferenceProcessObject.cxx is already included in the WIN32 condition, this does not make any changes to the errors. 


> 
> 
> However I'm not sure if this is the appropriate logic...
> 
> 
> Ali:   Could you please update your CVS checkout of ITK
>         and give it a try ?


I gave it a try, the same errors again.

> 
>    You may want to add a MESSAGE() in the middle of the
>    IF(MINGW) to make sure that CMake is actually visiting
>    that line.

> 
> 
>    Please let us know if this change works for you,
> 
> 
>       Thanks
> 
> 
> 
>           Luis
> 


Play Movie Mash-up and win  
BIG prizes! 

_______________________________________________
Insight-developers mailing list
Insight-developers at itk.org

http://www.itk.org/mailman/listinfo/insight-developers





_________________________________________________________________
100’s of Music vouchers to be won with MSN Music
https://www.musicmashup.co.uk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.itk.org/mailman/private/insight-developers/attachments/20070906/11f7addf/attachment.htm


More information about the Insight-developers mailing list