From 436fb243c979bbf016363a8568286b598d3245af Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <[email protected]>
Date: Wed, 23 Mar 2016 14:09:24 +0100
Subject: 4.14.3 bump
---
.gitignore | 1 +
.rpmlint | 3 +
0001-Changes-to-support-perl-5.18.0.patch | 480 ---------------------
0002-Fixes-for-perl-5.18.patch | 153 -------
...l-Peel-SvREFCNT_inc-removed-from-perl-5.2.patch | 67 ---
...96.0-Initialize-smokeperl_object-properly.patch | 37 --
perl-Qt.spec | 65 ++-
...copy-of-the-Qt-AutoLoad-AUTOLOAD-variable.patch | 42 --
...14.3-Initialize-smokeperl_object-properly.patch | 36 ++
sources | 2 +-
10 files changed, 72 insertions(+), 814 deletions(-)
create mode 100644 .rpmlint
delete mode 100644 0001-Changes-to-support-perl-5.18.0.patch
delete mode 100644 0002-Fixes-for-perl-5.18.patch
delete mode 100644
Qt-0.96.0-Bundle-Devel-Peel-SvREFCNT_inc-removed-from-perl-5.2.patch
delete mode 100644 Qt-0.96.0-Initialize-smokeperl_object-properly.patch
delete mode 100644
perlqt-4.14.2-Use-a-copy-of-the-Qt-AutoLoad-AUTOLOAD-variable.patch
create mode 100644 perlqt-4.14.3-Initialize-smokeperl_object-properly.patch
diff --git a/.gitignore b/.gitignore
index d4cc362..0caa298 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
/Qt-0.96.0.tar.gz
+/perlqt-4.14.3.tar.xz
diff --git a/.rpmlint b/.rpmlint
new file mode 100644
index 0000000..6e84d5a
--- /dev/null
+++ b/.rpmlint
@@ -0,0 +1,3 @@
+from Config import *
+addFilter("file-not-utf8 .*/encodedfiles/iso-8859-.*\.txt");
+addFilter("wrong-script-interpreter
/usr/share/doc/perl-Qt-devel/examples/linguist/hellotr/hellotr.pro");
diff --git a/0001-Changes-to-support-perl-5.18.0.patch
b/0001-Changes-to-support-perl-5.18.0.patch
deleted file mode 100644
index 96ba9c9..0000000
--- a/0001-Changes-to-support-perl-5.18.0.patch
+++ /dev/null
@@ -1,480 +0,0 @@
-From aa2083b40c83fad6b931a2088ae69bc206a7edc7 Mon Sep 17 00:00:00 2001
-From: Chris Burel <[email protected]>
-Date: Fri, 23 Aug 2013 12:04:01 -0700
-Subject: [PATCH 1/2] Changes to support perl 5.18.0.
-
-Perl no longer calls the AUTOLOAD method for DESTROY. So that has to be
defined explicitly.
-It also didn't like bless \shift, $package, so I've changed that as well.
-defined @array is deprecated, update that code.
-Also remove spurious breakpoints in example code.
-Also, CMake seems to have changed, so the prove "macro" is now a function,
because functions support actual scope on cmake variables.
----
- cmake/MacroProve.cmake | 4 +-
- qtcore/lib/QtCore4.pm | 85 ++++-----
- qtcore/src/QtCore4.xs | 2 +
- qtcore/src/util.cpp | 190 ++++++++++++---------
- qtcore/src/util.h | 1 +
- qtcore/t/d_sigslot.t | 1 -
- qtcore/t/qabstractitemmodel.t | 1 -
- qtgui/examples/tools/customcompleter/TextEdit.pm | 1 -
- .../tools/settingseditor/VariantDelegate.pm | 1 -
- qtgui/t/itemviewspuzzle.t | 2 -
- 10 files changed, 154 insertions(+), 134 deletions(-)
-
-SKIP diff --git a/cmake/MacroProve.cmake b/cmake/MacroProve.cmake
-SKIP index 13387af..489878a 100644
-SKIP --- a/cmake/MacroProve.cmake
-SKIP +++ b/cmake/MacroProve.cmake
-SKIP @@ -1,5 +1,5 @@
-SKIP
-SKIP -MACRO( MACRO_PROVE _testname _path)
-SKIP +FUNCTION( MACRO_PROVE _testname _path)
-SKIP
-SKIP if(WIN32)
-SKIP set(prove_cmd "prove.bat")
-SKIP @@ -20,4 +20,4 @@ MACRO( MACRO_PROVE _testname _path)
-SKIP endif(_workingdir)
-SKIP
-SKIP add_test(${_testname} ${prove_cmd} ${prove_args} ${escaped_path})
-SKIP -ENDMACRO( MACRO_PROVE _testname _path )
-SKIP +ENDFUNCTION( MACRO_PROVE _testname _path )
-diff --git a/qtcore/lib/QtCore4.pm b/qtcore/lib/QtCore4.pm
-index b14e817..0459dd8 100644
---- a/qtcore/lib/QtCore4.pm
-+++ b/qtcore/lib/QtCore4.pm
-@@ -1301,12 +1301,15 @@ sub init_class {
-
- foreach my $sp ('', ' ') {
- my $where = $sp . $perlClassName;
-- installautoload($where);
-- # Putting this in one package gives XS_AUTOLOAD one spot to look for
-- # the autoload variable
-- package Qt::AutoLoad;
-- my $autosub = \&{$where . '::_UTOLOAD'};
-- Qt::_internal::installSub( $where.'::AUTOLOAD', sub{&$autosub} );
-+
-+ if (!exists &{$where . '::AUTOLOAD'}) {
-+ installautoload($where);
-+ # Putting this in one package gives XS_AUTOLOAD one spot to look
for
-+ # the autoload variable
-+ package Qt::AutoLoad;
-+ my $autosub = \&{$where . '::_UTOLOAD'};
-+ Qt::_internal::installSub( $where.'::AUTOLOAD', sub{&$autosub} );
-+ }
- }
-
- installSub("$perlClassName\::NEW", sub {
-@@ -1417,9 +1420,9 @@ sub makeMetaData {
- my $signals = $meta->{signals};
- my $slots = $meta->{slots};
-
-- @{$classinfos} = () if !defined @{$classinfos};
-- @{$signals} = () if !defined @{$signals};
-- @{$slots} = () if !defined @{$slots};
-+ @{$classinfos} = () if !defined $classinfos;
-+ @{$signals} = () if !defined $signals;
-+ @{$slots} = () if !defined $slots;
-
- # Each entry in 'stringdata' corresponds to a string in the
- # qt_meta_stringdata_<classname> structure.
-@@ -1805,67 +1808,67 @@ Qt::_internal::installSub(' Qt::Variant::value', sub {
- });
-
- sub String {
-- if ( @_ ) {
-- return bless \shift, 'Qt::String';
-- } else {
-- return bless '', 'Qt::String';
-+ my ($val) = @_;
-+ if ( !$val ) {
-+ $val = '';
- }
-+ return bless \$val, 'Qt::String';
- }
-
- sub CString {
-- if ( @_ ) {
-- return bless \shift, 'Qt::CString';
-- } else {
-- return bless '', 'Qt::CString';
-+ my ($val) = @_;
-+ if ( !$val ) {
-+ $val = '';
- }
-+ return bless \$val, 'Qt::CString';
- }
-
- sub Int {
-- if ( @_ ) {
-- return bless \shift, 'Qt::Int';
-- } else {
-- return bless '', 'Qt::Int';
-+ my ($val) = @_;
-+ if ( !$val ) {
-+ $val = '';
- }
-+ return bless \$val, 'Qt::Int';
- }
-
- sub Uint {
-- if ( @_ ) {
-- return bless \shift, 'Qt::Uint';
-- } else {
-- return bless '', 'Qt::Uint';
-+ my ($val) = @_;
-+ if ( !$val ) {
-+ $val = '';
- }
-+ return bless \$val, 'Qt::Uint';
- }
-
- sub Bool {
-- if ( @_ ) {
-- return bless \shift, 'Qt::Bool';
-- } else {
-- return bless '', 'Qt::Bool';
-+ my ($val) = @_;
-+ if ( !$val ) {
-+ $val = '';
- }
-+ return bless \$val, 'Qt::Bool';
- }
-
- sub Short {
-- if ( @_ ) {
-- return bless \shift, 'Qt::Short';
-- } else {
-- return bless '', 'Qt::Short';
-+ my ($val) = @_;
-+ if ( !$val ) {
-+ $val = '';
- }
-+ return bless \$val, 'Qt::Short';
- }
-
- sub Ushort {
-- if ( @_ ) {
-- return bless \shift, 'Qt::Ushort';
-- } else {
-- return bless '', 'Qt::Ushort';
-+ my ($val) = @_;
-+ if ( !$val ) {
-+ $val = '';
- }
-+ return bless \$val, 'Qt::Ushort';
- }
-
- sub Uchar {
-- if ( @_ ) {
-- return bless \shift, 'Qt::Uchar';
-- } else {
-- return bless '', 'Qt::Uchar';
-+ my ($val) = @_;
-+ if ( !$val ) {
-+ $val = '';
- }
-+ return bless \$val, 'Qt::Uchar';
- }
-
- 1;
-diff --git a/qtcore/src/QtCore4.xs b/qtcore/src/QtCore4.xs
-index fd219c5..a699132 100644
---- a/qtcore/src/QtCore4.xs
-+++ b/qtcore/src/QtCore4.xs
-@@ -249,6 +249,8 @@ installautoload( package )
- char* autoload = new char[strlen(package) + 11];
- sprintf(autoload, "%s::_UTOLOAD", package);
- newXS(autoload, XS_AUTOLOAD, __FILE__);
-+ sprintf(autoload, "%s::DESTROY", package);
-+ newXS(autoload, XS_DESTROY, __FILE__);
- delete[] autoload;
-
- void
-diff --git a/qtcore/src/util.cpp b/qtcore/src/util.cpp
-index f66fb6b..a163e7e 100644
---- a/qtcore/src/util.cpp
-+++ b/qtcore/src/util.cpp
-@@ -1939,6 +1939,109 @@ XS(XS_qvariant_from_value) {
- XSRETURN(1);
- }
-
-+XS(XS_DESTROY) {
-+ dXSARGS;
-+ PERL_SET_CONTEXT(PL_curinterp);
-+ char* package = HvNAME(SvSTASH(SvRV(ST(0))));
-+ ++package;
-+
-+#ifdef PERLQTDEBUG
-+ if( do_debug && ( do_debug & qtdb_autoload ) ) {
-+ fprintf(stderr, "In XS DESTROY for %s", package);
-+ if((do_debug & qtdb_verbose)) {
-+ smokeperl_object *o = sv_obj_info(ST(0));
-+ if(o)
-+ fprintf(stderr, " - SV*: %p this: (%s)%p\n", ST(0),
o->smoke->classes[o->classId].className, o->ptr);
-+ else
-+ fprintf(stderr, " - this: (unknown)(nil)\n");
-+ }
-+ else {
-+ fprintf(stderr, "\n");
-+ }
-+ }
-+#endif
-+
-+ // For anything we do here where withObject is true, sv_this should be set
-+ // to the first argument on the stack, since that's where perl puts it.
-+ // Wherever we return, be sure to restore sv_this.
-+ SV* old_this = 0;
-+ old_this = sv_this;
-+ sv_this = newSVsv(ST(0));
-+
-+ smokeperl_object* o = sv_obj_info(sv_this);
-+
-+ // Check to see that o exists (has a smokeperl_object in sv_this), has
-+ // a valid pointer, and (is allocated or has an entry in the pointer
-+ // map). If all of that's true, or we're in global destruction, we
-+ // don't really care what happens.
-+ if( PL_dirty ) {
-+ // This block will be repeated a lot to clean stuff up.
-+ // Restore sv_this
-+ SvREFCNT_dec(sv_this);
-+ sv_this = old_this;
-+ XSRETURN_YES;
-+ }
-+ if( !(o && o->ptr && (o->allocated || getPointerObject(o->ptr))) ) {
-+ // This block will be repeated a lot to clean stuff up.
-+ // Restore sv_this
-+ SvREFCNT_dec(sv_this);
-+ sv_this = old_this;
-+ XSRETURN_YES;
-+ }
-+
-+ // Check to see if a delete of this object has been tried before, by
-+ // seeing if the object's hash has the "has been hidden" key
-+ static const char* key = "has been hidden";
-+ U32 klen = 15;
-+ SV** svp = 0;
-+ if( SvROK(sv_this) && SvTYPE(SvRV(sv_this)) == SVt_PVHV ) {
-+ HV* hv = (HV*)SvRV(sv_this);
-+ svp = hv_fetch( hv, key, klen, 0);
-+ }
-+ if(svp) {
-+ // Found "has been hidden", so don't do anything, just clean up
-+ // Restore sv_this
-+ SvREFCNT_dec(sv_this);
-+ sv_this = old_this;
-+ XSRETURN_YES;
-+ }
-+
-+#ifdef PERLQTDEBUG
-+ // The following perl call seems to stomp on the package name, let's copy
it
-+ char* packagecpy = new char[strlen(package)+1];
-+ strcpy( packagecpy, package );
-+#endif
-+
-+ // Call the ON_DESTROY method, that stores a reference (increasing the
-+ // refcnt) if necessary
-+ HV* stash = gv_stashpv(package, TRUE);
-+ GV* gv = gv_fetchmethod_autoload(stash, "ON_DESTROY", 0);
-+ int retval = 0;
-+ if( gv ) {
-+ PUSHMARK(SP);
-+ int count = call_sv((SV*)GvCV(gv), G_SCALAR|G_NOARGS);
-+ SPAGAIN;
-+ if (count != 1) {
-+ // Restore sv_this
-+ SvREFCNT_dec(sv_this);
-+ sv_this = old_this;
-+ croak( "Corrupt ON_DESTROY return value: Got %d value(s),
expected 1\n", count );
-+ }
-+ retval = POPi;
-+ PUTBACK;
-+ }
-+
-+#ifdef PERLQTDEBUG
-+ if( do_debug && retval && (do_debug & qtdb_gc) )
-+ fprintf(stderr, "Increasing refcount in DESTROY for %s=%p (still has
a parent)\n", packagecpy, o->ptr);
-+ delete[] packagecpy;
-+#endif
-+
-+ // Now clean up
-+ SvREFCNT_dec(sv_this);
-+ sv_this = old_this;
-+}
-+
- XS(XS_AUTOLOAD) {
- dXSARGS;
- PERL_SET_CONTEXT(PL_curinterp);
-@@ -2045,95 +2148,12 @@ XS(XS_AUTOLOAD) {
- else
- XSRETURN(count);
- }
-- else if( !strcmp( methodname, "DESTROY" ) ) {
-- smokeperl_object* o = sv_obj_info(sv_this);
--
-- // Check to see that o exists (has a smokeperl_object in sv_this), has
-- // a valid pointer, and (is allocated or has an entry in the pointer
-- // map). If all of that's true, or we're in global destruction, we
-- // don't really care what happens.
-- if( PL_dirty ) {
-- // This block will be repeated a lot to clean stuff up.
-- if( withObject ) {
-- // Restore sv_this
-- SvREFCNT_dec(sv_this);
-- sv_this = old_this;
-- }
-- XSRETURN_YES;
-- }
-- if( !(o && o->ptr && (o->allocated || getPointerObject(o->ptr))) ) {
-- // This block will be repeated a lot to clean stuff up.
-- if( withObject ) {
-- // Restore sv_this
-- SvREFCNT_dec(sv_this);
-- sv_this = old_this;
-- }
-- XSRETURN_YES;
-- }
--
-- // Check to see if a delete of this object has been tried before, by
-- // seeing if the object's hash has the "has been hidden" key
-- static const char* key = "has been hidden";
-- U32 klen = 15;
-- SV** svp = 0;
-- if( SvROK(sv_this) && SvTYPE(SvRV(sv_this)) == SVt_PVHV ) {
-- HV* hv = (HV*)SvRV(sv_this);
-- svp = hv_fetch( hv, key, klen, 0);
-- }
-- if(svp) {
-- // Found "has been hidden", so don't do anything, just clean up
-- if( withObject ) {
-- // Restore sv_this
-- SvREFCNT_dec(sv_this);
-- sv_this = old_this;
-- }
-- XSRETURN_YES;
-- }
--
--#ifdef PERLQTDEBUG
-- // The following perl call seems to stomp on the package name, let's
copy it
-- char* packagecpy = new char[strlen(package)+1];
-- strcpy( packagecpy, package );
--#endif
--
-- // Call the ON_DESTROY method, that stores a reference (increasing the
-- // refcnt) if necessary
-- if( !stash )
-- stash = gv_stashpv(package, TRUE);
-- gv = gv_fetchmethod_autoload(stash, "ON_DESTROY", 0);
-- int retval = 0;
-- if( gv ) {
-- PUSHMARK(SP);
-- int count = call_sv((SV*)GvCV(gv), G_SCALAR|G_NOARGS);
-- SPAGAIN;
-- if (count != 1) {
-- if( withObject ) {
-- // Restore sv_this
-- SvREFCNT_dec(sv_this);
-- sv_this = old_this;
-- }
-- croak( "Corrupt ON_DESTROY return value: Got %d value(s),
expected 1\n", count );
-- }
-- retval = POPi;
-- PUTBACK;
-- }
--
--#ifdef PERLQTDEBUG
-- if( do_debug && retval && (do_debug & qtdb_gc) )
-- fprintf(stderr, "Increasing refcount in DESTROY for %s=%p (still
has a parent)\n", packagecpy, o->ptr);
-- delete[] packagecpy;
--#endif
--
-- // Now clean up
-- if( withObject ) {
-- SvREFCNT_dec(sv_this);
-- sv_this = old_this;
-- }
-- }
- else {
- // We're calling a c++ method
-
- // Get the classId (eventually converting SUPER to the right Qt4
class)
-+ if (super && strcmp( super, "SUPER" ) == 0)
-+ package[strlen(package)-7] = 0;
- SV* moduleIdRef = package_classId( package );
- Smoke::ModuleIndex mi;
-
-diff --git a/qtcore/src/util.h b/qtcore/src/util.h
-index bd4bf31..430a8eb 100644
---- a/qtcore/src/util.h
-+++ b/qtcore/src/util.h
-@@ -98,6 +98,7 @@ XS(XS_qdatastream_readrawdata);
- XS(XS_qvariant_value);
- XS(XS_qvariant_from_value);
-
-+XS(XS_DESTROY);
- XS(XS_AUTOLOAD);
- XS(XS_qt_metacall);
- XS(XS_signal);
-diff --git a/qtcore/t/d_sigslot.t b/qtcore/t/d_sigslot.t
-index eea16c8..3d02f2e 100644
---- a/qtcore/t/d_sigslot.t
-+++ b/qtcore/t/d_sigslot.t
-@@ -30,7 +30,6 @@ sub NEW {
- emit signal( 5, 4 );
-
- # 3) Emit a signal, but missing an argument. Should fail.
-- $DB::single=1;
- eval{ emit signalWithBadArg() };
- like( $@, qr/Wrong number of arguments in signal call/, 'Missing
arguments in signal' );
- }
-diff --git a/qtcore/t/qabstractitemmodel.t b/qtcore/t/qabstractitemmodel.t
-index ae1174c..3e2baba 100644
---- a/qtcore/t/qabstractitemmodel.t
-+++ b/qtcore/t/qabstractitemmodel.t
-@@ -4,7 +4,6 @@ package TestModel;
-
- use strict;
- use warnings;
--use blib;
- use QtCore4;
- use QtCore4::isa qw( Qt::AbstractItemModel );
-
-diff --git a/qtgui/examples/tools/customcompleter/TextEdit.pm
b/qtgui/examples/tools/customcompleter/TextEdit.pm
-index 9b4e26f..3e82ae4 100644
---- a/qtgui/examples/tools/customcompleter/TextEdit.pm
-+++ b/qtgui/examples/tools/customcompleter/TextEdit.pm
-@@ -61,7 +61,6 @@ sub insertCompletion
- return;
- }
- my $tc = textCursor();
-- $DB::single=1;
- my $extra = length($completion) - length(c->completionPrefix());
- $tc->movePosition(Qt::TextCursor::Left());
- $tc->movePosition(Qt::TextCursor::EndOfWord());
-diff --git a/qtgui/examples/tools/settingseditor/VariantDelegate.pm
b/qtgui/examples/tools/settingseditor/VariantDelegate.pm
-index 5d91d3f..e450efb 100644
---- a/qtgui/examples/tools/settingseditor/VariantDelegate.pm
-+++ b/qtgui/examples/tools/settingseditor/VariantDelegate.pm
-@@ -197,7 +197,6 @@ sub setModelData
- }
-
- my $text = $lineEdit->text();
-- $DB::single=1;
- my $validator = $lineEdit->validator();
- if ($validator) {
- my $pos;
-SKIP diff --git a/qtgui/t/itemviewspuzzle.t b/qtgui/t/itemviewspuzzle.t
-SKIP index 4a6b623..ea1c07e 100644
-SKIP --- a/qtgui/t/itemviewspuzzle.t
-SKIP +++ b/qtgui/t/itemviewspuzzle.t
-SKIP @@ -85,8 +85,6 @@ sub initTestCase {
-SKIP Qt::Test::qWaitForWindowShown( $window );
-SKIP this->{window} = $window;
-SKIP pass( 'Window shown' );
-SKIP - $DB::single=1;
-SKIP - 1;
-SKIP }
-SKIP
-SKIP package main;
-SKIP --
-SKIP 1.8.3.1
-SKIP
diff --git a/0002-Fixes-for-perl-5.18.patch b/0002-Fixes-for-perl-5.18.patch
deleted file mode 100644
index a1a71e0..0000000
--- a/0002-Fixes-for-perl-5.18.patch
+++ /dev/null
@@ -1,153 +0,0 @@
-From d4627fb5f3a571212457df22e2ab861b890fc992 Mon Sep 17 00:00:00 2001
-From: Chris Burel <[email protected]>
-Date: Fri, 23 Aug 2013 14:56:37 -0700
-Subject: [PATCH 2/2] Fixes for perl 5.18
-
-I'm not really sure how this was working before, but perl 5.18 really wasn't
-happy. The way these functions work is really tricky, because the marshallers
-expect to be able to set the scalar ref's returned from them. My previous fix
-didn't allow the refs to be set correctly.
----
- qtcore/lib/QtCore4.pm | 90 +++++++++++++++++++++++++++++++++------------------
- 1 file changed, 58 insertions(+), 32 deletions(-)
-
-diff --git a/qtcore/lib/QtCore4.pm b/qtcore/lib/QtCore4.pm
-index 0459dd8..1a5e454 100644
---- a/qtcore/lib/QtCore4.pm
-+++ b/qtcore/lib/QtCore4.pm
-@@ -1649,6 +1649,8 @@ package Qt;
- use strict;
- use warnings;
-
-+use Scalar::Util;
-+
- # Called in the DESTROY method for all QObjects to see if they still have a
- # parent, and avoid deleting them if they do.
- sub Qt::Object::ON_DESTROY {
-@@ -1808,67 +1810,91 @@ Qt::_internal::installSub(' Qt::Variant::value', sub {
- });
-
- sub String {
-- my ($val) = @_;
-- if ( !$val ) {
-- $val = '';
-+ if ( scalar @_ ) {
-+ if ( Scalar::Util::readonly( $_[0] ) ) {
-+ my $val = shift;
-+ return bless \$val, 'Qt::String';
-+ }
-+ return bless \shift, 'Qt::String';
- }
-- return bless \$val, 'Qt::String';
-+ return bless '', 'Qt::String';
- }
-
- sub CString {
-- my ($val) = @_;
-- if ( !$val ) {
-- $val = '';
-+ if ( scalar @_ ) {
-+ if ( Scalar::Util::readonly( $_[0] ) ) {
-+ my $val = shift;
-+ return bless \$val, 'Qt::CString';
-+ }
-+ return bless \shift, 'Qt::CString';
- }
-- return bless \$val, 'Qt::CString';
-+ return bless '', 'Qt::CString';
- }
-
- sub Int {
-- my ($val) = @_;
-- if ( !$val ) {
-- $val = '';
-+ if ( scalar @_ ) {
-+ if ( Scalar::Util::readonly( $_[0] ) ) {
-+ my $val = shift;
-+ return bless \$val, 'Qt::Int';
-+ }
-+ return bless \shift, 'Qt::Int';
- }
-- return bless \$val, 'Qt::Int';
-+ return bless '', 'Qt::Int';
- }
-
- sub Uint {
-- my ($val) = @_;
-- if ( !$val ) {
-- $val = '';
-+ if ( scalar @_ ) {
-+ if ( Scalar::Util::readonly( $_[0] ) ) {
-+ my $val = shift;
-+ return bless \$val, 'Qt::Uint';
-+ }
-+ return bless \shift, 'Qt::Uint';
- }
-- return bless \$val, 'Qt::Uint';
-+ return bless '', 'Qt::Uint';
- }
-
- sub Bool {
-- my ($val) = @_;
-- if ( !$val ) {
-- $val = '';
-+ if ( scalar @_ ) {
-+ if ( Scalar::Util::readonly( $_[0] ) ) {
-+ my $val = shift;
-+ return bless \$val, 'Qt::Bool';
-+ }
-+ return bless \shift, 'Qt::Bool';
- }
-- return bless \$val, 'Qt::Bool';
-+ return bless '', 'Qt::Bool';
- }
-
- sub Short {
-- my ($val) = @_;
-- if ( !$val ) {
-- $val = '';
-+ if ( scalar @_ ) {
-+ if ( Scalar::Util::readonly( $_[0] ) ) {
-+ my $val = shift;
-+ return bless \$val, 'Qt::Short';
-+ }
-+ return bless \shift, 'Qt::Short';
- }
-- return bless \$val, 'Qt::Short';
-+ return bless '', 'Qt::Short';
- }
-
- sub Ushort {
-- my ($val) = @_;
-- if ( !$val ) {
-- $val = '';
-+ if ( scalar @_ ) {
-+ if ( Scalar::Util::readonly( $_[0] ) ) {
-+ my $val = shift;
-+ return bless \$val, 'Qt::Ushort';
-+ }
-+ return bless \shift, 'Qt::Ushort';
- }
-- return bless \$val, 'Qt::Ushort';
-+ return bless '', 'Qt::Ushort';
- }
-
- sub Uchar {
-- my ($val) = @_;
-- if ( !$val ) {
-- $val = '';
-+ if ( scalar @_ ) {
-+ if ( Scalar::Util::readonly( $_[0] ) ) {
-+ my $val = shift;
-+ return bless \$val, 'Qt::Uchar';
-+ }
-+ return bless \shift, 'Qt::Uchar';
- }
-- return bless \$val, 'Qt::Uchar';
-+ return bless '', 'Qt::Uchar';
- }
-
- 1;
---
-1.8.3.1
-
diff --git
a/Qt-0.96.0-Bundle-Devel-Peel-SvREFCNT_inc-removed-from-perl-5.2.patch
b/Qt-0.96.0-Bundle-Devel-Peel-SvREFCNT_inc-removed-from-perl-5.2.patch
deleted file mode 100644
index 441c064..0000000
--- a/Qt-0.96.0-Bundle-Devel-Peel-SvREFCNT_inc-removed-from-perl-5.2.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-From 1f62c5d8dd589e7131df0b378513148375e41317 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <[email protected]>
-Date: Thu, 11 Sep 2014 16:48:39 +0200
-Subject: [PATCH] Bundle Devel::Peel::SvREFCNT_inc removed from perl-5.20.0
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Patch taken from Ubuntu:
-
-perlqt (4:4.14.0-0ubuntu4) utopic; urgency=medium
-
- * Devel::Peek in Perl 5.20 no longer exports SvREFCNT_inc, so put a copy
- in QtGui4::_internal instead. Fixes perlkde build.
-
- -- Colin Watson <[email protected]> Tue, 26 Aug 2014 14:13:07 -0700
-
-CPAN RT#98790
-
-Signed-off-by: Petr Písař <[email protected]>
----
- qtgui/lib/QtGui4.pm | 3 +--
- qtgui/src/QtGui4.xs | 7 +++++++
- 2 files changed, 8 insertions(+), 2 deletions(-)
-
-diff --git a/qtgui/lib/QtGui4.pm b/qtgui/lib/QtGui4.pm
-index a33f66a..2fae3d7 100644
---- a/qtgui/lib/QtGui4.pm
-+++ b/qtgui/lib/QtGui4.pm
-@@ -22,7 +22,6 @@ use warnings;
-
- use QtCore4;
- use base qw(Qt::_internal);
--use Devel::Peek qw( SvREFCNT_inc );
-
- sub init {
- @Qt::_internal::vectorTypes{qw(Qt::Polygon Qt::PolygonF
Qt::ItemSelection)}
-@@ -76,7 +75,7 @@ sub Qt::GraphicsObject::ON_DESTROY {
- }
-
- sub Qt::UndoCommand::ON_DESTROY {
-- Devel::Peek::SvREFCNT_inc( Qt::this() );
-+ QtGui4::_internal->SvREFCNT_inc( Qt::this() );
- # XXX is there a better solution here?
- return 1;
- }
-diff --git a/qtgui/src/QtGui4.xs b/qtgui/src/QtGui4.xs
-index e1a0783..3a23ad4 100644
---- a/qtgui/src/QtGui4.xs
-+++ b/qtgui/src/QtGui4.xs
-@@ -91,6 +91,13 @@ getEnumList()
- OUTPUT:
- RETVAL
-
-+SV*
-+SvREFCNT_inc(sv)
-+ SV* sv
-+ PPCODE:
-+ RETVAL = SvREFCNT_inc(sv);
-+ PUSHs(RETVAL);
-+
- MODULE = QtGui4 PACKAGE = QtGui4
-
- PROTOTYPES: ENABLE
---
-1.9.3
-
diff --git a/Qt-0.96.0-Initialize-smokeperl_object-properly.patch
b/Qt-0.96.0-Initialize-smokeperl_object-properly.patch
deleted file mode 100644
index 279c524..0000000
--- a/Qt-0.96.0-Initialize-smokeperl_object-properly.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 1d30fbbd8fad3d9ee87f1b524384bb337c559d88 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <[email protected]>
-Date: Mon, 1 Feb 2016 16:31:45 +0100
-Subject: [PATCH] Initialize smokeperl_object properly
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-This patch fixes this build failure with GCC 6:
-
-/builddir/build/BUILD/Qt-0.96.0/qtcore/src/util.cpp:2248:59: error: cannot
convert 'bool' to 'void*' in initialization
- static smokeperl_object nothis = { 0, 0, 0, false };
- ^
-
-CPAN RT#111630
-
-Signed-off-by: Petr Písař <[email protected]>
----
- qtcore/src/util.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/qtcore/src/util.cpp b/qtcore/src/util.cpp
-index 0c94e32..4857573 100644
---- a/qtcore/src/util.cpp
-+++ b/qtcore/src/util.cpp
-@@ -2225,7 +2225,7 @@ XS(XS_AUTOLOAD) {
- methcache.insert(mcid, new Smoke::ModuleIndex(mi));
- }
-
-- static smokeperl_object nothis = { 0, 0, 0, false };
-+ static smokeperl_object nothis = { 0, 0, 0, NULL };
- smokeperl_object* call_this = 0;
- if ( SvOK(sv_this) ) {
- call_this = sv_obj_info( sv_this );
---
-2.5.0
-
diff --git a/perl-Qt.spec b/perl-Qt.spec
index 5f24070..034d365 100644
--- a/perl-Qt.spec
+++ b/perl-Qt.spec
@@ -1,30 +1,25 @@
%global use_x11_tests 1
Name: perl-Qt
-Version: 0.96.0
-Release: 19%{?dist}
+Version: 4.14.3
+Release: 1%{?dist}
Summary: Perl bindings for Qt
-# Files under qtcore/tools/ and qtdbus/tools/ are LGPLv2.1+ with Nokia
-# exceptions or GPLv3+. The Nokia files only appear in -devel subpackage.
-# QtCore4.pm is 'same terms as Perl itself'. The rest is GPLv2+.
+# qtcore/lib/QtCore4.pm: GPL+ or Artistic
+# other files: GPLv2+
+## devel subpackage
+# qtcore/tools: LGPLv2+ with Nokia exceptions or GPLv3+
+# qtcore/tools/puic/perl/plwriteinitialization.h:
+# GPLv2 or GPLv3+ with Trolltech exception
+# qtdbus/tools: LGPLv2.1+ with Nokia exceptions or GPLv3+
+# qtgui/examples/draganddrop/delayedencoding/images/example.svg:
+# LGPLv2 with Nokia exception or GPLv3+
+# qtgui/examples/xml/htmlinfo/apache_org.html: ASL 2.0
License: GPLv2+ and (GPL+ or Artistic)
Group: Development/Libraries
-URL: http://search.cpan.org/dist/Qt/
-Source0: http://www.cpan.org/modules/by-module/Qt/Qt-%{version}.tar.gz
-Patch1: 0001-Changes-to-support-perl-5.18.0.patch
-Patch2: 0002-Fixes-for-perl-5.18.patch
-# Adjust to perl-5.20.0, bug #1136340, CPAN RT#98790, in new upstream
-# <git://anongit.kde.org/perlqt>
-Patch3:
Qt-0.96.0-Bundle-Devel-Peel-SvREFCNT_inc-removed-from-perl-5.2.patch
-# Adjust to perl-5.20.0, bug #1136340, CPAN RT#98790, in new upstream
-# <git://anongit.kde.org/perlqt>
-Patch4:
perlqt-4.14.2-Use-a-copy-of-the-Qt-AutoLoad-AUTOLOAD-variable.patch
-# Adjust to GCC 6, bug #1303658, CPAN RT#111630
-Patch5: Qt-0.96.0-Initialize-smokeperl_object-properly.patch
-# Adjust to smokeqt's QChar, in upstream after 4.8.0
-Patch6: Qt-0.96.0-Fix-uchar-test.patch
-# Fix code generation with "puic4 -x", bug #1118240, in upstream after 4.14.3
-Patch7: Qt-0.96.0-Fix-problems-with-puic4-x-code-generation.patch
+URL: https://techbase.kde.org/Languages/Perl
+Source0:
http://download.kde.org/stable/%{version}/src/perlqt-%{version}.tar.xz
+# Adjust to GCC 6, bug #1303658, KDE bug #360844, CPAN RT#111630
+Patch1: perlqt-4.14.3-Initialize-smokeperl_object-properly.patch
BuildRequires: coreutils
BuildRequires: cmake
# gcc for C standard library headers
@@ -33,7 +28,7 @@ BuildRequires: gcc-c++
BuildRequires: make
BuildRequires: perl
BuildRequires: perl-devel
-# Perl module used by qtcore/src/doxsubpp.pl and cmake/FindPerlMore.cmake
+# Perl modules used by qtcore/src/doxsubpp.pl and cmake/FindPerlMore.cmake
BuildRequires: perl(Config)
BuildRequires: perl(ExtUtils::MakeMaker)
BuildRequires: perl(File::Spec)
@@ -81,23 +76,15 @@ This module provides Perl bindings for the Qt 4 libraries.
%package devel
Summary: Development files for perl-Qt
-License: GPLv2+ and (GPL+ or Artistic) and (LGPLv2+ with exceptions or
GPLv3+)
+License: GPLv2+ and (GPL+ or Artistic) and (LGPLv2+ with exceptions or
GPLv3+) and (LGPLv2 with exception or GPLv3+) and ASL 2.0
Requires: %{name} = %{?epoch:%{epoch}:}%{version}-%{release}
%description devel
Development files for perl-Qt.
%prep
-%setup -q -n Qt-%{version}
-
-# Fixes from upstream for Perl 5.18
+%setup -q -n perlqt-%{version}
%patch1 -p1
-%patch2 -p1
-%patch3 -p1
-%patch4 -p1
-%patch5 -p1
-%patch6 -p1
-%patch7 -p1
mkdir build
@@ -138,6 +125,11 @@ sed -i \
-e '/perlqt_mainwindowsmdi/d' \
qtgui/t/CMakeLists.txt
+# This test hangs, <https://bugs.kde.org/show_bug.cgi?id=360899>
+sed -i \
+ -e '/perlqt_itemviewspuzzle/d' \
+ qtgui/t/CMakeLists.txt
+
%ifarch armv7hl
# perlqt_qtcore4_handlers fails on armv7hl
sed -i \
@@ -156,7 +148,7 @@ make %{?_smp_mflags}
%install
cd build
-make install DESTDIR=%{buildroot}
+make install/fast DESTDIR=%{buildroot}
%{_fixperms} %{buildroot}/*
@@ -170,7 +162,7 @@ export PERL5LIB="$PWD/blib/lib:$PWD/blib/arch"
%endif
%files
-%license LICENSE
+%license LICENSE*
%doc README
%{perl_vendorarch}/*
%exclude %dir %{perl_vendorarch}/auto/
@@ -182,6 +174,11 @@ export PERL5LIB="$PWD/blib/lib:$PWD/blib/arch"
%{_datadir}/perlqt
%changelog
+* Wed Mar 23 2016 Petr Pisar <[email protected]> - 4.14.3-1
+- 4.14.3 bump (upstream changed from CPAN to KDE)
+- perl-Qt-devel license changed to (GPLv2+ and (GPL+ or Artistic) and (LGPLv2+
+ with exceptions or GPLv3+) and (LGPLv2 with exception or GPLv3+) and ASL 2.0)
+
* Tue Mar 22 2016 Petr Pisar <[email protected]> - 0.96.0-19
- Modernize spec file
- Run X11 tests
diff --git
a/perlqt-4.14.2-Use-a-copy-of-the-Qt-AutoLoad-AUTOLOAD-variable.patch
b/perlqt-4.14.2-Use-a-copy-of-the-Qt-AutoLoad-AUTOLOAD-variable.patch
deleted file mode 100644
index 7acb6d8..0000000
--- a/perlqt-4.14.2-Use-a-copy-of-the-Qt-AutoLoad-AUTOLOAD-variable.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 1b665848e178301344386717c658386d160d222a Mon Sep 17 00:00:00 2001
-From: Chris Burel <[email protected]>
-Date: Fri, 31 Oct 2014 11:23:18 -0700
-Subject: [PATCH] Use a copy of the Qt::AutoLoad::AUTOLOAD variable.
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-This appears to be a change in Perl's behavior. The way the operator
-overloading in PerlQt works is that it first tries to find an operator method
-on the class itself, and then next it tries to find one in the so-called
-QGlobalSpace, which is a place defined by the smoke library for global Qt
-functions. Perl passes the underlying XS code the full package and function
-being called, which PerlQt splits into 2 strings, one for the package name, and
-one for the method name. PerlQt null-terminates the package name string, and
-in previous versions of Perl, this modification did not affect the source
-$AUTOLOAD variable. In Perl 5.20.0, it does update the Perl variable, and then
-causes confusion down the line.
-
-https://bugzilla.redhat.com/show_bug.cgi?id=1136340
-https://bugs.kde.org/show_bug.cgi?id=340518
-Signed-off-by: Petr Písař <[email protected]>
----
- qtcore/src/util.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/qtcore/src/util.cpp b/qtcore/src/util.cpp
-index a163e7e..b913af3 100644
---- a/qtcore/src/util.cpp
-+++ b/qtcore/src/util.cpp
-@@ -2047,7 +2047,7 @@ XS(XS_AUTOLOAD) {
- PERL_SET_CONTEXT(PL_curinterp);
- // Figure out which package and method is being called, based on the
- // autoload variable
-- SV* autoload = get_sv( "Qt::AutoLoad::AUTOLOAD", TRUE );
-+ SV* autoload = sv_mortalcopy( get_sv( "Qt::AutoLoad::AUTOLOAD", TRUE ) );
- char* package = SvPV_nolen( autoload );
- char* methodname = 0;
- // Splits off the method name from the package
---
-1.9.3
-
diff --git a/perlqt-4.14.3-Initialize-smokeperl_object-properly.patch
b/perlqt-4.14.3-Initialize-smokeperl_object-properly.patch
new file mode 100644
index 0000000..69a2e48
--- /dev/null
+++ b/perlqt-4.14.3-Initialize-smokeperl_object-properly.patch
@@ -0,0 +1,36 @@
+From 70100c1865985e0cabbba5716cb9a6df8099b377 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <[email protected]>
+Date: Tue, 22 Mar 2016 11:27:24 +0100
+Subject: [PATCH] Initialize smokeperl_object properly
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This patch fixes this build failure with GCC 6:
+
+/builddir/build/BUILD/Qt-0.96.0/qtcore/src/util.cpp:2248:59: error: cannot
convert 'bool' to 'void*' in initialization
+ static smokeperl_object nothis = { 0, 0, 0, false };
+ ^
+CPAN RT#111630
+
+Signed-off-by: Petr Písař <[email protected]>
+---
+ qtcore/src/util.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/qtcore/src/util.cpp b/qtcore/src/util.cpp
+index b913af3..4c94e2c 100644
+--- a/qtcore/src/util.cpp
++++ b/qtcore/src/util.cpp
+@@ -2251,7 +2251,7 @@ XS(XS_AUTOLOAD) {
+ methcache.insert(mcid, new Smoke::ModuleIndex(mi));
+ }
+
+- static smokeperl_object nothis = { 0, 0, 0, false };
++ static smokeperl_object nothis = { 0, 0, 0, NULL };
+ smokeperl_object* call_this = 0;
+ if ( SvOK(sv_this) ) {
+ call_this = sv_obj_info( sv_this );
+--
+2.5.5
+
diff --git a/sources b/sources
index 79dc168..577069e 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-300aa694926f07e53a8ffd99350a247c Qt-0.96.0.tar.gz
+d410c5b95680d1c56d037d22ef984479 perlqt-4.14.3.tar.xz
--
cgit v1.1
https://src.fedoraproject.org/cgit/perl-Qt.git/commit/?h=epel7&id=436fb243c979bbf016363a8568286b598d3245af
_______________________________________________
perl-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]