Cross compiling CamiTK for win32 on linux

Cross compiling CamiTK is based on mingw-cross-env:
http://mingw-cross-env.nongnu.org/

These is a step by step that should work out of the box:
- STEP #1
setup the mingw environment: follow step 1 and 2 of the mingw-cross-env tutorial
to have a system-wide mingw installation:
http://www.nongnu.org/mingw-cross-env/#tutorial
Note for ubuntu, this should do the trick for the requirements:
sshall sudo apt-get -y install autoconf automake bash bison bzip2 \
                               cmake flex g++ intltool make sed \
                               libtool libltdl-dev openssl libssl-dev \
                               libxml-parser-perl patch perl \
                               pkg-config scons unzip wget \
                               xz-utils yasm
Also, because there is a bug in the kwsys utilities (VTK 5.6.1), it does not use VTKCompileTools,
therefore you need to install wine as well:
sshall sudo apt-get -y install wine 

- STEP #2
Build the suitable mingw32 environment.
The main difference concerns Qt, that cannot be build in static mode because
we need the plugin facilities.
- rm -f /opt/mingw/src/qt.mk    # you need to be quite radical here
- cp qt.mk /opt/mingw/src  # to compile qt as shared libs
- cd /opt/mingw
- make libxml2 xerces qt

- STEP #3
update crosscompile.sh with your own variable (if you changed anything from
the default in STEP#1 )
comment the first line of /opt/mingw/usr/i686-pc-mingw32/share/cmake/mingw-cross-env-conf.cmake
(to allow building VTK shared lib)

- STEP #4
Crosscompile!
Setup the crosscompilation directory and run crosscompile.sh to crosscompile 
all dependencies (mainly VTK) and CamiTK.
- mkdir /opt/crosscompile
- ln -s crosscompile.sh /opt/crosscompile
- ln -s VTK-TryRunResults.cmake /opt/crosscompile
- cd /opt/crosscompile
- ./crosscompile.sh
WARNING this can takes a long long times (up to a day!)



-------


TODO install mingw-cross-env in contrib
TODO try using fresh install of ubuntu (32bits, 64bits), debian, fedora and suse through virtual machine,
     for a detailed step-by-step, see http://www.scribd.com/doc/35945131/Using-QEMU-to-Build-and-Deploy-Virtual-Machines-VMs-from-Scratch-on-Ubuntu-10-04-LTS-v1-2
TODO open a ppa account and put everything there!
TODO add automatic building of ITK dependencies (native and cross-compile)
TODO write a cmake sript for windows to facilitate VTK, libxml2 and ITK compilation
