Posts: 4
Registered: ‎01-30-2008
Message 1 of 2 (180 Views)

Trouble Compiling SDK

180 Views, 1 Replies
01-30-2008 02:45 PM
I have been trying to recompile the .cpp including in the SDK for python2.4 support.
Once I finally was able to get it to compile, I ended up with the following:

4184 libwiretapPythonClientAPI.so
4573538 lib/opt/LINUX/i686/RHEL4/GCC_3_4_4/libwiretapClientAPI.a
2648825 lib/opt/LINUX/i686/RHEL4/GCC_3_4_4/libwiretapClientAPI.so
2980394 lib/opt/LINUX/i686/RHEL4/GCC_3_4_4/libwiretapPythonClientAPI.so

I have added this lib path, as well as my boost location (/usr/local/lib/boost-1_33_1) to my environ variable LD_LIBRARY_PATH, and tried to import libwiretapPythonClientAPI.so

I get the following error:
>>> from libwiretapPythonClientAPI import *
Traceback (most recent call last):
File "", line 1, in ?
ImportError: dynamic module does not define init function (initlibwiretapPythonClientAPI)

I am able to use the supplied python2.3 .so just fine, but I need it for 2.4
Could anyone offer specific information on how to properly recompile the SDK?

Distinguished Contributor
Posts: 103
Registered: ‎05-11-2004
Message 2 of 2 (180 Views)

Re: Trouble Compiling SDK

01-31-2008 04:49 PM in reply to: jdisrael

I suggest you use "nm -C" (on linux) to list the symbols. My guess is that your link line is to blame. Here's the one we use:

g++ -m32 -O3 -shared --whole-archive -Bdynamic -o libwiretapPythonClientAPI.so wiretapPythonClientAPI.o libwiretapClientAPI.a libboost_python.a

Not ethat we link against the static WT API lib


Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Do you have 60 seconds to spare? The Autodesk Community Team is revamping our site ranking system and we want your feedback! Please click here to launch the 5 question survey. As always your input is greatly appreciated.