Error in recent change for Java component

Discussion of issues specific to mobile platforms such as iOS, Android, Symbian and Meego.
Post Reply
redpearl
Gnoblar
Posts: 17
Joined: Tue Nov 28, 2017 12:19 am

Error in recent change for Java component

Post by redpearl » Tue Feb 13, 2018 1:24 am

I have successfully built and used Ogre for Android on one machine. However, when I cloned the latest Ogre in a new machine and built it, I met errors in Java component:

In file included from /usr1/AR/ogre/OgreMain/include/Ogre.h:71:0,
from /usr1/AR/ogre/build/java/src/org/Ogre/OgreJAVA_wrap.cxx:431:
/usr1/AR/ogre/OgreMain/include/OgreInstanceManager.h: In function 'jlong Java_org_Ogre_OgreJNI_InstanceManager_1getInstanceBatchMapIterator(JNIEnv*, jclass, jlong, jobject)':
/usr1/AR/ogre/OgreMain/include/OgreInstanceManager.h:98:53: error: 'typedef Ogre::vector<Ogre::InstanceBatch*>::type Ogre::InstanceManager::InstanceBatchVec' is private
typedef vector<InstanceBatch*>::type InstanceBatchVec; //vec[batchN] = Batch
^
/usr1/AR/ogre/build/java/src/org/Ogre/OgreJAVA_wrap.cxx:203729:3: error: within this context
SwigValueWrapper< Ogre::ConstMapIterator< Ogre::map< Ogre::String,Ogre::InstanceManager::InstanceBatchVec,std::less< Ogre::String > >::type > > result;
^
[ 85%] Building CXX object Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainMaterialShaderHelperGLSL.cpp.o
[ 85%] Building CXX object Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainMaterialShaderHelperHLSL.cpp.o
[ 85%] Building CXX object Components/Terrain/CMakeFiles/OgreTerrain.dir/src/OgreTerrainQuadTreeNode.cpp.o
[ 85%] Built target pch_Generate_OgreMeshLodGenerator
Scanning dependencies of target OgreMeshLodGenerator
make[2]: *** [Components/Java/CMakeFiles/OgreJNI.dir/__/__/java/src/org/Ogre/OgreJAVA_wrap.cxx.o] Error 1
make[1]: *** [Components/Java/CMakeFiles/OgreJNI.dir/all] Error 2

Can anyone tell me how to fix it? Thanks!
0 x

paroj
OGRE Team Member
OGRE Team Member
Posts: 573
Joined: Sun Mar 30, 2014 2:51 pm
x 83
Contact:

Re: Error in recent change for Java component

Post by paroj » Wed Feb 14, 2018 2:54 am

master builds on CI at least:
https://travis-ci.org/OGRECave/ogre/jobs/340176548

note the updated swig version to 3.0.8. In doubt make a clean built as swig sometimes does not re-parse the source headers.
0 x

redpearl
Gnoblar
Posts: 17
Joined: Tue Nov 28, 2017 12:19 am

Re: Error in recent change for Java component

Post by redpearl » Thu Feb 15, 2018 1:19 am

Ah, yes, upgrade SWIG to 3.0.12 resolved the problem.
0 x

MichaelMinor
Gnoblar
Posts: 1
Joined: Tue May 15, 2018 2:34 pm

Re: Error in recent change for Java component

Post by MichaelMinor » Tue May 15, 2018 2:36 pm

redpearl wrote:
Thu Feb 15, 2018 1:19 am
Ah, yes, upgrade SWIG to 3.0.12 resolved the problem.
nice, that is what I was need :!:
0 x

Post Reply