1

I'm trying to install Tkx on my Mac, with Perl 5.16.0 under perlbrew. Keep getting this error:

Test Summary Report
-------------------
t/tcl.t         (Wstat: 0 Tests: 18 Failed: 1)
  Failed test:  18
Files=8, Tests=54,  8 wallclock secs ( 0.04 usr  0.02 sys +  1.58 cusr  0.83 csys =  2.47 CPU)
Result: FAIL
Failed 1/8 test programs. 1/54 subtests failed.
make: *** [test_dynamic] Error 255
  GAAS/Tkx-1.09.tar.gz
  /usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
  reports GAAS/Tkx-1.09.tar.gz
Running make install
  make test had returned bad status, won't install without force
Failed during this command:
 GAAS/Tkx-1.09.tar.gz                         : make_test NO

When I execute reports GAAS/Tkx-1.09.tar.gz (inside the CPAN shell) I get this:

Distribution: G/GA/GAAS/Tkx-1.09.tar.gz
Fetching 'http://www.cpantesters.org/show/Tkx.yaml'...DONE

Catching error: "CPAN::Exception::yaml_process_error=HASH(0x7fb392b404b8)" at /Users/daryl/perl5/perlbrew/perls/perl-5.16.0/lib/5.16.0/CPAN.pm line 392.
    CPAN::shell() called at -e line 1

Early in this process, I noticed that in the directory ~/.cpan/sources/authors/id about half the directories were owned by root, the others by me. I did "chown -R $USER" at the .cpan level and all my other installs have been okay. Also, "install Tk" succeeded; I guess I can revert to Tk but I really wanted to try Tkx. So much so that I ran "notest install Tk". I'm sure I'll run into an issue soon, so if there is an answer to this problem, I'd love to hear it.

RadlyEel
  • 309
  • 3
  • 11
  • Does this answer your question? [trouble installing Tkx perl module in Ubuntu 14.04](https://stackoverflow.com/questions/38067254/trouble-installing-tkx-perl-module-in-ubuntu-14-04) – chrstphrchvz Mar 03 '21 at 09:58
  • Sorry, the "Does this answer your question?" was automatically generated; I flagged this question as a duplicate. I have now posted the same answer to both since they are for the same issue. – chrstphrchvz Mar 03 '21 at 10:02

3 Answers3

2

Tkx was last released ten years ago and has twice as many FAIL as PASS reports in CPAN Testers. I don't think you really want to try Tkx unless you have the gumption and time to fix it yourself.

This really isn't an issue with CPAN or the cpan client. Your next step is to try to install it by hand and see what the output is. Then investigate what that test is doing to see why it fails.

brian d foy
  • 129,424
  • 31
  • 207
  • 592
2

I recently adopted Tkx and published release 1.10, which allows installation to proceed despite the t/tcl.t test 18 failure.

This test failure had been reported at RT #115662 and several other places. It appears to have been caused by unexpected but minor changes to error message formatting in newer Tcl.pm. Pending the issue actually being fixed, it is not something which Tkx should abort installation over.

chrstphrchvz
  • 657
  • 5
  • 18
1

I tried to install Tkx on macOS Catalina, perlbrew with perl version 5.30.1 Running cpanm Tkx fails with the package Tcl. It is the tests for the package Tcl that fails (first): failed 20/20 test programs. 0/0 subtests failed.:

"/Users/hakonhaegland/perl5/perlbrew/perls/perl-5.30.1/bin/perl" -MExtUtils::Command::MM -e 'cp_nonempty' -- Tcl.bs blib/arch/auto/Tcl/Tcl.bs 644
PERL_DL_NONLAZY=1 "/Users/hakonhaegland/perl5/perlbrew/perls/perl-5.30.1/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/call.t .............
No subtests run
t/constants.t ........
No subtests run
t/createcmd.t ........
No subtests run
t/disposal-subs-a.t ..
No subtests run
t/disposal-subs-b.t ..
No subtests run
t/disposal-subs-c.t ..
No subtests run
t/disposal-subs-d.t ..
No subtests run
t/disposal-subs-e.t ..
No subtests run
t/disposal-subs-f.t ..
No subtests run
t/disposal-subs.t ....
No subtests run
t/eval.t .............
No subtests run
t/export_to_tcl.t ....
Failed 4/4 subtests
t/info.t .............
[...]
Files=20, Tests=0,  2 wallclock secs ( 0.07 usr  0.05 sys +  0.39 cusr  0.17 csys =  0.68 CPU)
Result: FAIL
Failed 20/20 test programs. 0/0 subtests failed.

If I download the distribution and run one of the tests manually, I get a segfault:

$ perl -Iblib/lib -Iblib/arch t/call.t
[1]    66551 segmentation fault  perl -Iblib/lib -Iblib/arch t/call.t

See also this bug report.

Håkon Hægland
  • 39,012
  • 21
  • 81
  • 174
  • Then I can mark that as a dead end and get on with my life. Thanks. – RadlyEel Apr 06 '20 at 06:55
  • It seems to install fine on my Ubuntu Linux laptop though, so the problem seems specific to macOS.. – Håkon Hægland Apr 06 '20 at 09:40
  • I recently adopted Tkx. The errors in this answer are likely examples of [RT #132668](https://rt.cpan.org/Ticket/Display.html?id=132668)/[RT #132729](https://rt.cpan.org/Ticket/Display.html?id=132729): the Tcl.pm prerequisite currently requires some manual effort to correctly install on macOS and/or use a Tcl/Tk other than the very old version shipped with macOS. [RT #132278](https://rt.cpan.org/Public/Bug/Display.html?id=132278), which the answer linked to, is irrelevant. – chrstphrchvz Mar 03 '21 at 09:23