470,826 Members | 1,898 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,826 developers. It's quick & easy.

undefined symbol: PyUnicodeUCS4_FromUnicode

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 qt.so is the same in the build directory
as it is in the site-packages/qt.so.

output is:

psyco installed and used
Traceback (most recent call last):
File "/usr/local/lib/python2.3/site-packages/drt/drt.py", line 40, in ?
from qt import *
ImportError: /usr/lib/python2.3/site-packages/qt.so: undefined symbol:
PyUnicodeUCS4_FromUnicode

Any pointers on how to resolve?
Jul 18 '05 #1
4 7182
Bill Hodges wrote:
output is:

psyco installed and used
Traceback (most recent call last):
File "/usr/local/lib/python2.3/site-packages/drt/drt.py", line 40, in ?
from qt import *
ImportError: /usr/lib/python2.3/site-packages/qt.so: undefined symbol:
PyUnicodeUCS4_FromUnicode

Any pointers on how to resolve?


It appears that you have built qt.so for UCS-4, but the installed Python
is UCS-2. Do "nm -D /usr/bin/python2.3|grep UCS" to verify that.

If so, make sure the pyconfig.h that you are using belongs to the
/usr/bin/python you are using.

Regards,
Martin
Jul 18 '05 #2
Martin,

Your dianosis is correct.
I compiled tcl to include UCS4 and
Python then compiled to UCS4
(nm revealed the difference).
PyQt compiled fine, However, it
still errors out the same way.
For some reason PyQt needs to be told to
include the UCS4 stuff in qt.so na d
I cannot find the key.

Do you have another suggestion.
----------------------------------------------------------
drt
psyco installed and used
Traceback (most recent call last):
File "/usr/local/lib/python2.3/site-packages/drt/drt.py", line 40, in ?
from qt import *
ImportError: /usr/lib/python2.3/site-packages/qt.so: undefined symbol:
PyUnicodeUCS4_FromUnicode
Martin v. Löwis wrote:
Bill Hodges wrote:
output is:

psyco installed and used
Traceback (most recent call last):
File "/usr/local/lib/python2.3/site-packages/drt/drt.py", line 40, in ?
from qt import *
ImportError: /usr/lib/python2.3/site-packages/qt.so: undefined symbol:
PyUnicodeUCS4_FromUnicode

Any pointers on how to resolve?

It appears that you have built qt.so for UCS-4, but the installed Python
is UCS-2. Do "nm -D /usr/bin/python2.3|grep UCS" to verify that.

If so, make sure the pyconfig.h that you are using belongs to the
/usr/bin/python you are using.

Regards,
Martin

Jul 18 '05 #3
Bill Hodges wrote:
Your dianosis is correct.
I compiled tcl to include UCS4 and
Python then compiled to UCS4
(nm revealed the difference).
Are you sure about that? Are you absolutely certain that
the installed Python (/usr/local/bin/python2.3) is UCS-4?
It appears to me that it is likely UCS-2.
PyQt compiled fine, However, it
still errors out the same way.
For some reason PyQt needs to be told to
include the UCS4 stuff in qt.so na d
I cannot find the key.


Do you happen to have Python header files both in /usr/include
and /usr/local/include? Make sure PyQt is using the ones in
/usr/local/include, if you plan to use PyQt with that Python
installation.

Regards,
Martin
Jul 18 '05 #4
Martin,
Your diagnosis was correct.
When I removed the python stuff in /usr
and rebuilt everything in /usr/local
I finally got DRT to run.

Thank you.

Bill
Martin v. Löwis wrote:
Bill Hodges wrote:
Your dianosis is correct.
I compiled tcl to include UCS4 and
Python then compiled to UCS4
(nm revealed the difference).

Are you sure about that? Are you absolutely certain that
the installed Python (/usr/local/bin/python2.3) is UCS-4?
It appears to me that it is likely UCS-2.
PyQt compiled fine, However, it
still errors out the same way.
For some reason PyQt needs to be told to
include the UCS4 stuff in qt.so na d
I cannot find the key.

Do you happen to have Python header files both in /usr/include
and /usr/local/include? Make sure PyQt is using the ones in
/usr/local/include, if you plan to use PyQt with that Python
installation.

Regards,
Martin

Jul 18 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by pervinder | last post: by
8 posts views Thread by Scott J. McCaughrin | last post: by
2 posts views Thread by el prinCipante | last post: by
8 posts views Thread by pavan734 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.