--- libgtk2-mozembed-perl-0.08.orig/debian/compat +++ libgtk2-mozembed-perl-0.08/debian/compat @@ -0,0 +1 @@ +7 --- libgtk2-mozembed-perl-0.08.orig/debian/README.source +++ libgtk2-mozembed-perl-0.08/debian/README.source @@ -0,0 +1,5 @@ +This package uses quilt to manage all modifications to the upstream +source. Changes are stored in the source package as diffs in +debian/patches and applied during the build. + +See /usr/share/doc/quilt/README.source for a detailed explanation. --- libgtk2-mozembed-perl-0.08.orig/debian/libgtk2-mozembed-perl.examples +++ libgtk2-mozembed-perl-0.08/debian/libgtk2-mozembed-perl.examples @@ -0,0 +1 @@ +examples/* --- libgtk2-mozembed-perl-0.08.orig/debian/watch +++ libgtk2-mozembed-perl-0.08/debian/watch @@ -0,0 +1,4 @@ +# format version number, currently 3; this line is compulsory! +version=3 +# URL to the package page followed by a regex to search +http://search.cpan.org/dist/Gtk2-MozEmbed/ .*/Gtk2-MozEmbed-v?(\d[\d_.-]+)\.(?:tar(?:\.gz|\.bz2)?|tgz|zip)$ --- libgtk2-mozembed-perl-0.08.orig/debian/copyright +++ libgtk2-mozembed-perl-0.08/debian/copyright @@ -0,0 +1,21 @@ +Format-Specification: + http://wiki.debian.org/Proposals/CopyrightFormat?action=recall&rev=196 +Upstream-Maintainer: the gtk2-perl team +Upstream-Source: http://search.cpan.org/dist/Gtk2-MozEmbed/ +Upstream-Name: Gtk2-MozEmbed + +Files: * +Copyright: 2004-2008, the gtk2-perl team +License: LGPL-2.1+ + +Files: debian/* +Copyright: 2009, Ryan Niebur +License: LGPL-2.1+ + +License: LGPL-2.1+ + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License as published by + the Free Software Foundation; either version 2.1, or (at your option) + any later version. + On Debian GNU/Linux systems, the complete text of the GNU Lesser General + Public License version 2.1 can be found in `/usr/share/common-licenses/LGPL-2.1' --- libgtk2-mozembed-perl-0.08.orig/debian/rules +++ libgtk2-mozembed-perl-0.08/debian/rules @@ -0,0 +1,27 @@ +#!/usr/bin/make -f + +include /usr/share/quilt/quilt.make + +build: build-stamp +build-stamp: $(QUILT_STAMPFN) + dh --before dh_auto_test build + xvfb-run dh_auto_test + dh --after dh_auto_test build + touch $@ + +clean: unpatch + dh $@ + +install: install-stamp +install-stamp: build-stamp + dh install + touch $@ + +binary-arch: install + dh $@ + +binary-indep: + +binary: binary-arch binary-indep + +.PHONY: binary binary-arch binary-indep install clean build --- libgtk2-mozembed-perl-0.08.orig/debian/control +++ libgtk2-mozembed-perl-0.08/debian/control @@ -0,0 +1,22 @@ +Source: libgtk2-mozembed-perl +Section: perl +Priority: optional +Build-Depends: debhelper (>= 7), libextutils-depends-perl (>= 0.20), + libextutils-pkgconfig-perl (>= 1.03), libgtk2-perl (>= 1.081), + perl (>= 5.6.0-12), xulrunner-dev (>= 1.9.1~), xvfb, xauth, xfonts-base, + libglib2.0-dev, libgtk2.0-dev, quilt +Maintainer: Ubuntu MOTU Developers +XSBC-Original-Maintainer: Debian Perl Group +Uploaders: Ryan Niebur +Standards-Version: 3.8.1 +Homepage: http://gtk2-perl.sourceforge.net/ +Vcs-Svn: svn://svn.debian.org/pkg-perl/trunk/libgtk2-mozembed-perl/ +Vcs-Browser: http://svn.debian.org/viewsvn/pkg-perl/trunk/libgtk2-mozembed-perl/ + +Package: libgtk2-mozembed-perl +Architecture: any +Depends: ${perl:Depends}, ${shlibs:Depends}, ${misc:Depends}, + libextutils-depends-perl (>= 0.20), libgtk2-perl (>= 1.081), + libextutils-pkgconfig-perl (>= 1.03), xulrunner-1.9 +Description: Perl interface to the Mozilla embedding widget + Gtk2::MozEmbed allows a Perl developer to use the Mozilla embedding widget. --- libgtk2-mozembed-perl-0.08.orig/debian/changelog +++ libgtk2-mozembed-perl-0.08/debian/changelog @@ -0,0 +1,22 @@ +libgtk2-mozembed-perl (0.08-2ubuntu0.xul191) karmic; urgency=low + + * xulrunner-1.9.1 by default transition + + see: https://blueprints.launchpad.net/ubuntu/+spec/desktop-karmic-firefox-3.5 + - bump minimal xulrunner-dev version + + -- Alexander Sack Fri, 07 Aug 2009 10:27:45 +0200 + +libgtk2-mozembed-perl (0.08-2) unstable; urgency=low + + [ gregor herrmann ] + * New patch dont-pollute-HOME: use a temp directory for tests and remove + it afterwards instead of polluting $HOME, thanks to Niko Tyni for + spotting. This actually fixes the segfault. (Closes: #525534) + + -- Ryan Niebur Thu, 30 Apr 2009 01:04:55 -0700 + +libgtk2-mozembed-perl (0.08-1) unstable; urgency=low + + * Initial Release. (LP: #187921) (Closes: #518099) + + -- Ryan Niebur Mon, 23 Mar 2009 10:42:49 -0700 --- libgtk2-mozembed-perl-0.08.orig/debian/libgtk2-mozembed-perl.docs +++ libgtk2-mozembed-perl-0.08/debian/libgtk2-mozembed-perl.docs @@ -0,0 +1 @@ +NEWS --- libgtk2-mozembed-perl-0.08.orig/debian/patches/series +++ libgtk2-mozembed-perl-0.08/debian/patches/series @@ -0,0 +1,3 @@ +whatis-entry +use-the-right-xul +dont-pollute-HOME --- libgtk2-mozembed-perl-0.08.orig/debian/patches/use-the-right-xul +++ libgtk2-mozembed-perl-0.08/debian/patches/use-the-right-xul @@ -0,0 +1,278 @@ +Description: link to xulrunner the right way by using the insane glue code +Author: Ryan Niebur +the actual code part (in the BOOT: section of the xs) was stolen from +the gnome-python-extras package, who stole it from Ubuntu. :) + +--- a/Makefile.PL ++++ b/Makefile.PL +@@ -42,17 +42,9 @@ + exit 1; # not reached + } + +-# Check if Mozilla::DOM is installed. (could use an ENABLE_DOM option) +-my $use_dom = 1; +-unless (eval "use Mozilla::DOM '$build_reqs{'perl-Mozilla-DOM'}'; 1") { +- $use_dom = 0; +-} ++my $use_dom = 0; + +-my %pkgcfg = ExtUtils::PkgConfig->find( +- "xulrunner-gtkmozembed >= $build_reqs{'XULRunner'}", +- "mozilla-gtkmozembed >= $build_reqs{'Mozilla'}", +- "firefox-gtkmozembed >= $build_reqs{'Firefox'}", +- "mozilla-firefox-gtkmozembed >= $build_reqs{'Firefox'}"); ++my %pkgcfg = ExtUtils::PkgConfig->find("mozilla-gtkmozembed-embedding >= $build_reqs{'XULRunner'}"); + + mkdir 'build', 0777; + +@@ -81,6 +73,8 @@ + . qq("\\"/usr/lib/xulrunner-$1\\"" ); + } + ++$libs .= " -lstdc++ "; ++ + my $mozembed = ExtUtils::Depends->new('Gtk2::MozEmbed', 'Gtk2', + ($use_dom ? ('Mozilla::DOM') : ())); + +@@ -107,7 +101,7 @@ + XSPROTOARG => '-noprototypes', + MAN3PODS => \%pod_files, + +- ($use_dom ? (CC => 'c++', XSOPT => '-C++') : ()), ++ CC => 'c++', XSOPT => '-C++', + + $mozembed->get_makefile_vars, + +--- a/xs/GtkMozEmbed.xs ++++ b/xs/GtkMozEmbed.xs +@@ -20,6 +20,7 @@ + + #include "gtkmozembed2perl.h" + #include "gperl_marshal.h" ++#include "gtkmozembed_glue.cpp" + + /* ------------------------------------------------------------------------- */ + +@@ -134,143 +135,50 @@ + + /* gint (* dom_key_press) (GtkMozEmbed *embed, gpointer dom_event); */ + +-#ifdef __cplusplus /* implies Mozilla::DOM is installed */ +- +-static void +-gtk2perl_moz_embed_dom_key_marshal (GClosure *closure, +- GValue *return_value, +- guint n_param_values, +- const GValue *param_values, +- gpointer invocation_hint, +- gpointer marshal_data) +-{ +- dGPERL_CLOSURE_MARSHAL_ARGS; +- +- GPERL_CLOSURE_MARSHAL_INIT (closure, marshal_data); +- +- ENTER; +- SAVETMPS; +- +- PUSHMARK (SP); +- +- GPERL_CLOSURE_MARSHAL_PUSH_INSTANCE (param_values); +- +- /* param_values + 1 is the `gpointer dom_event' */ +- XPUSHs (sv_2mortal (newSVnsIDOMKeyEvent ((nsIDOMKeyEvent *) +- g_value_get_pointer (param_values + 1)))); +- +- +- GPERL_CLOSURE_MARSHAL_PUSH_DATA; +- +- PUTBACK; +- +- GPERL_CLOSURE_MARSHAL_CALL (G_SCALAR); +- +- SPAGAIN; +- +- if (count != 1) +- croak ("signal handlers for `dom_key_*' are supposed to " +- "return an integer"); +- +- gperl_value_from_sv (return_value, POPs); +- +- PUTBACK; +- +- FREETMPS; +- LEAVE; +-} +- +-static void +-gtk2perl_moz_embed_dom_mouse_marshal (GClosure *closure, +- GValue *return_value, +- guint n_param_values, +- const GValue *param_values, +- gpointer invocation_hint, +- gpointer marshal_data) +-{ +- dGPERL_CLOSURE_MARSHAL_ARGS; +- +- GPERL_CLOSURE_MARSHAL_INIT (closure, marshal_data); +- +- ENTER; +- SAVETMPS; +- +- PUSHMARK (SP); +- +- GPERL_CLOSURE_MARSHAL_PUSH_INSTANCE (param_values); +- +- /* param_values + 1 is the `gpointer dom_event' */ +- XPUSHs (sv_2mortal (newSVnsIDOMMouseEvent ((nsIDOMMouseEvent *) +- g_value_get_pointer (param_values + 1)))); +- +- +- GPERL_CLOSURE_MARSHAL_PUSH_DATA; +- +- PUTBACK; +- +- GPERL_CLOSURE_MARSHAL_CALL (G_SCALAR); +- +- SPAGAIN; +- +- if (count != 1) +- croak ("signal handlers for `dom_mouse_*' are supposed to " +- "return an integer"); +- +- gperl_value_from_sv (return_value, POPs); +- +- PUTBACK; +- +- FREETMPS; +- LEAVE; +-} +- +-#endif /* ifdef __cplusplus */ +- + /* ------------------------------------------------------------------------- */ + + MODULE = Gtk2::MozEmbed PACKAGE = Gtk2::MozEmbed PREFIX = gtk_moz_embed_ + + BOOT: +-#include "register.xsh" +-#include "boot.xsh" +-#ifdef GTK_MOZ_EMBED_PERL_XULRUNNER_PATH +- gtk_moz_embed_set_path (GTK_MOZ_EMBED_PERL_XULRUNNER_PATH); +-#endif /* GTK_MOZ_EMBED_PERL_XULRUNNER_PATH */ ++ ++ /* copied from the gnome-python-extras package's patch */ ++ static const GREVersionRange greVersion = { ++ "1.9b", PR_TRUE, ++ "1.9.*", PR_TRUE ++ }; ++ char xpcomLocation[4096]; ++ nsresult rv = GRE_GetGREPathWithProperties(&greVersion, 1, nsnull, 0, xpcomLocation, 4096); ++ if (NS_FAILED(rv)) { ++ croak("failed 1"); ++ }; ++ ++ // Startup the XPCOM Glue that links us up with XPCOM. ++ XPCOMGlueStartup(xpcomLocation); ++ if (NS_FAILED(rv)) { ++ croak("failed 2"); ++ } ++ ++ rv = GTKEmbedGlueStartup(); ++ if (NS_FAILED(rv)) { ++ croak("failed 3"); ++ } ++ ++ /* gtk_moz_embed_set_comp_path(xpcomLocation); */ ++ ++ char *lastSlash = strrchr(xpcomLocation, '/'); ++ if (lastSlash) ++ *lastSlash = '\0'; ++ ++ gtk_moz_embed_set_path(xpcomLocation); ++ + gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, + "new_window", + gtk2perl_moz_embed_new_window_marshal); + /* gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED_SINGLE, + "new_window_orphan", + gtk2perl_moz_embed_new_window_marshal); */ +-#ifdef __cplusplus +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_key_down", +- gtk2perl_moz_embed_dom_key_marshal); +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_key_press", +- gtk2perl_moz_embed_dom_key_marshal); +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_key_up", +- gtk2perl_moz_embed_dom_key_marshal); +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_mouse_down", +- gtk2perl_moz_embed_dom_mouse_marshal); +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_mouse_up", +- gtk2perl_moz_embed_dom_mouse_marshal); +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_mouse_click", +- gtk2perl_moz_embed_dom_mouse_marshal); +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_mouse_dbl_click", +- gtk2perl_moz_embed_dom_mouse_marshal); +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_mouse_over", +- gtk2perl_moz_embed_dom_mouse_marshal); +- gperl_signal_set_marshaller_for (GTK_TYPE_MOZ_EMBED, +- "dom_mouse_out", +- gtk2perl_moz_embed_dom_mouse_marshal); +-#endif /* ifdef __cplusplus */ ++#include "register.xsh" ++#include "boot.xsh" + + =for object Gtk2::MozEmbed::main + +@@ -539,31 +447,6 @@ + OUTPUT: + RETVAL + +-#ifdef __cplusplus /* implies Mozilla::DOM is installed */ +- +-=for apidoc +- +-This method gets the nsIWebBrowser for this window. +-It is only available if Mozilla::DOM was installed +-before building Gtk2::MozEmbed. +- +-Note: it seems that this will return NULL before you've called `show_all' +-on your Gtk2::Window object, so check if this returns undef. +- +-=cut +-## void gtk_moz_embed_get_nsIWebBrowser (GtkMozEmbed *embed, nsIWebBrowser **retval) +-nsIWebBrowser * +-gtk_moz_embed_get_nsIWebBrowser (embed) +- GtkMozEmbed *embed +- PREINIT: +- nsIWebBrowser *browser; +- CODE: +- gtk_moz_embed_get_nsIWebBrowser (embed, &browser); +- RETVAL = browser; +- OUTPUT: +- RETVAL +- +-#endif + + # --------------------------------------------------------------------------- # + +--- a/gtkmozembed2perl.h ++++ b/gtkmozembed2perl.h +@@ -33,11 +33,6 @@ + + #include + +-#ifdef __cplusplus /* implies Mozilla::DOM is installed */ +-#include +-#include +-#endif +- + #include "gtkmozembed2perl-version.h" + + #if 1 /* FIXME: !GTK_MOZ_EMBED_CHECK_VERSION (x, y, z) */ --- libgtk2-mozembed-perl-0.08.orig/debian/patches/dont-pollute-HOME +++ libgtk2-mozembed-perl-0.08/debian/patches/dont-pollute-HOME @@ -0,0 +1,33 @@ +Author: gregor herrmann +Description: use tmpdir for tests instead of polluting $HOME; + also, if $HOME doesn't exist, the tests segfault. + discovered by Niko Tyni in #525534 + +--- a/t/GtkMozEmbed.t ++++ b/t/GtkMozEmbed.t +@@ -8,13 +8,17 @@ + use Gtk2 -init; + use Gtk2::MozEmbed; + ++use File::Spec; ++use File::Path; ++ + use Test::More tests => 8; + + Gtk2::MozEmbed -> push_startup(); + Gtk2::MozEmbed -> pop_startup(); + +-Gtk2::MozEmbed -> set_comp_path($ENV{ HOME }); +-Gtk2::MozEmbed -> set_profile_path($ENV{ HOME } . "/.Schmuh", "Schmuh"); ++my $HOME = File::Spec->tmpdir(); ++Gtk2::MozEmbed -> set_comp_path($HOME); ++Gtk2::MozEmbed -> set_profile_path($HOME . "/.Schmuh", "Schmuh"); + + my $moz = Gtk2::MozEmbed -> new(); + isa_ok($moz, "Gtk2::MozEmbed"); +@@ -53,3 +57,5 @@ + + # my $single = Gtk2::MozEmbedSingle -> new(); + # isa_ok($single, "Gtk2::MozEmbedSingle"); ++ ++rmtree($HOME . "/.Schmuh"); --- libgtk2-mozembed-perl-0.08.orig/debian/patches/whatis-entry +++ libgtk2-mozembed-perl-0.08/debian/patches/whatis-entry @@ -0,0 +1,13 @@ +add a useful whatis entry to the generated man page + +--- a/xs/GtkMozEmbed.xs ++++ b/xs/GtkMozEmbed.xs +@@ -567,7 +567,7 @@ + + # --------------------------------------------------------------------------- # + +-=for object Gtk2::MozEmbed::main ++=for object Gtk2::MozEmbed::main - Perl interface to the Mozilla embedding widget + + =head1 SIGNALS +