Linkage problem in Linux with OGRE 1.7.0 Final

asura10

14-03-2010 00:47:16

I used the instructions to buid Python-Ogre 1.7.0 given in http://wiki.python-ogre.org/index.php/LinuxBuildV4, but i found linkage problems on _ogre_.so, giving the following problem when trying to run demos:

ImportError: /usr/local/lib/python2.6/dist-packages/ogre/renderer/OGRE/_ogre_.so: undefined symbol: _ZN4Ogre11PropertySet11setValueMapERKSt3mapISsNS_13PropertyValueESt4lessISsENS_12STLAllocatorISt4pairIKSsS2_ENS_22CategorisedAllocPolicyILNS_14MemoryCategoryE0EEEEEE

i found by using nm and grep that this symbol is contained in libOgreProperty.so.1.7.0 and based on ldd info:

linux-gate.so.1 => (0xb76f0000)
libOgreMain.so.1.7.0 => /usr/lib/libOgreMain.so.1.7.0 (0xb26d7000)
libpthread.so.0 => /../../lib/tls/i686/cmov/libpthread.so.0 (0xb26be000)
libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0xb25cb000)
libboost_python-py26.so.1.41.0 => /usr/lib/libboost_python-py26.so.1.41.0 (0xb2580000)
libm.so.6 => /../../lib/tls/i686/cmov/libm.so.6 (0xb255a000)
libgcc_s.so.1 => /../../lib/libgcc_s.so.1 (0xb253c000)
libc.so.6 => /../../lib/tls/i686/cmov/libc.so.6 (0xb23f7000)
libfreetype.so.6 => /usr/lib/libfreetype.so.6 (0xb2377000)
libSM.so.6 => /usr/lib/libSM.so.6 (0xb236e000)
libICE.so.6 => /usr/lib/libICE.so.6 (0xb2353000)
libX11.so.6 => /usr/lib/libX11.so.6 (0xb2224000)
libXext.so.6 => /usr/lib/libXext.so.6 (0xb2214000)
libXt.so.6 => /usr/lib/libXt.so.6 (0xb21c1000)
libXaw.so.7 => /usr/lib/libXaw.so.7 (0xb215a000)
libdl.so.2 => /../../lib/tls/i686/cmov/libdl.so.2 (0xb2156000)
libboost_thread.so.1.41.0 => /usr/lib/libboost_thread.so.1.41.0 (0xb2142000)
libboost_date_time.so.1.41.0 => /usr/lib/libboost_date_time.so.1.41.0 (0xb2131000)
libfreeimage.so.3 => /usr/lib/libfreeimage.so.3 (0xb1ea3000)
libzzip-0.so.13 => /usr/lib/libzzip-0.so.13 (0xb1e9b000)
libz.so.1 => /../../lib/libz.so.1 (0xb1e85000)
/lib/ld-linux.so.2 (0xb76f1000)
libutil.so.1 => /../../lib/tls/i686/cmov/libutil.so.1 (0xb1e81000)
librt.so.1 => /../../lib/tls/i686/cmov/librt.so.1 (0xb1e78000)
libuuid.so.1 => /../../lib/libuuid.so.1 (0xb1e73000)
libxcb.so.1 => /usr/lib/libxcb.so.1 (0xb1e54000)
libXau.so.6 => /usr/lib/libXau.so.6 (0xb1e50000)
libXmu.so.6 => /usr/lib/libXmu.so.6 (0xb1e37000)
libXpm.so.4 => /usr/lib/libXpm.so.4 (0xb1e25000)
libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0xb1e20000)

it was not linked inside the _ogre_.so library, are there any steps to follow to fix this problem?

also there is a comma in Config that makes ogresdksample path a tuple so os.path.join chokes on it

UPDATE: Found the solution myself:
change
libs = [boost.lib, 'OgreMain']

to

libs = [boost.lib, 'OgreMain', 'libOgreProperty']

asura10

14-03-2010 20:12:56

Patch file for some changes i made to compile python-ogre on ubuntu 9.10 using ogre-1.7.0 final, also some updates to nvidia-cg and simple stuff like that, all this based on rv1100 from svn.

Also this command: [0, "find . -name *.a -execdir cp {} %s/lib \;" % PREFIX, baseDir] on bullet doesnt work while building using the new --usesystem switch, there are some tweaks needed to make bullet and ogrebulletd to compile, i also include that in the patch file.

I add to the tr1 patches to final ogre sourcecode

andy

15-03-2010 00:53:34

Thanks for the patch -- nearly finished with the 1.7 Windows release at which point I'll clean up the Linux version...

Andy

asura10

15-03-2010 01:13:43

Can you tell mithro his libboost-serialization1.41.0 package from ppa is broken? i had to modify it to build python-ogre, it depends on a future version of itself and i was trying to use as many precompiled libraries as possible and had to install that to avoid the broken relation between python 2.6.4 and boost 1.38

asura10

15-03-2010 02:36:07

Sorry to keep bothering but i am offering some new patches to the build system on linux. Updated for rv1101

The final bullet build patch that includes modifications on source code and the modificiations on enviroment.py

UPDATE: remade python-ogre.patch since the changes in rv 1101 include something for debug support and dont allow to build the libs, also some adds from ogrevideo and theoraplayer made by andy