<div dir="ltr">When I added the KiwiNative.cpp and java files to my project and attempted to build it, the 'dynamic_cast' in the vtk SharedPtr caused errors. <div><br></div><div>D:/packages/Android/android-ndk-r8c/sources/cxx-stl/gnu-libstdc++/4.6/include/tr1/shared_ptr.h:625:31: error: 'dynamic_cast' not permitted with -fno-rtti</div>
<div><br></div><div>Reading up on android-ndk-r8c/docs/CPLUSPLUS-SUPPORT.html showed that adding</div><div><br></div><div><div>LOCAL_CPP_FEATURES += rtti</div></div><div><br></div><div>to my own module section in the Android.mk file would fix that - and it did. I can now compile my app.</div>
<div><br></div><div>To actually make it run, I had to fix the bugs in Eigen's Visitor.h file that Eclipse had flagged. Before fixing them, Eclipse would say "Your project contains error(s), please fix them before running your application" and cancel the launch.</div>
<div><br></div><div>One of the bugs is at Visitor.h line 37, around</div><div><br></div><div><div> static inline void run(const Derived &mat, Visitor& visitor)</div><div> {</div><div> return visitor.init(mat.coeff(0, 0), 0, 0);</div>
<div> }</div></div><div><br></div><div>is obviously a true bug, so removing "return" did the job here. At lines 194 and 228, the macro EIGEN_STATIC_ASSERT_VECTOR_ONLY has a definition that uses the undefined macro YOU_TRIED_CALLING_A_VECTOR_METHOD_ON_A_MATRIX, so i just commented that out.</div>
<div><br></div><div>Now it launches.</div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Aug 27, 2013 at 4:19 PM, Candemir Doger <span dir="ltr"><<a href="mailto:cd.doger@gmail.com" target="_blank">cd.doger@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 dir="ltr">Hi Sven,<div><br></div><div>That's correct my intention was to decouple the cmake process from app development. The cmake is only used for building the .a libraries at first. I will try to clean and share the whole project when I have the time.</div>
</div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Aug 27, 2013 at 3:24 PM, Sven Prevrhal <span dir="ltr"><<a href="mailto:sprevrha@gmail.com" target="_blank">sprevrha@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 dir="ltr">I am on Windows and used cmake to build the VES and KIWI Libs and App. Then I followed Candemir's Blog at <a href="http://www.kitware.com/blog/home/post/538" target="_blank">http://www.kitware.com/blog/home/post/538</a> for the Android.mk and the Application.mk file. Then I just used the ndk-build.cmd (via the Eclipse "Build project" context menu), so no cmake here. The way I had interpreted the blog and the whole cmake business was that it was needed to compile the ves libs etc but not the Android app, and the whole point of the blog was to discouple further app development from cmake and use the standard NDK build chain instead. Is that wrong? The generator looks interesting but I am not sure how exactly I need to use it for VES/Kiwi. Anywhere I can read up on it?</div>
<div class="gmail_extra"><div><div><br><br><div class="gmail_quote">On Tue, Aug 27, 2013 at 3:07 PM, Aashish Chaudhary <span dir="ltr"><<a href="mailto:aashish.chaudhary@kitware.com" target="_blank">aashish.chaudhary@kitware.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thanks for notifying us. I am assuming you used cmake eclipse generator? <div><br></div><div>Thanks,</div>
<div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div>On Tue, Aug 27, 2013 at 8:41 AM, Sven Prevrhal <span dir="ltr"><<a href="mailto:sprevrha@gmail.com" target="_blank">sprevrha@gmail.com</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr"><span style="color:rgb(119,119,119);font-family:Arial,sans-serif;font-size:11px;line-height:16.1875px">When I actually tried #include'ing the vesKiwiViewerApp.h in my own cpp file, build showed the error below. I fixed it by adding $(LOCAL_PATH)/eigen to the LOCAL_C_INCLUDES. </span><br clear="all">
<div><br></div><div><div>D:\packages\Android\android-ndk-r9\ndk-build.cmd all </div><div>"Compile++ thumb : MyFirstAndroidNativeAppFromScratch <= MyFirstAndroidNativeAppFromScratch.cpp</div><div>In file included from jni/ves-android/include/ves/ves/vesMath.h:24:0,</div>
<div> from jni/ves-android/include/ves/kiwi/vesKiwiBaseApp.h:30,</div><div> from jni/ves-android/include/ves/kiwi/vesKiwiViewerApp.h:25,</div><div> from jni/MyFirstAndroidNativeAppFromScratch.cpp:5:</div>
<div>jni/ves-android/include/ves/ves/vesEigen.h:30:23: fatal error: Eigen/Dense: No such file or directory</div><div>compilation terminated.</div><div>make: *** [obj/local/armeabi/objs/MyFirstAndroidNativeAppFromScratch/MyFirstAndroidNativeAppFromScratch.o] Error 1</div>
</div><br>
</div>
<br></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></blockquote></div><span><font color="#888888"><br><br clear="all"><div><br></div>-- <br>| Aashish Chaudhary <br>| R&D Engineer <br>| Kitware Inc. <br>| <a href="http://www.kitware.com" target="_blank">www.kitware.com</a>
</font></span></div>
</blockquote></div><br><br clear="all"><div><br></div></div></div><span><font color="#888888">-- <br>--<div>Sven</div>
</font></span></div>
<br>_______________________________________________<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></blockquote></div><br></div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br>--<div>Sven</div>
</div>