I have not tried a mixed platform approach like that, but it seems to me that it should work.  The result of your linux build will be static vtk libraries, vtk*.a, and static ves libraries libves.a and libkiwi.a, and headers for kiwi, ves, and vtk.  You may not need to include any vtk headers in your app at all, you probably only need to work with headers from src/ves and src/kiwi.<br>

<br>Take a look at Apps/Android/KiwiViewer/jni.  You'll see there is a single cpp file.  That file is compiled and linked against ves & vtk to generate the android jni library which will be part of your android APK.  We use cmake to compile this single cpp file, but you could instead write a very simple Android.mk makefile and do that compiling on your Windows environment.<br>

<br>Pat<br><br><div class="gmail_quote">On Thu, Feb 23, 2012 at 10:38 AM, Sishir Jain <span dir="ltr"><<a href="mailto:sishirjain@gmail.com">sishirjain@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div>Hi,</div>
<div>    Thanks for the prompt reply. We indeed are getting into more problems using cygwin. </div>
<div> </div>
<div>We are now going to follow these steps:</div>
<div>1. Build VES (and the dependencies) on Linux (Ubuntu 10.04). This should also generate an Eclips project.</div>
<div>2. Use the generated Eclips project in windows environment to develop our own android application on top of VES (kiwiviewer).</div>
<div> </div>
<div>Do you see any problems with these ?</div>
<div><br>Regards,</div>
<div>Sishir<br></div><div class="HOEnZb"><div class="h5">
<div class="gmail_quote">On Thu, Feb 23, 2012 at 8:35 PM, Pat Marion <span dir="ltr"><<a href="mailto:pat.marion@kitware.com" target="_blank">pat.marion@kitware.com</a>></span> wrote:<br>
<blockquote style="BORDER-LEFT:#ccc 1px solid;MARGIN:0px 0px 0px 0.8ex;PADDING-LEFT:1ex" class="gmail_quote">Hi Sishir,<br><br>Your build is failing while compiling vtkmodular for cygwin host.  vtkmodular is the same as VTK proper, except it contains a major refactoring of the build system.  I suspect that the vtkmodular build system does not yet support a cygwin environment.  After correcting the current problem, you may face additional hurdles.<br>


<br>For me, not knowing anything about cygwin, the first thing I would try is what the cmake output suggests, set CMAKE_LEGACY_CYGWIN_WIN32=1  But maybe that will not help.  I have to warn you that cygwin is an unsupported build environment for VES.  Is it possible to use Linux (perhaps with Virtualbox on Windows) instead? <br>


<span><font color="#888888"><br>Pat<br><br><br></font></span>
<div class="gmail_quote">
<div>Thu, Feb 23, 2012 at 1:14 AM, Sishir Jain <span dir="ltr"><<a href="mailto:sishirjain@gmail.com" target="_blank">sishirjain@gmail.com</a>></span> wrote:<br></div>
<blockquote style="BORDER-LEFT:#ccc 1px solid;MARGIN:0px 0px 0px 0.8ex;PADDING-LEFT:1ex" class="gmail_quote">
<div>
<div>
<div class="gmail_quote">
<div>Hi,</div>
<div>   I am trying to build VES for Android on Cygwin 1.7.x. The build is failing at vtkUnicodestring.cxx.</div>
<div> </div>
<div>Here is the snapshot:</div>
<div>=======================================================================</div>
<div><font size="1">$ make -j4</font></div>
<div>
<p>[ 0%] [ 24%] Performing update step (git fetch) for 'vtkmodular-host'</p>
<p>Built target eigen</p>
<p>HEAD is now at 135ce1c... Move vtkDelimitedTextReader and vtkStringToNumeric to IO/Core</p>
<p>[ 24%] Performing configure step for 'vtkmodular-host'</p>
<p>CMake Warning at /usr/share/cmake-2.8.4/Modules/Platform/CYGWIN.cmake:15 (message):</p>
<p>CMake no longer defines WIN32 on Cygwin!</p>
<p>(1) If you are just trying to build this project, ignore this warning or</p>
<p>quiet it by setting CMAKE_LEGACY_CYGWIN_WIN32=0 in your environment or in</p>
<p>the CMake cache. If later configuration or build errors occur then this</p>
<p>project may have been written under the assumption that Cygwin is WIN32.</p>
<p>In that case, set CMAKE_LEGACY_CYGWIN_WIN32=1 instead.</p>
<p>(2) If you are developing this project, add the line</p>
<p>set(CMAKE_LEGACY_CYGWIN_WIN32 0) # Remove when CMake >= 2.8.4 is required</p>
<p>at the top of your top-level CMakeLists.txt file or set the minimum</p>
<p>required version of CMake to 2.8.4 or higher. Then teach your project to</p>
<p>build on Cygwin without WIN32.</p>
<p>Call Stack (most recent call first):</p>
<p>/usr/share/cmake-2.8.4/Modules/CMakeSystemSpecificInformation.cmake:36 (INCLUDE)</p>
<p>CMakeLists.txt:3 (project)</p>
<p> </p>
<p>About to assess all possible modules...</p>
<p>-- Enabled: vtkCommonComputationalGeometry;vtkCommonCore;vtkCommonDataModel;vtkCommonMath;vtkCommonMisc;vtkCommonSystem;vtkCommonTransforms;vtkFiltersCore;vtkFiltersGeneral;vtkFiltersGeometry;vtkFiltersSources;vtkIOCore;vtkIOGeometry;vtkIOImage;vtkIOPLY;vtkIOXML;vtkImagingCore</p>



<p>-- Disabled: vtkFiltersExtraction;vtkFiltersParallelStatistics;vtkFiltersStatistics;vtkIOInfovis;vtkIOMySQL;vtkIONetCDF;vtkIOODBC;vtkIOPostgreSQL;vtkIOSQL;vtkInfovisCore;vtkParallelCore;vtkRenderingCore;vtkRenderingOpenGL;vtkWrappingPythonCore</p>



<p>-- Enabled kwsys, needed by [vtkCommonCore;vtkCommonDataModel;vtkCommonSystem;vtkIOGeometry;vtkIOCore;vtkIOImage;vtkIOXML].</p>
<p>-- Enabled vtkCommonCore, needed by [vtkFiltersCore;vtkCommonDataModel;vtkCommonMath;vtkCommonMisc;vtkCommonSystem;vtkCommonTransforms;vtkFiltersGeometry;vtkCommonComputationalGeometry;vtkFiltersSources;vtkFiltersGeneral;vtkImagingCore;vtkIOGeometry;vtkIOImage;vtkIOPLY;vtkIOXML].</p>



<p>-- Enabled vtkCommonMath, needed by [vtkCommonDataModel;vtkCommonMisc;vtkCommonTransforms;vtkFiltersCore;vtkCommonComputationalGeometry;vtkFiltersSources;vtkFiltersGeneral;vtkImagingCore;vtkIOImage].</p>
<p>-- Enabled vtkCommonMisc, needed by [vtkCommonDataModel;vtkFiltersCore;vtkFiltersGeneral;vtkIOGeometry;vtkIOCore;vtkIOImage;vtkIOPLY;vtkIOXML].</p>
<p>-- Enabled vtkCommonSystem, needed by [vtkCommonDataModel;vtkFiltersCore;vtkCommonComputationalGeometry;vtkFiltersGeneral;vtkImagingCore;vtkIOGeometry;vtkIOImage;vtkIOXML].</p>
<p>-- Enabled vtkCommonTransforms, needed by [vtkCommonDataModel;vtkFiltersCore;vtkFiltersSources;vtkFiltersGeneral;vtkImagingCore;vtkIOImage].</p>
<p>-- Enabled vtkCommonDataModel, needed by [vtkFiltersCore;vtkFiltersGeometry;vtkCommonComputationalGeometry;vtkFiltersSources;vtkFiltersGeneral;vtkImagingCore;vtkIOGeometry;vtkIOCore;vtkIOImage;vtkIOPLY;vtkIOXML].</p>
<p>-- Enabled vtkCommonComputationalGeometry, needed by [vtkFiltersSources;vtkFiltersGeneral;vtkImagingCore].</p>
<p>-- Enabled vtkFiltersCore, requested by Module_vtkFiltersCore.</p>
<p>-- Enabled vtkFiltersGeneral, needed by [vtkFiltersSources].</p>
<p>-- Enabled vtkFiltersGeometry, requested by Module_vtkFiltersGeometry.</p>
<p>-- Enabled vtkFiltersSources, requested by Module_vtkFiltersSources.</p>
<p>-- Enabled vtkzlib, needed by [vtkIOCore;vtkIOGeometry;vtkIOImage].</p>
<p>-- Enabled vtkIOCore, needed by [vtkIOGeometry;vtkIOImage;vtkIOPLY;vtkIOXML].</p>
<p>-- Enabled MaterialLibrary, needed by [vtkIOGeometry;vtkIOGeometry].</p>
<p>-- Enabled vtkIOGeometry, requested by Module_vtkIOGeometry.</p>
<p>-- Enabled DICOMParser, needed by [vtkIOImage].</p>
<p>-- Enabled vtkfreetype, needed by [vtkIOImage].</p>
<p>-- Enabled vtkjpeg, needed by [vtkIOImage].</p>
<p>-- Enabled vtkmetaio, needed by [vtkIOImage].</p>
<p>-- Enabled vtkoggtheora, needed by [vtkIOImage].</p>
<p>-- Enabled vtkpng, needed by [vtkIOImage].</p>
<p>-- Enabled vtktiff, needed by [vtkIOImage].</p>
<p>-- Enabled vtkIOImage, requested by Module_vtkIOImage.</p>
<p>-- Enabled vtkIOPLY, requested by Module_vtkIOPLY.</p>
<p>-- Enabled vtkexpat, needed by [vtkIOXML].</p>
<p>-- Enabled vtkIOXML, requested by Module_vtkIOXML.</p>
<p>-- Enabled vtkImagingCore, requested by Module_vtkImagingCore.</p>
<p>-- Configuring done</p>
<p>-- Generating done</p>
<p>-- Build files have been written to: /cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Build/vtkmodular-host</p>
<p>[ 24%] Performing build step for 'vtkmodular-host'</p>
<p>[ 0%] [ 1%] [ 2%] Built target vtkMaterialLibraryConfiguredFiles</p>
<p>Built target vtkzlib</p>
<p>Built target vtksys</p>
<p>[ 2%] Built target vtkDICOMParser</p>
<p>[ 4%] [ 8%] Built target vtkfreetype</p>
<p>[ 11%] Built target vtkjpeg</p>
<p>[ 14%] Built target vtkmetaio</p>
<p>Built target vtkoggtheora</p>
<p>[ 14%] Built target vtkmkg3states</p>
<p>[ 14%] Built target vtkexpat</p>
<p>[ 14%] [ 14%] [ 14%] [ 15%] <font color="#00bf00"><font color="#00bf00">Building CXX object Common/Core/CMakeFiles/vtkCommonCore.dir/vtkUnicodeString.cxx.o</font></font></p>
<p>Built target ProcessShader</p><font color="#00bf00"><font color="#00bf00">
<p>Building CXX object Common/Core/CMakeFiles/vtkCommonCore.dir/vtkUnsignedShortArray.cxx.o</p></font></font>
<p>Built target vtkpng</p>
<p>[ 15%] </p><font color="#00bf00"><font color="#00bf00">Building CXX object Common/Core/CMakeFiles/vtkCommonCore.dir/vtkVariantArray.cxx.o</font></font> 
<p>[ 19%] Built target vtktiff</p>
<p>[ 20%] </p><font color="#00bf00"><font color="#00bf00">Building CXX object Common/Core/CMakeFiles/vtkCommonCore.dir/vtkVariant.cxx.o</font></font> 
<p>/cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Source/vtkmodular/Common/Core/vtkUnicodeString.cxx: In member function ‘vtkUnicodeString vtkUnicodeString::fold_case() const’:</p>
<p>/cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Source/vtkmodular/Common/Core/vtkUnicodeString.cxx:382:5: error: expected primary-expression before ‘for’</p>
<p>/cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Source/vtkmodular/Common/Core/vtkUnicodeString.cxx:382:5: error: expected ‘}’ before ‘for’</p>
<p>/cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Source/vtkmodular/Common/Core/vtkUnicodeString.cxx:382:5: error: expected ‘,’ or ‘;’ before ‘for’</p>
<p>/cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Source/vtkmodular/Common/Core/vtkUnicodeString.cxx:382:54: error: ‘i’ was not declared in this scope</p>
<p>/cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Source/vtkmodular/Common/Core/vtkUnicodeString.cxx:382:60: error: expected ‘;’ before ‘)’ token</p>
<p>/cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Source/vtkmodular/Common/Core/vtkUnicodeString.cxx:465:1: error: expected ‘}’ at end of input</p>
<p>/cygdrive/d/vessource/Apps/Android/CMakeBuild/build/CMakeExternals/Source/vtkmodular/Common/Core/vtkUnicodeString.cxx:465:1: error: expected ‘}’ at end of input</p>
<p>Common/Core/CMakeFiles/vtkCommonCore.dir/build.make:2309: recipe for target `Common/Core/CMakeFiles/vtkCommonCore.dir/vtkUnicodeString.cxx.o' failed</p>
<p>make[5]: *** [Common/Core/CMakeFiles/vtkCommonCore.dir/vtkUnicodeString.cxx.o] Error 1</p>
<p>make[5]: *** Waiting for unfinished jobs....</p>
<p>CMakeFiles/Makefile2:993: recipe for target `Common/Core/CMakeFiles/vtkCommonCore.dir/all' failed</p>
<p>make[4]: *** [Common/Core/CMakeFiles/vtkCommonCore.dir/all] Error 2</p>
<p>Makefile:113: recipe for target `all' failed</p>
<p>make[3]: *** [all] Error 2</p>
<p>CMakeFiles/vtkmodular-host.dir/build.make:105: recipe for target `CMakeExternals/Stamp/vtkmodular-host/vtkmodular-host-build' failed</p>
<p>make[2]: *** [CMakeExternals/Stamp/vtkmodular-host/vtkmodular-host-build] Error 2</p>
<p>CMakeFiles/Makefile2:166: recipe for target `CMakeFiles/vtkmodular-host.dir/all' failed</p>
<p>make[1]: *** [CMakeFiles/vtkmodular-host.dir/all] Error 2</p>
<p>Makefile:72: recipe for target `all' failed</p>
<p>make: *** [all] Error 2</p>
<p>========================================================</p>
<p><font face="arial,helvetica,sans-serif"></font> <font face="arial,helvetica,sans-serif">Any help would be greatly appreciated.</font></p>
<p><font face="arial,helvetica,sans-serif">Regards,</font></p>
<p><font face="arial,helvetica,sans-serif">Sishir</font></p>
<p> </p>
<p> </p></div></div><br><br></div></div>
<div>_______________________________________________<br>Ves mailing list<br><a href="mailto:Ves@public.kitware.com" target="_blank">Ves@public.kitware.com</a><br><a href="http://public.kitware.com/cgi-bin/mailman/listinfo/ves" target="_blank">http://public.kitware.com/cgi-bin/mailman/listinfo/ves</a><br>


<br></div></blockquote></div><br></blockquote></div><br>
</div></div></blockquote></div><br>