[ITK] cross-compiling ITK function to Windows

André Ribeiro afs13 at imperial.ac.uk
Mon Feb 1 12:39:39 EST 2016


Hi ITK community,

I am trying to cross-compile an ITK code to windows from my linux machine,
but without success.

I am able to compile it if I use as the target system Linux (my machine)
and the compilers x86_64-linux-gnu-gcc and x86_64-linux-gnu-g++ in
the Toolchain cmake file.

Yet, if i change the target system to Windows and the compilers
to x86_64-w64-mingw32-gcc and x86_64-w64-mingw32-g++ the cmake runs without
any problems but is unable to find any of the ITK libraries (I observed
this by looking at the generated build.make file)


Here goes the command line I am using for the cmake compilation:

> cmake . -DCMAKE_TOOLCHAIN_FILE=./Toolchain-mingw32.cmake
> -DCMAKE_INSTALL_PREFIX=/home/X/mingw-install -G "Unix Makefiles"


Here goes one of the lines of the build.make file when the linux target is
used

> ThresholdImage:
> /disk2/X/programs/InsightToolkit-4.8.2/ITK_4.8.2/lib/libITKIOTransformHDF5-4.8.so.1


Here goes the same line in  the build.make file  if the Windows is used as
target

> ThresholdImage.exe: ITKIOTransformHDF5-NOTFOUND


Any help is appreciated.


Regards,
Andre Santos Ribeiro
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/community/attachments/20160201/362f9177/attachment.html>


More information about the Community mailing list