Hi Martino,

Thanks for the quick reply

I compiled the (make/ make install)  in the following directory
    /home/nearchos/OpenSceneGraph_Android/make_test
The sample is in another directory
    /home/nearchos/OpenSceneGraph_Android/test_osg2_1

I modified the Android.mk in the /jni folder
    OSG_ANDROID_DIR    := /home/nearchos/OpenSceneGraph_Android/make_test

And i have the following errors

In file included from jni/osgNativeLib.cpp:7:
jni/OsgMainApp.hpp:21:18: error: osg/GL: No such file or directory
jni/OsgMainApp.hpp:22:28: error: osg/GLExtensions: No such file or directory
jni/OsgMainApp.hpp:23:21: error: osg/Depth: No such file or directory
jni/OsgMainApp.hpp:24:23: error: osg/Program: No such file or directory
jni/OsgMainApp.hpp:25:22: error: osg/Shader: No such file or directory
jni/OsgMainApp.hpp:26:20: error: osg/Node: No such file or directory
jni/OsgMainApp.hpp:27:22: error: osg/Notify: No such file or directory
jni/OsgMainApp.hpp:29:24: error: osgText/Text: No such file or directory
jni/OsgMainApp.hpp:31:31: error: osgDB/DatabasePager: No such file or directory
jni/OsgMainApp.hpp:32:26: error: osgDB/Registry: No such file or directory
jni/OsgMainApp.hpp:33:26: error: osgDB/ReadFile: No such file or directory
jni/OsgMainApp.hpp:34:27: error: osgDB/WriteFile: No such file or directory
jni/OsgMainApp.hpp:36:28: error: osgViewer/Viewer: No such file or directory
jni/OsgMainApp.hpp:37:30: error: osgViewer/Renderer: No such file or directory jni/OsgMainApp.hpp:38:41: error: osgViewer/ViewerEventHandlers: No such file or directory jni/OsgMainApp.hpp:40:33: error: osgGA/GUIEventAdapter: No such file or directory jni/OsgMainApp.hpp:41:48: error: osgGA/MultiTouchTrackballManipulator: No such file or directory jni/OsgMainApp.hpp:42:38: error: osgGA/TrackballManipulator: No such file or directory jni/OsgMainApp.hpp:43:35: error: osgGA/FlightManipulator: No such file or directory jni/OsgMainApp.hpp:44:34: error: osgGA/DriveManipulator: No such file or directory jni/OsgMainApp.hpp:45:44: error: osgGA/KeySwitchMatrixManipulator: No such file or directory jni/OsgMainApp.hpp:46:37: error: osgGA/StateSetManipulator: No such file or directory jni/OsgMainApp.hpp:47:42: error: osgGA/AnimationPathManipulator: No such file or directory jni/OsgMainApp.hpp:48:36: error: osgGA/TerrainManipulator: No such file or directory jni/OsgMainApp.hpp:49:38: error: osgGA/SphericalManipulator: No such file or directory
In file included from jni/OsgMainApp.hpp:51,
                 from jni/osgNativeLib.cpp:7:
jni/OsgAndroidNotifyHandler.hpp:17: error: expected initializer before ':' token
In file included from jni/osgNativeLib.cpp:7:
jni/OsgMainApp.hpp:54: error: expected constructor, destructor, or type conversion before '(' token
jni/OsgMainApp.hpp:134: error: 'osg' has not been declared
jni/OsgMainApp.hpp:134: error: ISO C++ forbids declaration of 'ref_ptr' with no type
jni/OsgMainApp.hpp:134: error: expected ';' before '<' token
jni/OsgMainApp.hpp:135: error: 'osg' has not been declared
jni/OsgMainApp.hpp:135: error: ISO C++ forbids declaration of 'ref_ptr' with no type
jni/OsgMainApp.hpp:135: error: expected ';' before '<' token
jni/OsgMainApp.hpp:136: error: 'osg' has not been declared
jni/OsgMainApp.hpp:136: error: ISO C++ forbids declaration of 'ref_ptr' with no type
jni/OsgMainApp.hpp:136: error: expected ';' before '<' token
jni/OsgMainApp.hpp:137: error: 'osg' has not been declared
jni/OsgMainApp.hpp:137: error: ISO C++ forbids declaration of 'ref_ptr' with no type
jni/OsgMainApp.hpp:137: error: expected ';' before '<' token
jni/OsgMainApp.hpp:145: error: ISO C++ forbids declaration of 'OsgAndroidNotifyHandler' with no type
jni/OsgMainApp.hpp:145: error: expected ';' before '*' token
jni/OsgMainApp.hpp:147: error: ISO C++ forbids declaration of 'vector' with no type
jni/OsgMainApp.hpp:147: error: invalid use of '::'
jni/OsgMainApp.hpp:147: error: expected ';' before '<' token
jni/OsgMainApp.hpp:148: error: ISO C++ forbids declaration of 'vector' with no type
jni/OsgMainApp.hpp:148: error: invalid use of '::'
jni/OsgMainApp.hpp:148: error: expected ';' before '<' token
jni/OsgMainApp.hpp:149: error: ISO C++ forbids declaration of 'vector' with no type
jni/OsgMainApp.hpp:149: error: invalid use of '::'
jni/OsgMainApp.hpp:149: error: expected ';' before '<' token
jni/OsgMainApp.hpp:177: error: 'osg' has not been declared
jni/OsgMainApp.hpp:177: error: expected ',' or '...' before 'color'
jni/OsgMainApp.hpp:178: error: 'osg' has not been declared
jni/OsgMainApp.hpp:178: error: ISO C++ forbids declaration of 'Vec4f' with no type
jni/OsgMainApp.hpp:178: error: expected ';' before 'getClearColor'
jni/osgNativeLib.cpp: In function '_jintArray* Java_osg_AndroidExample_osgNativeLib_getClearColor(JNIEnv*, _jobject*)':
jni/osgNativeLib.cpp:58: error: 'osg' has not been declared
jni/osgNativeLib.cpp:58: error: expected ';' before 'vTemp1'
jni/osgNativeLib.cpp:62: error: 'vTemp1' was not declared in this scope
jni/osgNativeLib.cpp: In function 'void Java_osg_AndroidExample_osgNativeLib_setClearColor(JNIEnv*, _jobject*, jint, jint, jint)':
jni/osgNativeLib.cpp:73: error: 'osg' has not been declared
jni/osgNativeLib.cpp:73: error: expected ';' before 'tVec'
jni/osgNativeLib.cpp:74: error: 'tVec' was not declared in this scope
make: *** [obj/local/armeabi/objs/osgNativeLib/osgNativeLib.o] Error 1



On 19/12/11 22:05, [email protected] wrote:
Message: 1
Date: Mon, 19 Dec 2011 00:05:43 +0100
From: rocco martino<[email protected]>
To: OpenSceneGraph Users<[email protected]>
Subject: Re: [osg-users] More Information about the osgAndroid
        Examples 2
Message-ID:
        <CAFHkbs1S=rcqx0dbby2d_sxe7yytojzm80v6kxevm4yu0yt...@mail.gmail.com>
Content-Type: text/plain; charset="iso-8859-1"

Hi, Nearchos,


I think you should edit Android.mk:7


  6  ### Main Install dir
  7  OSG_ANDROID_DIR    :=<  type your install directory>



Martino



2011/12/18 Nearchos<[email protected]>

**
Hello,

I am having trouble compiling the osg examples. I follow the instructions
of the


http://www.openscenegraph.org/projects/osg/wiki/Support/PlatformSpecifics/Android

I downloaded the ndk-version *android-ndk-r7*
OpenScenegraph *OpenSceneGraph-3.0.1*

And i am using linux

  cmake ../OpenSceneGraph-3.0.1/
              -DOSG_BUILD_PLATFORM_ANDROID=ON
              -DDYNAMIC_OPENTHREADS=OFF
              -DDYNAMIC_OPENSCENEGRAPH=OFF
              -DOSG_GL_DISPLAYLISTS_AVAILABLE=OFF
              -DOSG_GL_MATRICES_AVAILABLE=OFF
              -DOSG_GL_VERTEX_FUNCS_AVAILABLE=OFF
              -DOSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE=OFF
              -DOSG_GL_FIXED_FUNCTION_AVAILABLE=OFF
              -DOSG_CPP_EXCEPTIONS_AVAILABLE=OFF
              -DOSG_GL1_AVAILABLE=OFF
              -DOSG_GL2_AVAILABLE=OFF
              -DOSG_GL3_AVAILABLE=OFF
              -DOSG_GLES1_AVAILABLE=OFF
              -DOSG_GLES2_AVAILABLE=ON
              -DCMAKE_BUILD_TYPE=Release

I correct the NDK_PATH with *ccmake .*

And then complete the *make* and *make install *without errors (I also
tried the NDK_BUILD)

Now my problem is when I try to build the Sample Application. I import the
sample in eclipse and try to compile the jni without success
*./OpenSceneGraph-3.0.1/android-ndk-r7/ndk-build
Compile++ thumb  : osgNativeLib<= osgNativeLib.cpp
/bin/sh: cannot open -Itype: No such file
make: ***
[/home/nearchos/OpenSceneGraph_Android/test_osg2_1/obj/local/armeabi/objs/osgNativeLib/osgNativeLib.o]
Error 2
**
*I believe the problem is that i do not include binaries directories in
the eclipse project.
*"After that you need to set up properly your include and binaries
directories."*

Could you please elaborate what should i include?

PS: I also tried to do the procedure in the osgAndroid example (cmake .. /
make / make install) but still i did not manage to run it

Thanks in advance



_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


-------------- next part --------------
An HTML attachment was scrubbed...
URL:<http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20111219/5d178e4e/attachment.html>

------------------------------

_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to