undefined symbol: PyUnicodeUCS2_FromUnicode

Eric Moors scare.crow at oz.land
Tue Feb 24 09:08:13 EST 2004


Daniel Dittmar wrote:

> Eric Moors wrote:
>> /home/me>redhat-config-services
>> ImportError: /usr/lib/python2.2/site-packages/gtk-2.0/gtk/_gtk.so:
> undefined
>> symbol: PyUnicodeUCS2_FromUnicode
> 
> Python on RedHat 9 is compiled with 4 byte unicode characters (UCS4), most
> other distributions use 2 byte unicode characters (UCS2). So if you
> install a rpm compiled on a different system, this error is bound to

I have installed mandrake's synaptic, but that is replaced, and maybe some
fedora core rpms. The rest are RH9 dedicated RPMS or compiled at my machine

Just checked, the only fedora core RPM I had was for wine. I removed it,
just to be sure. No change (None expected)

> happen. Solution: compile the python module from source, but this requires
> that the sources of the module have been prepared to deal with UCS4.

Thanks, but...
Which module? Is this a gtk thing? (The name does suggest this)
but `rpm -qf _gtk.so` shows that _gtk.so doesn't belong to any package.
Yet gtk is installed by rpm.

Aargh. So this is probably something I installed from a tarball.

I can remove it manually (and _gtk.la), but then the program fails with:

Fatal Python error: could not import pango
/usr/share/redhat-config-services/redhat-config-services: line 4: 13918
Aborted                 /usr/bin/python
/usr/share/redhat-config-services/serviceconf.py


It must probably also possible to trace this back, but I am severly lacking
python knowledge to do this. Any pointers?

Eric





More information about the Python-list mailing list