473,396 Members | 2,036 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Undefined symbol errors upon import of an extension I made.

An extension I used uses some other functions i made (outside of the sources used by the extension itself), but it complains about them upon import as being undefined symbols.

Expand|Select|Wrap|Line Numbers
  1. >>> import libpytwo2gam 
  2. Traceback (most recent call last):
  3.   File "<stdin>", line 1, in <module>
  4. ImportError: ./libpytwo2gam.so: undefined symbol: twoll_linearsearch
  5. >>> 
  6.  
twoll_linearsearch() is a function in an object file I include in the extra_objects member of the Extension object I make in the setup.py script. Here's the script:

Expand|Select|Wrap|Line Numbers
  1.  
  2. from distutils.core import setup, Extension
  3.  
  4. ARCH = 'x86_64'
  5.  
  6. extra = ['../../../misc/ll/'+ARCH+'_tmp/ll.o',
  7.          '../../simple/'+ARCH+'_tmp/srctools.o',
  8.          '../'+ARCH+'_tmp/util.o',
  9.          '../'+ARCH+'_tmp/extern.o']
  10. print extra
  11.  
  12. two2gam_module = Extension('libpytwo2gam',
  13.                            sources=['pyext.c'],
  14.                            extra_objects = extra,
  15.                            libraries=['SDL', 'SDL_image'])
  16.  
  17. setup(name = 'libpytwo2gam',
  18.        version = '0.0.1',
  19.        description = 'Python Interface for two2gam',
  20.        author = '{2}rIng',
  21.        author_email = 'xxx@xxx.com',
  22.        long_description = '''
  23. Description says it (IOW, long_descriptions goes here!).
  24. ''',
  25.        ext_modules = [two2gam_module])
  26.  
Oct 31 '10 #1
0 1275

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Sean | last post by:
System is Redhat 9.0, Python 2.2.3, Zope 2.6.2 built OpenSSL from source: 2791797 Sep 30 14:50:15 2003 openssl-0.9.7c.tar.gz used configure options to set for /usr/local and...
4
by: Bill Hodges | last post by:
I just build PyQt from sources on Mandrake 10 and tried to run a le gacy application from a University that runs in several environments. I detectedno errors on the configuration or build and the...
0
by: Nemtos | last post by:
Hi, I upgraded my laptop from RH9 to Fedora 3 yesterday. It seems to have a problem with an undefined symbol in Python. Specifically, if I try to run system-config-packages, I get the following...
3
by: ch424 | last post by:
Hi there, I'm using Python 2.4.1 on Ubuntu Linux, and I'm having problems extending python in C: The C code is below: #include <Python.h> #include "ni488.h"
0
by: pervinder | last post by:
Hi, I have a c++ application which depends on some other libs which uses stlport When i build the application, it works fine on sun/linux/hp platform. (provided the .a for the dependency libs) ...
4
by: Mathias Waack | last post by:
Hi, I've embedded python into a legacy application. It works - most of the time. In some special situations the app crashes executing the "import random". There are two different situations: ...
8
by: pavan734 | last post by:
Hello, Please excuse me as Iam not posting this to correct group. I have a parser code obtained from flex command. I have many other files. When I compile them Iam getting a message like:...
0
by: çÌÏÔÏ× áÒÔÅÍ | last post by:
Hello! I'm trying to install the web application written with Python, and have the trouble with module math.so: # lwp-request http://localhost/site/code/edit.py Mod_python error:...
1
by: Justin Johnson | last post by:
Hello, I'm trying to build Python 2.5.0 on AIX 5.3 using IBM's compiler (VisualAge C++ Professional / C for AIX Compiler, Version 6). I run configure and make, but makes fails with undefined...
1
by: grbgooglefan | last post by:
I am importing cStringIO module in my PythonC++ embedded program. The import is failing with the following error: ImportError: /usr/lib/python2.3/lib-dynload/cStringIO.so: undefined symbol:...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.