After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 622232 - libchamplain-0.4.6 python bindings doesn't work at all
libchamplain-0.4.6 python bindings doesn't work at all
Status: RESOLVED FIXED
Product: libchamplain
Classification: Core
Component: bindings
0.4.x
Other FreeBSD
: Normal critical
: ---
Assigned To: libchamplain-maint
libchamplain-maint
Depends on:
Blocks:
 
 
Reported: 2010-06-20 21:24 UTC by Ruslan Makhmatkhanov
Modified: 2010-08-20 22:34 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Ruslan Makhmatkhanov 2010-06-20 21:24:06 UTC
Good day!

After update to libchamplain 0.4.6, Getting Things Gnome now crashes when i select Edit -> Preferences. The error is: 

/libexec/ld-elf.so.1: /usr/local/lib/python2.6/site-packages/champlain.so: Undefined symbol "champlain_add_constants"

But if i just start python and try to import champlain it complains too: 

[mrk@smeshariki2 ~]> python
Python 2.6.5 (r265:79063, Jun 18 2010, 09:30:32)
[GCC 4.2.1 20070719  [FreeBSD]] on freebsd8
Type "help", "copyright", "credits" or "license" for more information.
>>> import champlain
Traceback (most recent call last):
  • File "<stdin>", line 1 in <module>
ImportError: /usr/local/lib/python2.6/site-packages/champlain.so: Undefined symbol "champlain_functions"
>>>

It worked pretty fine before the update so it seems has something to do with changes in 0.4.6. 

I'm open for any tests and additional information.

Thanks!
Comment 1 Jiri Techet 2010-06-20 21:48:59 UTC
OK, a few questions. Did you get the library as your distribution's update or did you compile and install it manually? If you compiled it by yourself, you should use --enable-python for compilation. One more thing, did you run ldconfig after make install?
Comment 2 Ruslan Makhmatkhanov 2010-06-20 22:00:31 UTC
Sorry i forgot to say that i installed libchamplain from freebsd ports collection (software repository) and it builds with --enable-python=yes by default. After updating some port package manager run ldconfig, but i now run it manually just for the case. And nothing changed.
Comment 3 Jiri Techet 2010-06-22 13:43:30 UTC
Hmm, I have no idea what might be wrong. One more question - what libchamplain version did you use before this update? There haven't been any libchamplain python bindings updates since 0.4.3 as far as I can tell.

Maybe Victor, the libchamplain's python bindings maintainer, might know more. Looking at the bindings code the missing symbol "champlain_functions" is defined in the gtk bindings code (is this the right way to do it?) So one more problem might be that the package wasn't compiled with --enable-gtk.

If you wish, you might also try to compile libchamplain by yourself (with --enable-gtk and --enable-python) to see if it works, but I expect it will given the fact that it works for all libchamplain developers.
Comment 4 Ruslan Makhmatkhanov 2010-06-23 07:52:26 UTC
Good day!

I was updating from version 0.4.5. 
I dont see that --enable-gtk is defined manifestly in our port's Makefile, so i did it manually (and --enable-python uncoditionally). Then i rebuild and reinstall the port. Please see full buildlog, maybe you can see obvious inconsistences:

http://pastebin.com/x47yAqSN

But i still got this "champlain_functions" problem when trying to import champlain.
Comment 5 Jiri Techet 2010-06-29 10:24:03 UTC
Ah crap, I've just noticed it - bindings/python/champlain/pychamplain.c has 0 size - apparently something went wrong during make distcheck, not sure what may have caused this. It looks I'll have to make one more 0.4.x release.

Would you try the following to be sure? Run 'make clean' - that should remove pychamplain.c because it's autogenerated and run make again. Now it should generate pychamplain.c hopefully with non-zero size and python bindings should work again.
Comment 6 Ruslan Makhmatkhanov 2010-06-29 11:28:11 UTC
Yes it works. I've check that it has 0 size, then do ./configure. Than make clean and make in bindings/python/champlain/. Then copied champlain.so and .la into python's site-packages dir and all is now working. Thanks!

Untill new version wasn't released can we somehow patch Makefile in bindings/python/champlain/ to force it to regenerate files when building libchamplain?
Comment 7 Jiri Techet 2010-06-29 12:21:17 UTC
I think the easiest way is to either

* delete pychamplain.c (so it'll get generated automatically during make), or
* use the correct pychamplain.c you get after 'make clean; make'

The second one is actually the only change for 0.4.7 so you can make your own home-made release by just replacing the 0-size pychamplain.c with the generated one in the tarball.

(However I'll wait for a while with the 0.4.7 release because there is one more bug that might need to be fixed.)
Comment 8 Jiri Techet 2010-08-20 22:34:29 UTC
Fixed in the 0.4.7 release.