Compile problems with OGRE 1.7.1

Bunz

03-06-2010 01:48:18

Hi,

I'm new here, so apologies if this is a query that's already been well and truly dealt with.. :)

I'm trying to compile SVN with OGRE 1.7.1, using g++ 4.4.3, but I'm coming up against many errors.

Is this plugin known not to work with 1.7.1, or do I have some environmental issues? All the problems for far have been type compatibility issues, some of which can be made to compile with a simple typecast.

Any info would be appreciated. Thanks.

Bunz

03-06-2010 02:05:08

Err... never mind. I just read the post below regarding whether it's being actively maintained. Never mind.

nevarim

06-12-2010 21:25:31

hi all

i'm trying to compile plsm2 with ogre 1.7.1 and i find impossible to compile,

here there are code log making all necessary includes with vc10 and xp system sp3

http://nevarim.net/upload/log.txt

i have charged it on ftp because its too long fo 1 single post :D

nevarim

07-12-2010 14:21:48

found resolution


modify in




std::vector<Ogre::String> in Ogre::StringVector and LodDistanceList in LodValueList


and it go :D

nevarim

07-12-2010 16:16:44

for mapper...

the file noise.h and interp.h are here
http://libnoise.sourceforge.net/downloads/index.html

nevarim

10-12-2010 10:42:36

nothing to do....... too much problems anyone can help me? there is a solution?

nevarim

09-02-2011 13:09:26

i never compile it with success

jackun

03-03-2011 19:03:12

Ugh, dirty attempt if someone finds it useful. Built on linux, dont know if it actually works though yet.


Index: PlugIns/PagingLandScape2/include/OgrePagingLandScapeOptions.h
===================================================================
--- PlugIns/PagingLandScape2/include/OgrePagingLandScapeOptions.h (revision 2979)
+++ PlugIns/PagingLandScape2/include/OgrePagingLandScapeOptions.h (working copy)
@@ -158,7 +158,7 @@
Vector3 scale;
Vector3 invScale;

- Material::LodDistanceList lodMaterialDistanceList; //Distance for the material LOD change
+ Material::LodValueList lodMaterialDistanceList; //Distance for the material LOD change
Real distanceLOD; //Distance for the LOD change
Real LOD_factor;
bool roughnessLod;
Index: PlugIns/PagingLandScape2/include/OgrePagingLandScapeSceneManager.h
===================================================================
--- PlugIns/PagingLandScape2/include/OgrePagingLandScapeSceneManager.h (revision 2979)
+++ PlugIns/PagingLandScape2/include/OgrePagingLandScapeSceneManager.h (working copy)
@@ -21,7 +21,7 @@
#include "OgrePagingLandScapePrerequisites.h"

#ifndef _PLSM_OCTREE
- #include "OgreOctreeSceneManager.h"
+ #include "Plugins/OctreeSceneManager/OgreOctreeSceneManager.h"
#else //_PLSM_OCTREE
#include "OgrePagingLandScapeOctreeSceneManager.h"
#endif //_PLSM_OCTREE
Index: PlugIns/PagingLandScape2/src/OgrePagingLandScapeOptions.cpp
===================================================================
--- PlugIns/PagingLandScape2/src/OgrePagingLandScapeOptions.cpp (revision 2979)
+++ PlugIns/PagingLandScape2/src/OgrePagingLandScapeOptions.cpp (working copy)
@@ -501,13 +501,13 @@
(StringUtil::endsWith(mapName, ".cfg", true) ? StringUtil::BLANK : String(".cfg")));
if (!cfgGroupName.empty ())
{
- std::vector<Ogre::String>::iterator itFileSystem = mResourceFilesystem.begin();
+ Ogre::StringVector::iterator itFileSystem = mResourceFilesystem.begin();
for(; itFileSystem != mResourceFilesystem.end(); ++itFileSystem)
{
ResourceGroupManager::getSingleton().removeResourceLocation(
*itFileSystem, cfgGroupName);
}
- std::vector<Ogre::String>::iterator itZip = mResourceZip.begin();
+ Ogre::StringVector::iterator itZip = mResourceZip.begin();
for(; itZip != mResourceZip.end(); ++itZip)
{
ResourceGroupManager::getSingleton().removeResourceLocation(
@@ -695,7 +695,7 @@

//add Resources Group to Ogre if needed.
StringVector mResourceFilesystem = mConfig->getMultiSetting("FileSystem");
- std::vector<Ogre::String>::iterator itFileSystem = mResourceFilesystem.begin();
+ Ogre::StringVector::iterator itFileSystem = mResourceFilesystem.begin();
for(; itFileSystem != mResourceFilesystem.end(); ++itFileSystem)
{
String resourceFileSystem = *itFileSystem;
@@ -733,7 +733,7 @@


StringVector mResourceZip = mConfig->getMultiSetting("Zip");
- std::vector<Ogre::String>::iterator itZip = mResourceZip.begin();
+ Ogre::StringVector::iterator itZip = mResourceZip.begin();
for(; itZip != mResourceZip.end(); ++itZip)
{
String resourceZip = *itZip;
@@ -1702,7 +1702,7 @@
{
// name to pageX, uint pageZ, uint tileX, uint tileZ
{
- std::vector<String> coordinates = StringUtil::split(name, "_");
+ StringVector coordinates = StringUtil::split(name, "_");

const uint pageX = StringConverter::parseUnsignedInt(coordinates[0]);
const uint pageZ = StringConverter::parseUnsignedInt(coordinates[1]);
@@ -1714,7 +1714,7 @@

// name to LOD roughness value.
{
- std::vector<String> minLevelDistSqr = StringUtil::split(value, "_");
+ StringVector minLevelDistSqr = StringUtil::split(value, "_");
PLSM2_ASSERT (minLevelDistSqr.size () == numLod);

t->mMinLevelDistSqr = new std::vector<Real>();
Index: PlugIns/PagingLandScape2/src/OgrePagingLandScapeOctreeNode.cpp
===================================================================
--- PlugIns/PagingLandScape2/src/OgrePagingLandScapeOctreeNode.cpp (revision 2979)
+++ PlugIns/PagingLandScape2/src/OgrePagingLandScapeOctreeNode.cpp (working copy)
@@ -187,7 +187,7 @@
_addBoundingBoxToQueue(queue);

if ( mCreator->getDisplaySceneNodes())
- queue -> addRenderable( this );
+ queue -> addRenderable((Renderable*) this );

}
//-----------------------------------------------------------------------
Index: PlugIns/PagingLandScape2/src/OgrePagingLandScapeRenderable.cpp
===================================================================
--- PlugIns/PagingLandScape2/src/OgrePagingLandScapeRenderable.cpp (revision 2979)
+++ PlugIns/PagingLandScape2/src/OgrePagingLandScapeRenderable.cpp (working copy)
@@ -568,7 +568,7 @@
&& mMaterial->getNumLodLevels(MaterialManager::getSingleton()._getActiveSchemeIndex()) > 1
)
{
- const unsigned short LODIndex = mMaterial->getLodIndexSquaredDepth (mDistanceToCam);
+ const unsigned short LODIndex = mMaterial->getLodIndex (mDistanceToCam*mDistanceToCam);
if (LODIndex != mMaterialLODIndex)
mMaterialLODIndex = LODIndex;
}
Index: PlugIns/PagingLandScape2/src/OgrePagingLandScapeOctreeSceneManager.cpp
===================================================================
--- PlugIns/PagingLandScape2/src/OgrePagingLandScapeOctreeSceneManager.cpp (revision 2979)
+++ PlugIns/PagingLandScape2/src/OgrePagingLandScapeOctreeSceneManager.cpp (working copy)
@@ -1147,7 +1147,7 @@


mDestRenderSystem->setCurrentPassIterationCount(1);

_setPass(r->getMaterial()->getBestTechnique()->getPass(0));

- useRenderableViewProjMode (r);

+ useRenderableViewProjMode (r, false);



RenderOperation ro;

r->getRenderOperation (ro);

Index: Tools/MapSplitter/src/MapSplitter.cpp
===================================================================
--- Tools/MapSplitter/src/MapSplitter.cpp (revision 2979)
+++ Tools/MapSplitter/src/MapSplitter.cpp (working copy)
@@ -251,7 +251,7 @@
String pure_file_name;

// Get codec according to filename extension
- std::vector< String > partofname = StringUtil::split (filename, ".");
+ StringVector partofname = StringUtil::split (filename, ".");
String ext_name;

if (partofname.size() <= 1)
@@ -450,7 +450,7 @@
String FileNameRaw;

// Get codec according to filename extension
- std::vector< String > partofname = StringUtil::split (filename, ".");
+ StringVector partofname = StringUtil::split (filename, ".");

if (partofname.size() <= 1)
FileNameRaw = filename + ".raw";
@@ -524,7 +524,7 @@
}

// Get codec according to filename extension
- std::vector< String > partofname = StringUtil::split (filename, ".");
+ StringVector partofname = StringUtil::split (filename, ".");
String pure_file_name;
String ext_name;

@@ -610,7 +610,7 @@
String FileNameRaw;

// Get codec according to filename extension
- std::vector< String > partofname = StringUtil::split (filename, ".");
+ StringVector partofname = StringUtil::split (filename, ".");

if (partofname.size() <= 1)
FileNameRaw = filename + ".raw";
@@ -645,7 +645,7 @@
else
ext_name = MapUtil::getSingleton().mTextureExt;

- std::vector< String > partofname = StringUtil::split (filename, ".");
+ StringVector partofname = StringUtil::split (filename, ".");
String pure_file_name;
if (partofname.size() <= 1)
{
@@ -777,7 +777,7 @@


// Get codec according to filename extension
- std::vector< String > partofname = StringUtil::split (filename, ".");
+ StringVector partofname = StringUtil::split (filename, ".");
String pure_file_name;
String ext_name = (b_SaveAsRaw)? MapUtil::getSingleton().mExt:MapUtil::getSingleton().mTextureExt;
if (partofname.size() <= 1)
@@ -1021,7 +1021,7 @@
DEBUG_OUTPUT ( filename );

// Get codec according to filename extension
- std::vector< String > partofname = StringUtil::split (filename, ".");
+ StringVector partofname = StringUtil::split (filename, ".");
String ext_name = (b_SaveAsRaw)? MapUtil::getSingleton().mExt:MapUtil::getSingleton().mTextureExt;
String pure_file_name;
if (partofname.size() <= 1)
Index: Tools/MapSplitter/src/MapUtil.cpp
===================================================================
--- Tools/MapSplitter/src/MapUtil.cpp (revision 2979)
+++ Tools/MapSplitter/src/MapUtil.cpp (working copy)
@@ -896,7 +896,7 @@


// set codec according to filename extension or cfg file parameter

String colormPureFilename;

- std::vector< String > partofname = StringUtil::split (MapName, ".");

+ StringVector partofname = StringUtil::split (MapName, ".");

Image ExistingColorMap;

if (partofname.size() <= 1)

{

@@ -1035,7 +1035,7 @@


// set codec according to filename extension or cfg file parameter

String colormPureFilename;

- std::vector< String > partofname = StringUtil::split (MapName, ".");

+ StringVector partofname = StringUtil::split (MapName, ".");

Image ExistingColorMap;

if (partofname.size() <= 1)

{

Index: Samples/Common/include/PagingLandScape2Application.h
===================================================================
--- Samples/Common/include/PagingLandScape2Application.h (revision 2979)
+++ Samples/Common/include/PagingLandScape2Application.h (working copy)
@@ -220,7 +220,7 @@
{

// Initialise, parse scripts etc

//ResourceGroupManager::getSingleton().initialiseAllResourceGroups();

- ResourceGroupManager::getSingleton().initialiseResourceGroup(ResourceGroupManager::BOOTSTRAP_RESOURCE_GROUP_NAME);

+ ResourceGroupManager::getSingleton().initialiseResourceGroup(ResourceGroupManager::DEFAULT_RESOURCE_GROUP_NAME);

ResourceGroupManager::getSingleton().initialiseResourceGroup("General");

ResourceGroupManager::getSingleton().initialiseResourceGroup("PLSM2");



Index: acinclude.m4
===================================================================
--- acinclude.m4 (revision 2979)
+++ acinclude.m4 (working copy)
@@ -8,7 +8,8 @@
ac_cv_use_ogre=/usr/local)
if test x$ac_cv_use_ogre != xno; then
OGRE_CFLAGS=`pkg-config --cflags OGRE`
- OGRE_LIBS=`pkg-config --libs OGRE`
+ OGRE_LIBS=`pkg-config --libs OGRE`
+ OGRE_LIBS="$OGRE_LIBS -Wl,/usr/local/lib/OGRE/Plugin_OctreeSceneManager.so -Wl,-rpath,/usr/local/lib/OGRE/"
OGRE_PLUGINDIR=`pkg-config --variable plugindir OGRE`
fi
AC_SUBST(OGRE_CFLAGS)
Index: bootstrap
===================================================================
--- bootstrap (revision 2979)
+++ bootstrap (working copy)
@@ -22,10 +22,10 @@
exit 1;
fi

-if test -z "`libtool --version 2>&1|head -n 1|egrep '1.[4-5]'`"; then
- echo "Libtool 1.4 or above is required. Aborting build...";
- exit 1;
-fi
+#if test -z "`libtool --version 2>&1|head -n 1|egrep '1.[4-5]'`"; then
+# echo "Libtool 1.4 or above is required. Aborting build...";
+# exit 1;
+#fi

# clean up files which cause confusion when switch versions of auto*
rm -rf autom4te.cache