<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi Pat,<div><br></div><div>Thanks for you reply. I think that the only way to debug native code into eclipse is using the Android.mk file. I will configure Android.mk by hand and set all dependencies.</div><div><br></div><div>About TestKiwiImage.cpp:</div><div><br></div><div><blockquote type="cite"><div><blockquote type="cite">About the TestKiwiImage.cpp, I've had some troubles to compile the<br></blockquote><blockquote type="cite">VES_HOST_SUPERBUILD. I got some errors ( OpenGLES/ES2/gl.h file not found).<br></blockquote><blockquote type="cite">I thought that the GL library are including in Xcode 4.4<br></blockquote><blockquote type="cite">Where can I find just the file TestKiwiImage.cpp ?</blockquote></div></blockquote><div><br></div><br><div>
<span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-style: normal; font-weight: normal; font-size: medium; font-family: Helvetica; color: rgb(0, 0, 0); "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; font-variant: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-weight: normal; font-style: normal; "><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-weight: normal; font-style: normal; ">Thanks.</div><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-weight: normal; font-style: normal; ">__________________________________<br><font class="Apple-style-span" color="#b7bfc5">|</font> Ariel Hernán Curiale Ph.D Student<br><font class="Apple-style-span" color="#b7bfc5">|</font> ETSI Telecomunicación<br><font class="Apple-style-span" color="#b7bfc5">|</font> Universidad de Valladolid<br><font class="Apple-style-span" color="#b7bfc5">|</font> Campus Miguel Delibes<br><font class="Apple-style-span" color="#b7bfc5">|</font> 47011 Valladolid, Spain<br><font class="Apple-style-span" color="#b7bfc5">|</font> Phone: 983-423000 ext. 5590</div><div><font class="Apple-style-span" color="#b7b7b7" style="font-family: Helvetica; font-size: medium; font-weight: normal; font-style: normal; ">|</font> Web: <a href="http://www.curiale.com.ar/"><font class="Apple-style-span" color="#084ebe">www.curiale.com.ar</font></a><br><font class="Apple-style-span" color="#b7b7b7" style="font-family: Helvetica; font-size: medium; font-weight: normal; font-style: normal; ">|</font><span class="Apple-style-span" style="font-family: Helvetica; font-size: medium; font-weight: normal; font-style: normal; color: rgb(0, 0, 0); ">_________________________________</span></div></div></div></div></span></div></span></div></span></div></span></div></span></div></span></div></span></div></span></div></span></div></span></span>
</div>
<br><div><div>El 26/11/2012, a las 00:31, Pat Marion escribió:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>CMake is a replacement for Android.mk files and ndk-build.  CMake is<br>used to compile the VTK and VES libraries in a cross platform way, so<br>that they can be built for iOS, Android, and host architectures.<br><br>The file you are talking about is<br>Apps/Android/Kiwi/jni/KiwiNative.cpp.  This file is not part of the<br>VES cross platform library, it is part of the KiwiViewer app for<br>Android.  A CMakeLists.txt is provided to compile KiwiNative.cpp as a<br>shared library so that it may be loaded as a JNI library by the Kiwi<br>Java app.  Instead of using CMake to compile KiwiNative.cpp, you could<br>write an Android.mk file and use ndk-build, that will work fine.  The<br>reason that CMake is preferred is because it makes it easier to lookup<br>the required VES and VTK include dirs and libraries to link the JNI<br>shared library.  But, you could also list these things in an<br>Android.mk file and then use ndk-build.<br><br>Pat<br><br>On Sun, Nov 25, 2012 at 11:27 PM, Ariel Hernán Curiale<br><<a href="mailto:curiale@gmail.com">curiale@gmail.com</a>> wrote:<br><blockquote type="cite">Hi Pat,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">About the native compilation, I don't understand a few points:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">1) According to the NDK-GDB.html provided by android-ndk-r8b I need to<br></blockquote><blockquote type="cite">compile the .cxx files using the script 'ndk-build'. I'm using a modified<br></blockquote><blockquote type="cite">version of the script configure_cmake included into the Kiwi App.<br></blockquote><blockquote type="cite">In particular I modified this script to create a eclipse project. I use this<br></blockquote><blockquote type="cite">script:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">$CMAKE -DCMAKE_ECLIPSE_EXECUTABLE="/Applications/eclipse"\<br></blockquote><blockquote type="cite">       -DCMAKE_ECLIPSE_VERSION="4.2 (Juno)"\<br></blockquote><blockquote type="cite">       -DCMAKE_TOOLCHAIN_FILE=$TOOLCHAIN\<br></blockquote><blockquote type="cite">       -DANDROID_NATIVE_API_LEVEL=8\<br></blockquote><blockquote type="cite">       -DCMAKE_BUILD_TYPE="Debug"\<br></blockquote><blockquote type="cite">       -DVTK_DIR=$VTK_DIR\<br></blockquote><blockquote type="cite">       -DVES_DIR=$VES_DIR\<br></blockquote><blockquote type="cite">       -G "Eclipse CDT4 - Unix Makefiles"\<br></blockquote><blockquote type="cite">       $eclipse_dir<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">This script configure properly the dependencies of the ves library but I<br></blockquote><blockquote type="cite">think that this script configure eclipse to use the make command instead<br></blockquote><blockquote type="cite">ndk-build to compile the .cxx.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Is there a way to use cmake to configure the ves libraries and use the<br></blockquote><blockquote type="cite">ndk-build to compile the .cxx ?<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">2) According to all the tutorials that I read, including your<br></blockquote><blockquote type="cite">recommendation,  them use the file Android.mk to configure and build .cxx<br></blockquote><blockquote type="cite">files.<br></blockquote><blockquote type="cite">When I use cmake to create the project, cmake configure all files  and I<br></blockquote><blockquote type="cite">don't need to use the Android.mk. Indeed I think that I must not create the<br></blockquote><blockquote type="cite">Android.mk file because I use the cmake to configure the way to compile the<br></blockquote><blockquote type="cite">.cxx files.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I'm a bit confuse about if the cmake is configured to use ndk-build to<br></blockquote><blockquote type="cite">build the .cxx or if its just use the make command.<br></blockquote><blockquote type="cite">How can I use ndk-build instead of make ?<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I know how to compile and debug native libraries using Android.mk but I<br></blockquote><blockquote type="cite">don't know how to merge this with the configuration created by the cmake.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">About the TestKiwiImage.cpp, I've had some troubles to compile the<br></blockquote><blockquote type="cite">VES_HOST_SUPERBUILD. I got some errors ( OpenGLES/ES2/gl.h file not found).<br></blockquote><blockquote type="cite">I thought that the GL library are including in Xcode 4.4<br></blockquote><blockquote type="cite">Where can I find just the file TestKiwiImage.cpp ?<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Thanks a lot.<br></blockquote><blockquote type="cite">__________________________________<br></blockquote><blockquote type="cite">| Ariel Hernán Curiale Ph.D Student<br></blockquote><blockquote type="cite">| ETSI Telecomunicación<br></blockquote><blockquote type="cite">| Universidad de Valladolid<br></blockquote><blockquote type="cite">| Campus Miguel Delibes<br></blockquote><blockquote type="cite">| 47011 Valladolid, Spain<br></blockquote><blockquote type="cite">| Phone: 983-423000 ext. 5590<br></blockquote><blockquote type="cite">| Web: <a href="http://www.curiale.com.ar">www.curiale.com.ar</a><br></blockquote><blockquote type="cite">|_________________________________<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">El 19/11/2012, a las 08:53, Pat Marion escribió:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Hi Ariel,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">You should use CMAKE_BUILD_TYPE=Debug, which will pass the<br></blockquote><blockquote type="cite">CMAKE_CXX_FLAGS_DEBUG to the compiler.  If you need to add additional flags,<br></blockquote><blockquote type="cite">you can modify that variable.  If you want to debug native code on android<br></blockquote><blockquote type="cite">using the ndk gdb, you could try following some tutorials like this one:<br></blockquote><blockquote type="cite"><a href="http://vilimpoc.org/blog/2010/09/23/hello-gdbserver-a-debuggable-jni-example-for-android/">http://vilimpoc.org/blog/2010/09/23/hello-gdbserver-a-debuggable-jni-example-for-android/</a><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Pat<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">On Sun, Nov 18, 2012 at 5:22 AM, Ariel Hernán Curiale <<a href="mailto:curiale@gmail.com">curiale@gmail.com</a>><br></blockquote><blockquote type="cite">wrote:<br></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Hi all,<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">I did a native library and I want to debug it. I know how to do this using<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">eclipse and Android.mk but using VES I have some scripts to create and<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">configure the project . Also, I have some CMakeLists.txt and I don't know<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">how to set properly the debugger.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">I tried to set using the flag CMAKE_BUILD_TYPE<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">(-DCMAKE_BUILD_TYPE="Debug") but nothing.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">If anyone knows how to debug a native library built using VES please tell<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">me how can I debug it.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Thanks,<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">__________________________________<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">| Ariel Hernán Curiale Ph.D Student<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">| ETSI Telecomunicación<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">| Universidad de Valladolid<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">| Campus Miguel Delibes<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">| 47011 Valladolid, Spain<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">| Phone: 983-423000 ext. 5590<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">| Web: <a href="http://www.curiale.com.ar">www.curiale.com.ar</a><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">|_________________________________<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">_______________________________________________<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Ves mailing list<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><a href="mailto:Ves@public.kitware.com">Ves@public.kitware.com</a><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><a href="http://public.kitware.com/cgi-bin/mailman/listinfo/ves">http://public.kitware.com/cgi-bin/mailman/listinfo/ves</a><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote></div></blockquote></div><br></div></body></html>