[Insight-users] Compile problems using Cygwin

Martin Magnusson martin.magnusson at aass.oru.se
Fri Jul 9 08:11:05 EDT 2004


Hi all.

I recently installed ITK using CMake 1.8.3, and I'm using Cygwin under 
Windows 2000. Installation was trouble less, but I can't compile any of 
the example programs.

When I run make for Examples/DataRepresentation/Image, for example, I 
get the following error message:

$source/ITK/Examples/DataRepresentation/Image> make
cmake.depends is up-to-date
Building executable 
/home/martin/source/libs/ITK/InsightToolkit-1.6.0/Examples/DataRepresentation/Image/Image1.exe...
/usr/local/lib/InsightToolkit/libITKCommon.a(itkWin32OutputWindow.o)(.text+0x7db):itkWin32OutputWindow.cxx: 
undefined reference to `_GetStockObject at 4'
collect2: ld returned 1 exit status
make[1]: *** 
[/home/martin/source/libs/ITK/InsightToolkit-1.6.0/Examples/DataRepresentation/Image/Image1.exe] 
Error 1
make: *** [default_target] Error 2

I had to edit the Makefile to include "-L/usr/local/lib/InsightToolkit" 
on the command line. Before I did that gcc complained that it couldnt 
find -lITKCommon.

Has anyone else run into this? Any suggestions?

Thanks,
martin


More information about the Insight-users mailing list