Re: [osg-users] HELP~OSG forAndroid crashed~~~
Jan Ciger wrote: Hello Houhouh (sorry if that isn't your name, but you didn't provide one ...), You haven't provided the ABI you have compiled for, but seeing that your device has Tegra 2 SoC, I suspect that the crash comes from the lack of support for the Neon instructions on it. These are similar to the SSE instructions on x86, unfortunately they are an optional part of the ARM specification, so not all vendors implement them. Nvidia chose not to and thus Tegra 2 doesn't have them :( (however, the newer Tegra 3 does, go figure ...) You can solve this either by switching to the v5 ABI (armeabi instead of armeabi-v7a in your Application.mk file) that doesn't use Neon or by disabling Neon instructions and recompiling OSG again. I believe this is actually documented in the Android part of the website too. Regards, Jan -- Post generated by Mail2Forum Hello,Jan i am sorry that didnot say it clear : Android NDK: Building application 'local' for ABI 'armeabi' Android NDK: Using target toolchain 'arm-linux-androideabi-4.4.3' for 'armeabi' ABI i have compiled for ABI 'armeabi'. i followed the cookbook and commented LOCAL_ARM_NEON := true in PlatformSpecifics\Android\Android.mk.modules.in and commented armeabi-v7aalso in .mk file both in cmake build folder or osgAndroidExampleGLES1/jni/ Application.mk So,did i disable the Neon instructions clean? i used cygwin to build the whole work,and i used CMAKE commond as shows follow and NDK version is r7: cmake .. -DOSG_BUILD_PLATFORM_ANDROID=ON -DDYNAMIC_OPENTHREADS=OFF -DDYNAMIC_OPENSCENEGRAPH=OFF -DOSG_GL_DISPLAYLISTS_AVAILABLE=OFF -DOSG_GL_MATRICES_AVAILABLE=ON -DOSG_GL_VERTEX_FUNCS_AVAILABLE=ON -DOSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE=ON -DOSG_GL_FIXED_FUNCTION_AVAILABLE=ON -DOSG_CPP_EXCEPTIONS_AVAILABLE=OFF -DOSG_GL1_AVAILABLE=OFF -DOSG_GL2_AVAILABLE=OFF -DOSG_GL3_AVAILABLE=OFF -DOSG_GLES1_AVAILABLE=ON -DOSG_GLES2_AVAILABLE=OFF -DJ=4 -DANDROID_NDK=$NDK -DANDROID_STL=gnustl_static -DCMAKE_INSTALL_PREFIX=/cygdrive/c/cygwin/usr/local/osgNOneon Now,the statuation is that the apk can run normally,NOT crashed at once.Then , it will crash anytime.The apk is unstatble for use. i was disturbed by this bug for a month , thank you very much! -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=50827#50827 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] HELP~OSG forAndroid crashed~~~
Hello, On Mon, Oct 29, 2012 at 2:39 AM, wang xinyu houh...@163.com wrote: Hello,Jan i am sorry that didnot say it clear : Android NDK: Building application 'local' for ABI 'armeabi' Android NDK: Using target toolchain 'arm-linux-androideabi-4.4.3' for 'armeabi' ABI OK, that should be all right. i have compiled for ABI 'armeabi'. i followed the cookbook and commented LOCAL_ARM_NEON := true in PlatformSpecifics\Android\Android.mk.modules.inand commented armeabi-v7aalso in .mk file both in cmake build folder or osgAndroidExampleGLES1/jni/ Application.mk So,did i disable the Neon instructions clean? Actually, if you are compiling only for armeabi, you didn't have to disable Neon because armeabi doesn't support those instructions anyway. Only armeabi-v7a can use them. i used cygwin to build the whole work,and i used CMAKE commond as shows follow and NDK version is r7: cmake .. -DOSG_BUILD_PLATFORM_ANDROID=ON -DDYNAMIC_OPENTHREADS=OFF -DDYNAMIC_OPENSCENEGRAPH=OFF -DOSG_GL_DISPLAYLISTS_AVAILABLE=OFF -DOSG_GL_MATRICES_AVAILABLE=ON -DOSG_GL_VERTEX_FUNCS_AVAILABLE=ON -DOSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE=ON -DOSG_GL_FIXED_FUNCTION_AVAILABLE=ON -DOSG_CPP_EXCEPTIONS_AVAILABLE=OFF -DOSG_GL1_AVAILABLE=OFF -DOSG_GL2_AVAILABLE=OFF -DOSG_GL3_AVAILABLE=OFF -DOSG_GLES1_AVAILABLE=ON -DOSG_GLES2_AVAILABLE=OFF -DJ=4 -DANDROID_NDK=$NDK -DANDROID_STL=gnustl_static -DCMAKE_INSTALL_PREFIX=/cygdrive/c/cygwin/usr/local/osgNOneon Looks good to me. Now,the statuation is that the apk can run normally,NOT crashed at once.Then , it will crash anytime.The apk is unstatble for use. Well, that can be a different issue. If the app starts and loads a model, then you have resolved the ABI/Neon issues. For me it started up and crashed the moment I touched the screen if the Neon was enabled on the Tegra 2 tablet I have here (Acer Iconia 500). Once Neon was off and everything recompiled, it works fine and stable. I would suggest updating your NDK too, the latest is r8b. They often fix really showstopper bugs, so if you are getting crashes with an unmodified OSG example, that could help you. i was disturbed by this bug for a month , thank you very much! You are welcome. Jan ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] HELP~OSG forAndroid crashed~~~
hi,everyone here i have built OSG for Android and complie the example osgAndroidExampleGLES1.I load a earth model it runs sucessfully.But it crashed unexpected.Log as showed follow: 10-25 15:57:03.710: INFO/DEBUG(1732): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** 10-25 15:57:03.710: INFO/DEBUG(1732): Build fingerprint: 'samsung/GT-P7510/GT-P7510:3.1/HMJ37/ZCKH1:user/release-keys' 10-25 15:57:03.710: INFO/DEBUG(1732): pid: 2227, tid: 2235 osg.AndroidExample 10-25 15:57:03.710: INFO/DEBUG(1732): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 10-25 15:57:03.710: INFO/DEBUG(1732): r0 0032a2a0 r1 002f9300 r2 r3 0032a2a0 10-25 15:57:03.710: INFO/DEBUG(1732): r4 00329cc0 r5 839e4f7d r6 83e47168 r7 40183f58 10-25 15:57:03.710: INFO/DEBUG(1732): r8 5ec4ab70 r9 40183f50 10 40183f3c fp fe90 10-25 15:57:03.710: INFO/DEBUG(1732): ip 83677215 sp 5ec4aa58 lr 83b7c8c3 pc cpsr 0010 10-25 15:57:03.710: INFO/DEBUG(1732): d0 3de5d93a5acfd57c d1 10-25 15:57:03.710: INFO/DEBUG(1732): d2 be5ae56481ee2cda d3 bfc55228f9fedc91 10-25 15:57:03.710: INFO/DEBUG(1732): d4 3f548882600be91f d5 3f810fdb8fcd2457 10-25 15:57:03.710: INFO/DEBUG(1732): d6 3fbb8c153257d559 d7 3fbb8c153257d559 10-25 15:57:03.710: INFO/DEBUG(1732): d8 d9 10-25 15:57:03.710: INFO/DEBUG(1732): d10 d11 10-25 15:57:03.710: INFO/DEBUG(1732): d12 d13 10-25 15:57:03.710: INFO/DEBUG(1732): d14 d15 10-25 15:57:03.710: INFO/DEBUG(1732): scr 2012 10-25 15:57:03.980: INFO/DEBUG(1732): #00 pc 10-25 15:57:03.980: INFO/DEBUG(1732): #01 pc 00b7c8c0 /data/data/osg.AndroidExample/lib/libosgNativeLib.so (_ZN3osg5Group8traverseERNS_11NodeVisitorE) 10-25 15:57:03.980: INFO/DEBUG(1732): #02 pc 00689590 /data/data/osg.AndroidExample/lib/libosgNativeLib.so (_ZN3osg11NodeVisitor8traverseERNS_4NodeE) 10-25 15:57:03.980: INFO/DEBUG(1732): #03 pc 00ae9ce8 /data/data/osg.AndroidExample/lib/libosgNativeLib.so (_ZN7osgUtil13UpdateVisitor29handle_callbacks_and_traverseERN3osg4NodeE) 10-25 15:57:03.980: INFO/DEBUG(1732): #04 pc 00ae9bd0 /data/data/osg.AndroidExample/lib/libosgNativeLib.so (_ZN7osgUtil13UpdateVisitor5applyERN3osg5GroupE) 10-25 15:57:03.980: INFO/DEBUG(1732): #05 pc 009aa686 /data/data/osg.AndroidExample/lib/libosgNativeLib.so (_ZN3osg5Group6acceptERNS_11NodeVisitorE) 10-25 15:57:03.980: INFO/DEBUG(1732): #06 pc 0088f4b6 /data/data/osg.AndroidExample/lib/libosgNativeLib.so (_ZN9osgViewer5Scene16updateSceneGraphERN3osg11NodeVisitorE) 10-25 15:57:03.980: INFO/DEBUG(1732): libc base address: aff0 10-25 15:57:03.980: INFO/DEBUG(1732): code around pc: 10-25 15:57:03.980: INFO/DEBUG(1732): 10-25 15:57:03.980: INFO/DEBUG(1732): 0010 10-25 15:57:03.980: INFO/DEBUG(1732): 0020 10-25 15:57:03.980: INFO/DEBUG(1732): 0030 10-25 15:57:03.980: INFO/DEBUG(1732): 0040 10-25 15:57:03.980: INFO/DEBUG(1732): code around lr: 10-25 15:57:03.980: INFO/DEBUG(1732): 83b7c8a0 e0129303 1c18ab03 f904f673 1c181c03 10-25 15:57:03.980: INFO/DEBUG(1732): 83b7c8b0 ebf0f6b7 681a1c03 6812326c 1c189900 10-25 15:57:03.980: INFO/DEBUG(1732): 83b7c8c0 ab034790 f6551c18 9b01fa75 1c183374 10-25 15:57:03.980: INFO/DEBUG(1732): 83b7c8d0 f9f2f655 93021c03 ab02aa03 1c191c10 10-25 15:57:03.980: INFO/DEBUG(1732): 83b7c8e0 fa50f655 2b001c03 b005d1dc 46c0bd00 10-25 15:57:03.980: INFO/DEBUG(1732): stack: 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa18 839d06a5 /data/data/osg.AndroidExample/lib/libosgNativeLib.so 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa1c 5ec4aa48 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa20 83e321a8 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa24 839d0bad /data/data/osg.AndroidExample/lib/libosgNativeLib.so 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa28 8c7bf078 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa2c 0004ccdd 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa30 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa34 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa38 002fa570 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa3c 5ec4aa4c 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa40 83e321a8 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa44 5ec4aa60 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa48 5ec4aa60 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa4c 5ec4aa64 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa50 df002777 10-25 15:57:03.980: INFO/DEBUG(1732): 5ec4aa54 e3a070ad 10-25 15:57:03.980:
Re: [osg-users] HELP~OSG forAndroid crashed~~~
Hello Houhouh (sorry if that isn't your name, but you didn't provide one ...), On Thu, Oct 25, 2012 at 10:27 AM, houhouh houh...@163.com wrote: 10-25 15:57:03.710: INFO/DEBUG(1732): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr You haven't provided the ABI you have compiled for, but seeing that your device has Tegra 2 SoC, I suspect that the crash comes from the lack of support for the Neon instructions on it. These are similar to the SSE instructions on x86, unfortunately they are an optional part of the ARM specification, so not all vendors implement them. Nvidia chose not to and thus Tegra 2 doesn't have them :( (however, the newer Tegra 3 does, go figure ...) You can solve this either by switching to the v5 ABI (armeabi instead of armeabi-v7a in your Application.mk file) that doesn't use Neon or by disabling Neon instructions and recompiling OSG again. I believe this is actually documented in the Android part of the website too. Regards, Jan ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] HELP~OSG forAndroid crashed~~~
Hello again, On Thu, Oct 25, 2012 at 10:27 AM, houhouh houh...@163.com wrote: In forums have a similar question ,but it didn't work. http://forum.open scenegraph.org/viewtopic.php?t=8959postdays=0postorder=aschighlight=androidstart=15 Did anyone have encountered the similar error~or anyone who can help me to solve it~~i test the apk on a samsung pad ,and build the example only for armeabi ,unused Neon extensions!Thank you ~ For me what helped to solve this was to recompile *whole OSG*, not only the example only for armeabi. Unfortunately, the NDK build system is a bit strange, really fragile and sometimes wrong versions of the libraries gets picked, so it is possible that it has linked in an incorrect library file. Also, if you were doing multiple builds with/without Neon, armeabi-v7a, etc. make sure to use a clean folder for the compilation, to avoid any stale files. Jan ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org