[Kde-bindings] qtruby.rb: backporting the 'Module includes Qt' bug to 3.3

Richard Dale Richard_Dale at tipitina.demon.co.uk
Sun Apr 10 09:29:51 UTC 2005


On Saturday 09 April 2005 21:50, Adeodato Simó wrote:
> Hello Richard,
>
>   I'm one of the KDE packagers in Debian. Our next release, Sarge, will
>   be shipping with KDE 3.3, and a user has requested [1] that we
>   backport the "include 'Qt' in Module pollutes its namespace" fix from
>   KDE_3_4_BRANCH.
>
>     [1] http://bugs.debian.org/303608
>
>   I've digged into it today and backported the CVS commit. I've tested
>   the resulting package and seems to work, but I'd really appreciate if
>   you could have a quick look at the patch we'll be applying (attached).
>
>   I'm asking this because, although the patch came from CVS, I've needed
>   to do a bit of tweaking to it, and I fear having left something out,
>   or having included something that will have some nasty effects that my
>   testing hasn't discovered.
>
>   The changes are explained at the top of the diff, the involved CVS
>   revisions are listed in it too.
I've had a look at the changes, and they look ok. I did reformat some code at 
the same time as making the fix which makes it a bit less backporting 
friendly - sorry about that.

I fixed a couple of small regressions yesterday, Qt::version and 
Qt::ruby_version shouldn't have been moved to the Qt::Internal module, so 
these lines should be removed from the patch:

-    rb_define_method(qt_internal_module, "version", (VALUE (*) (...)) 
version, 0);
-    rb_define_method(qt_internal_module, "qtruby_version", (VALUE (*) (...)) 
qtruby_version, 0);

+    rb_define_module_function(qt_internal_module, "version", (VALUE (*) 
(...)) version, 0);
+    rb_define_module_function(qt_internal_module, "qtruby_version", (VALUE 
(*) (...)) 

The rbqtapi script in qtruby/bin also need changing to work with the methods 
moved to the Internal module. I've attached the current version.

Also a similar change was needed for korunudum.rb, otherwise ruby dcop won't 
work, I've attached a patch of that change. So please make sure that the 
examples in korundum/rubylib/examples/dcop still work ok after the fix.

Regards
-- Richard


-------------- next part --------------
A non-text attachment was scrubbed...
Name: korunundum-namespace.patch
Type: text/x-diff
Size: 3060 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-bindings/attachments/20050410/7eb7b545/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rbqtapi
Type: application/x-ruby
Size: 3017 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-bindings/attachments/20050410/7eb7b545/attachment-0001.bin>


More information about the Kde-bindings mailing list