Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > swig-python import error

Thread Tools

swig-python import error
Posts: n/a
I am facing a problem while loading a SWIG generated shared module
from python. The development is under HP-UX 32b platform. I use gcc
version 4.0.2 to build the shared module. This is how i try to build
the module.

# Compilation
GCC="$GCC -march=1.1"
$GCC -v -c -fpic ${ETUDE}.c ${ETUDE}_wrap.c -DDOUBLE_PRECISION -

# linking
ld -b binary -g -shared ${ETUDE}.o ${ETUDE}_wrap.o -o _${ETUDE}.so \
-a archive ${LIBS_CHAINE_PATH} -lfichiers_r8 -lmem -lutilitaires -
lsysteme -lcalcul -lmsgml -lcaractere \
-rpath -L/michprojects/ef/deli/Working/Source/deli9-PYAPI/Sandbox/libs/
chaine/PYAPI/don -L/michprojects/ef/deli/Working/Source/deli9-PYAPI/

The module generated is called In addition to that i set the
module path in LD_LIBRARY_PATH environment variable. Th error looks
like as follows.

Import error: module cannot be loaded.

But i am wondering how i am getting import error although every thing
looks OK. Any ideas are most welcome and thanks in advance.
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
to use import java.lang.* or import java.lang.Math or none at all? JPractitioner Java 13 02-24-2006 08:48 PM
XML Schema question - does "import" import elements? Vitali Gontsharuk XML 2 08-25-2005 07:33 PM
IMPORT STATIC; Why is "import static" file scope? Why not class scope? Paul Opal Java 12 10-10-2004 11:01 PM
GTK import doesn't import first time Dennis Python 2 08-18-2003 10:00 PM
import/from import question Artur M. Piwko Python 1 07-02-2003 07:04 PM