Announce: (ALPHA) Perl/Gtk 0.4 & Perl/Gnome 0.3000
- From: Kenneth Albanowski <kjahds kjahds com>
- To: gtk-list redhat com, gtk-devel-list redhat com
- Subject: Announce: (ALPHA) Perl/Gtk 0.4 & Perl/Gnome 0.3000
- Date: Thu, 1 Oct 1998 11:30:15 -0400 (EDT)
Perl/Gtk 0.4 & Perl/Gnome 0.3000 have been uploaded to ftp.gimp.org -- but
not to CPAN. These are fairly alpha modules, in that they seem to work
reasonably well, except for the bits that seem to break at random. As
really-truly alpha level code (unlike most of my alpha stuff which usually
works), this stuff is fairly evil, and I'd recommend sticking with 0.3 if
you intend to actually try to get anything done. If you do want to play
with 0.4, you _must_ have Gtk+-1.1.2, and glib 1.1.3 installed, and Gnome
0.30 for Perl/Gnome. (Actually, Perk/Gtk should still work with earlier
versions of Gtk+, but I didn't bother to verify this. And you'll need the
latest versions for Gnome.)
I hope that this instability will be resolved by the time Perl/Gtk 0.5 is
released. (And it's very likely that Perl/Gtk will then support several
versions of Gtk+, perhaps all of them, with different functionality, of
course.)
On that note, on to the goodies:
I've added an (entirely too complex) generic export mechanism, so that
one Perl binary module can portably plug in to functions & variables
exported by another, even (especially) if the local dynamic loading
facility does not support this. (Many don't.) The upshot of this is that
all of the Gnome functionality has been broken out of Perl/Gtk and placed
into Perl/Gnome (which is now appropriating the Gnome::* Perl namespace).
This is beneficial, as it paves the way for Perl modules to be distributed
separately from Perl/Gtk, and to be maintained separately from Perl/Gtk.
To accomplish this, there have been a number of upheavels in the build &
*.def processing mechanisms, and a lot of the generated files are now
installed into the Perl installation directories, along with the module
binaries. This allows subsequent modules (like Perl/Gnome) to make use of
the same tool that Perl/Gtk used to build itself, and also connect
directly (via the macroized export facility) to the Perl/Gtk binary code,
so that it can plug in to the type system, signal handling, and other
major facilities provided by Perl/Gtk.
(There are a few portions of this that are still quite clumsy: it's not
quite clean enough to build one Perl/Gtk submodule that depends on more
then one previously installed Perl/Gtk submodule, for example, and the
*.def processing doesn't quite grok declare vs. define yet. A little bit
of reengineering of the build tools should smooth this out quite nicely,
and it may even be possible to turn the export mechanism into a generic
Perl tool.)
There are likely to be some slow-downs due to all of this work (since
type-system function calls need to go through an indirect pointer in
submodules, and the various helper mechanisms for signals and the type
system have to code with additional helpers being defined by subsequent
submodules), but it shouldn't be a catastrophic effect, and it should be
possible to get rid of the export overhead on systems that do support
global dynamic linking (via RTLD_GLOBAL), however I've not explored this
yet, as it may involve some changes to Perl to support cleanly. Some of
the other delays (in signal helpers) should be reduced when signals gain
the ability to unambiguously describe their arguments. (Currently I need
hand-crafted C code it handle any signals with pointer arguments, to
maintain type-safety.)
But to get back to the good news: Perl/Gnome supports many Gnome 0.30
features, including panel applets! (I was quite suprised and pleased that
this worked without any problems.) Since Perl/Gnome is no longer under the
Gtk::* namespace, we can feel free to start defining non-Gtk sections of
Gnome. Thus, this module is designed to be destined become the complete
Perl interface to Gnome functionality, both graphical and non-.
Unfortunately, that leads back to the bad news: something is quite busted
with either Gnome or the Perl/Gnome code, with the result that installing
too many types seems to cause Gtk to go slightly haywire. On my machine,
at least, if you configure Perl/Gnome with all of the trimmings, then just
about all the Gnome widgets cease working (dying with segfaults if you try
to show them). This seems purely related to the number of Gnome widget
types defined. It may well be a memory leak somewhere in my code, but
unfortunately it is not trivial to debug this stuff. To top it off,
Electric Fence decides to die in the middle of gnome_init for no
immediately obvious reason.
It should be possible to turn on global dynamic linking, which should
eventually allow you to use the debugger on all of this code.
Alternatively, it should be possible to roll the Perl/Gnome contents back
in to the Perl/Gtk tree, to build it as a single module (which would
simply debugging). Unfortunately, this process isn't trivial at the moment
(though it ought to be, clearly another feature desirable for 0.5.)
Basically, if anyone feels like trying to debug this stuff, I'd appreciate
it.
Happy Hacking,
Ken
--
Kenneth Albanowski (kjahds@kjahds.com, CIS: 70705,126)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]