$ cd /Users/cmv/.cpan/build/Tk-804.036-0/PNG $ /opt/homebrew/Cellar/perl/5.36.0/bin/perl -w t/cmv.t 1..5 ok 1 - use Tk::PNG; Photo 1 zsh: segmentation fault /opt/homebrew/Cellar/perl/5.36.0/bin/perl -w +t/cmv.t
Here are some relavent lines from my cmv.t file
... use_ok('Tk::PNG'); my $file = (@ARGV) ? shift : "$FindBin::RealBin/../pngtest.png"; my $mw = MainWindow->new; $mw->geometry('+10+10'); $mw->update; #### Added by --cmv sleep 10; { print STDERR "Photo 1\n"; #### Added by --cmv my $image = $mw->Photo('-format' => "png", -file => $file); print STDERR "Photo 2\n"; #### Added by --cmv ok($image, "Loaded PNG image from $file"); print STDERR "Photo 3\n"; #### Added by --cmv $mw->Label(-image => $image)->pack; print STDERR "Photo 4\n"; #### Added by --cmv $mw->update; print STDERR "Photo 5\n"; #### Added by --cmv } ...
Note 1: The $mw->update; line does cause the Tk mainwindow to show up on my screen!!!
Note 2: The problem seems to be loading the PNG photo. More digging needed here.
Many thanks to all who have provided pointers and help!
-Craig
In reply to UPDATE: Problem Installing Perl-Tk on macOS Monterey (12.6) with Apple M1 chip
by cmv
in thread Problem Installing Perl-Tk on macOS Monterey (12.6) with Apple M1 chip
by cmv
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |