GType GValue has not been registered with GPerl at C:/msys64/mingw64/lib/perl5/site_perl/Gtk3.pm

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

GType GValue has not been registered with GPerl at C:/msys64/mingw64/lib/perl5/site_perl/Gtk3.pm

gtk-perl-list
Whenever I run a program to put something into a ListStore, I get the error below:

internal problem: GType GValue (68374864) has not been registered with GPerl at C:/msys64/mingw64/lib/perl5/site_perl/Gtk3.pm line 1329.


For Example:

This Simple Program Will Trigger The Error:

use strict;
use warnings;

use Gtk3 '-init';
use Glib 'TRUE', 'FALSE';

my @data = (TRUE, 42, 'Data...');

create_liststore_with_data();

sub create_liststore_with_data  {
    my $lstore = Gtk3::ListStore->new('Glib::Boolean', 'Glib::Uint', 'Glib::String');

        my $iter = $lstore->append();

        $lstore->insert_with_values( $iter,
                0, $data[0],
                1, $data[1],
                2, $data[2] );
}


Adding The Following Line to The BOOT: Section of Glib/GBoxed.xs:

gperl_register_boxed (G_TYPE_VALUE, "Glib::Value", &gperl_value_from_sv);


Seems to fix it.

Patch needed?

Thanks.

System is MSYS2 / MinGW64 updated via pacman, as of this date.

Perl Module Version Info:
Glib 1.327
Glib::Object::Introspection 0.045
Cairo 1.106
Cairo::GObject 1.004
Pango 1.227
Gtk2 1.24992
Gtk3 0.034
_______________________________________________
gtk-perl-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-perl-list
Reply | Threaded
Open this post in threaded view
|

Re: GType GValue has not been registered with GPerl at C:/msys64/mingw64/lib/perl5/site_perl/Gtk3.pm

gtk-perl-list
Correction:

This Program:

        use strict;
        use warnings;

        use Gtk3 '-init';
        use Glib 'TRUE', 'FALSE';

        my @data = (TRUE, 42, 'Data...');

        my $lstore = Gtk3::ListStore->new('Glib::Boolean', 'Glib::Uint', 'Glib::String');

        my $iter = $lstore->append();

        $lstore->insert_with_values( $iter, 0, $data[0], 1, $data[1], 2, $data[2] );o


Causes Signal SEGV at the last line.
Runinng it with perl -d gives no more info than that.

Using any method to put data into the ListStore causes the same problem.

I built Perl from source, to enable debugging symbols in the perl
executable, but unfortunately that gives an "Access Denied" error
when run, and Windows complainst that it can't be run.

Not sure where the Segfault is coming from.

_______________________________________________
gtk-perl-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-perl-list
Reply | Threaded
Open this post in threaded view
|

Re: GType GValue has not been registered with GPerl at C:/msys64/mingw64/lib/perl5/site_perl/Gtk3.pm

Torsten Schoenfeld
On 12.06.2018 05:17, [hidden email] wrote:

> Correction:
>
> This Program:
>
> use strict;
> use warnings;
>
> use Gtk3 '-init';
> use Glib 'TRUE', 'FALSE';
>
> my @data = (TRUE, 42, 'Data...');
>
> my $lstore = Gtk3::ListStore->new('Glib::Boolean', 'Glib::Uint', 'Glib::String');
>
> my $iter = $lstore->append();
>
> $lstore->insert_with_values( $iter, 0, $data[0], 1, $data[1], 2, $data[2] );o
>
>
> Causes Signal SEGV at the last line.

Runs fine for me on Linux, so I don't know what's wrong.  If I had to
guess, I'd say it's because multiple library installations are getting
mixed up on your machine, similarly to the other issue you reported.

Can anyone else reproduce the problem on Windows?

-Torsten
_______________________________________________
gtk-perl-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-perl-list
Reply | Threaded
Open this post in threaded view
|

Re: GType GValue has not been registered with GPerl at C:/msys64/mingw64/lib/perl5/site_perl/Gtk3.pm

gtk-perl-list
This can be closed.

I have been able to successfully build Perl Gtk2 and Gtk3 on MSYS2 with currentpacman updates.

I can run the Gtk2 Demo and Examples that ship with the module, and the Gtk3 examples
here:

https://github.com/dave-theunsub/gtk3-perl-demos

Including the liststore.pl example.

Done with perl 5.22 and 5.28.
_______________________________________________
gtk-perl-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-perl-list