Commit d9e5e77409 for perl

commit d9e5e774098393e1d3b858e3c09a92642406b9e0
Author: Andreas König <a.koenig@mind.de>
Date:   Fri Oct 2 08:49:51 2026 -0400

    cpan/CPAN - Update to version 2.41

    2026-09-12  k  <andreas.koenig.7os6VVqR@franz.ak.mind.de>

            * release 2.41

            * unchanged from 2.41-TRIAL

    2026-09-06  k  <andreas.koenig.7os6VVqR@franz.ak.mind.de>

            * release 2.41-TRIAL

            * Save on the 301 redirect to www.cpan.org (Kudos to Sevan Janiyan)

            * increase timeout in test script

    2026-05-24  k  <andreas.koenig.7os6VVqR@franz.ak.mind.de>
            * release 2.40-TRIAL
            * fix some internal section links (Thanks to grinnz)
            * suppress warnings in VERSION discovery (Thanks to brian d foy)
            * fix perl version check in Makefile.PL (Thanks to Lukas Mai)
            * adjust distroprefs file thanks to an intervention by mauke

    2026-04-21  k  <andreas.koenig.7os6VVqR@franz.ak.mind.de>
            * release 2.39-TRIAL
            * set Sortkeys when debugging with Data::Dumper
            * refuse calculating prereq_pm when our builddir is already cleaned up
            * fix a debug diagnostic against unini warnings
            * increase diagnostics during distroprefs resolution
            * Remove MacOS classic support (Thanks to Leon Timmermans)
            * start using the macro YAML_MODULE in the Makefile.PL
            * various distroprefs maintenance

diff --git a/Porting/Maintainers.pl b/Porting/Maintainers.pl
index 8aa4393e23..7e2458e9a6 100755
--- a/Porting/Maintainers.pl
+++ b/Porting/Maintainers.pl
@@ -274,8 +274,8 @@ our %Modules = (
     },

     'CPAN' => {
-        'DISTRIBUTION' => 'ANDK/CPAN-2.38.tar.gz',
-        'SYNCINFO'     => 'tib on Mon Nov 18 08:14:50 2024',
+        'DISTRIBUTION' => 'ANDK/CPAN-2.41.tar.gz',
+        'SYNCINFO'     => 'jkeenan on Fri Oct  2 08:49:23 2026',
         'FILES'        => q[cpan/CPAN],
         'EXCLUDED'     => [
             qr{^distroprefs/},
diff --git a/cpan/CPAN/lib/App/Cpan.pm b/cpan/CPAN/lib/App/Cpan.pm
index 6358e82a03..53fa2e5e99 100644
--- a/cpan/CPAN/lib/App/Cpan.pm
+++ b/cpan/CPAN/lib/App/Cpan.pm
@@ -6,7 +6,7 @@ use vars qw($VERSION);

 use if $] < 5.008 => 'IO::Scalar';

-$VERSION = '1.678';
+$VERSION = '1.679';

 =head1 NAME

@@ -1481,6 +1481,7 @@ sub _eval_version
 		package
 		  ExtUtils::MakeMaker::_version;

+        no warnings;
 		local $sigil$var;
 		\$$var=undef; do {
 			$line
diff --git a/cpan/CPAN/lib/CPAN.pm b/cpan/CPAN/lib/CPAN.pm
index 93f1208841..c3043ad339 100644
--- a/cpan/CPAN/lib/CPAN.pm
+++ b/cpan/CPAN/lib/CPAN.pm
@@ -2,7 +2,7 @@
 # vim: ts=4 sts=4 sw=4:
 use strict;
 package CPAN;
-$CPAN::VERSION = '2.38';
+$CPAN::VERSION = '2.41';
 $CPAN::VERSION =~ s/_//;

 # we need to run chdir all over and we would get at wrong libraries
@@ -66,7 +66,6 @@ sub _uniq;

 no lib ".";

-require Mac::BuildTools if $^O eq 'MacOS';
 if ($ENV{PERL5_CPAN_IS_RUNNING} && $$ != $ENV{PERL5_CPAN_IS_RUNNING}) {
     $ENV{PERL5_CPAN_IS_RUNNING_IN_RECURSION} ||= $ENV{PERL5_CPAN_IS_RUNNING};
     my @rec = _uniq split(/,/, $ENV{PERL5_CPAN_IS_RUNNING_IN_RECURSION}), $$;
@@ -1909,7 +1908,7 @@ B<Note>: This whole command currently is just a hack and will
 probably change in future versions of CPAN.pm, but the general
 approach will likely remain.

-B<Note>: See also L<smoke>
+B<Note>: See also L<smoke|/smoke ***EXPERIMENTAL COMMAND***>

 =head2 recompile

@@ -1953,7 +1952,7 @@ B<Note>: This whole command currently is just a hack and will
 probably change in future versions of CPAN.pm, but the general
 approach will likely remain.

-B<Note>: See also L<recent>
+B<Note>: See also L<recent|/recent ***EXPERIMENTAL COMMAND***>

 =head2 upgrade [Module|/Regexp/]...

@@ -3595,8 +3594,8 @@ See the source for details.

 =item use_inst($module)

-Similary to L<has_inst()> tries to load optional library but also dies if
-library is not available
+Similary to L</has_inst($module)> tries to load optional library but also
+dies if library is not available

 =item has_usable($module)

diff --git a/cpan/CPAN/lib/CPAN/CacheMgr.pm b/cpan/CPAN/lib/CPAN/CacheMgr.pm
index 144efd62b3..c4d4dc95e8 100644
--- a/cpan/CPAN/lib/CPAN/CacheMgr.pm
+++ b/cpan/CPAN/lib/CPAN/CacheMgr.pm
@@ -10,7 +10,7 @@ use File::Find;
 use vars qw(
             $VERSION
 );
-$VERSION = "5.5002";
+$VERSION = "5.5003";

 package CPAN::CacheMgr;
 use strict;
@@ -113,25 +113,19 @@ sub disk_usage {
              sub {
            $File::Find::prune++ if $CPAN::Signal;
            return if -l $_;
-           if ($^O eq 'MacOS') {
-             require Mac::Files;
-             my $cat  = Mac::Files::FSpGetCatInfo($_);
-             $Du += $cat->ioFlLgLen() + $cat->ioFlRLgLen() if $cat;
-           } else {
-             if (-d _) {
-               unless (-x _) {
-                 unless (chmod 0755, $_) {
-                   $CPAN::Frontend->mywarn("I have neither the -x permission nor ".
-                                           "the permission to change the permission; ".
-                                           "can only partially estimate disk usage ".
-                                           "of '$_'\n");
-                   $CPAN::Frontend->mysleep(5);
-                   return;
-                 }
+           if (-d _) {
+             unless (-x _) {
+               unless (chmod 0755, $_) {
+                 $CPAN::Frontend->mywarn("I have neither the -x permission nor ".
+                                         "the permission to change the permission; ".
+                                         "can only partially estimate disk usage ".
+                                         "of '$_'\n");
+                 $CPAN::Frontend->mysleep(5);
+                 return;
                }
-             } else {
-               $Du += (-s _);
              }
+           } else {
+             $Du += (-s _);
            }
          },
          $dir
diff --git a/cpan/CPAN/lib/CPAN/Debug.pm b/cpan/CPAN/lib/CPAN/Debug.pm
index 48e394bd41..68404a84fa 100644
--- a/cpan/CPAN/lib/CPAN/Debug.pm
+++ b/cpan/CPAN/lib/CPAN/Debug.pm
@@ -3,7 +3,7 @@ package CPAN::Debug;
 use strict;
 use vars qw($VERSION);

-$VERSION = "5.5001";
+$VERSION = "5.5002";
 # module is internal to CPAN.pm

 %CPAN::DEBUG = qw[
@@ -54,6 +54,7 @@ sub debug {
             if ($@) {
                 $CPAN::Frontend->myprint("Debug(\n" . $arg->as_string . ")\n");
             } else {
+                local $Data::Dumper::Sortkeys = 1;
                 $CPAN::Frontend->myprint("Debug(\n" . Data::Dumper::Dumper($arg) . ")\n");
             }
         } else {
diff --git a/cpan/CPAN/lib/CPAN/Distribution.pm b/cpan/CPAN/lib/CPAN/Distribution.pm
index 6ce0572ef7..660e45198a 100644
--- a/cpan/CPAN/lib/CPAN/Distribution.pm
+++ b/cpan/CPAN/lib/CPAN/Distribution.pm
@@ -9,7 +9,7 @@ use File::Path ();
 use POSIX ":sys_wait_h";
 @CPAN::Distribution::ISA = qw(CPAN::InfoObj);
 use vars qw($VERSION);
-$VERSION = "2.34";
+$VERSION = "2.39";

 my $run_allow_installing_within_test = 1; # boolean; either in test or in install, there is no third option

@@ -1293,11 +1293,6 @@ sub new {
 sub look {
     my($self) = @_;

-    if ($^O eq 'MacOS') {
-      $self->Mac::BuildTools::look;
-      return;
-    }
-
     if (  $CPAN::Config->{'shell'} ) {
         $CPAN::Frontend->myprint(qq{
 Trying to open a subshell in the build directory...
@@ -1404,11 +1399,6 @@ sub readme {
                                       $local_wanted)
         or $CPAN::Frontend->mydie(qq{No $sans.readme found});

-    if ($^O eq 'MacOS') {
-        Mac::BuildTools::launch_file($local_file);
-        return;
-    }
-
     my $fh_pager = FileHandle->new;
     local($SIG{PIPE}) = "IGNORE";
     my $pager = $CPAN::Config->{'pager'} || "cat";
@@ -2257,12 +2247,6 @@ is part of the perl-%s distribution. To install that, you need to run
         return;
     }

-    if ($^O eq 'MacOS') {
-        Mac::BuildTools::make($self);
-        $self->post_make();
-        return;
-    }
-
     my %env;
     while (my($k,$v) = each %ENV) {
         next if defined $v;
@@ -2647,9 +2631,13 @@ sub prefs {
             my $filler2 = int(66 - length($bs))/2;
             $filler2 = 0 if $filler2 < 0;
             $filler2 = " " x $filler2;
+            my $pretty = $self->pretty_id;
+            my $filler3 = int(66 - length($pretty))/2;
+            $filler3 = " " x $filler3;
             $CPAN::Frontend->myprint("
 $filler1 D i s t r o P r e f s $filler1
 $filler2 $bs $filler2
+$filler3 $pretty $filler3
 ");
             $CPAN::Frontend->mysleep(1);
             return $self->{prefs};
@@ -3230,9 +3218,9 @@ sub unsat_prereq {
         }
         # here need to flag as optional for recommends/suggests
         # -- xdg, 2012-04-01
-        $self->debug(sprintf "%s manadory?[%s]",
+        $self->debug(sprintf "%s mandatory?[%s]",
                      $self->pretty_id,
-                     $self->{mandatory})
+                     defined($self->{mandatory}) ? $self->{mandatory} : "<undef>")
             if $CPAN::DEBUG;
         my $optional = !$self->{mandatory}
             || $self->is_locally_optional($prereq_pm, $need_module);
@@ -3375,6 +3363,9 @@ sub prereq_pm {
     unless ($self->{build_dir}) {
         return;
     }
+    if ($self->{cleanup_after_install_done}) {
+        return;
+    }
     # no Makefile/Build means configuration aborted, so don't look for prereqs
     my $makefile  = File::Spec->catfile($self->{build_dir}, $^O eq 'VMS' ? 'descrip.mms' : 'Makefile');
     my $buildfile = File::Spec->catfile($self->{build_dir}, $^O eq 'VMS' ? 'Build.com' : 'Build');
@@ -3730,12 +3721,6 @@ sub test {
     $self->debug("Changed directory to $self->{build_dir}")
         if $CPAN::DEBUG;

-    if ($^O eq 'MacOS') {
-        Mac::BuildTools::make_test($self);
-        $self->post_test();
-        return;
-    }
-
     if ($self->{modulebuild}) {
         my $thm = CPAN::Shell->expand("Module","Test::Harness");
         my $v = $thm->inst_version;
@@ -3994,11 +3979,6 @@ sub clean {
         Carp::confess("Couldn't chdir to $self->{build_dir}: $!");
     $self->debug("Changed directory to $self->{build_dir}") if $CPAN::DEBUG;

-    if ($^O eq 'MacOS') {
-        Mac::BuildTools::make_clean($self);
-        return;
-    }
-
     my $system;
     if ($self->{modulebuild}) {
         unless (-f "Build") {
@@ -4195,12 +4175,6 @@ sub install {
     my $make = $self->{modulebuild} ? "Build" : "make";
     $CPAN::Frontend->myprint(sprintf "Running %s install for %s\n", $make, $self->pretty_id);

-    if ($^O eq 'MacOS') {
-        Mac::BuildTools::make_install($self);
-        $self->post_install();
-        return;
-    }
-
     my $system;
     if (my $commandline = $self->prefs->{install}{commandline}) {
         $system = $commandline;
diff --git a/cpan/CPAN/lib/CPAN/FTP.pm b/cpan/CPAN/lib/CPAN/FTP.pm
index 652f5be774..a19aa1ba81 100644
--- a/cpan/CPAN/lib/CPAN/FTP.pm
+++ b/cpan/CPAN/lib/CPAN/FTP.pm
@@ -15,7 +15,7 @@ use vars qw($connect_to_internet_ok $Ua $Thesite $ThesiteURL $Themethod);
 use vars qw(
             $VERSION
 );
-$VERSION = "5.5016";
+$VERSION = "5.5018";

 sub _plus_append_open {
     my($fh, $file) = @_;
@@ -367,7 +367,7 @@ sub localize_2021 {
         for my $prx (qw(https_proxy no_proxy)) {
             $ENV{$prx} = $CPAN::Config->{$prx} if $CPAN::Config->{$prx};
         }
-        $base = "https://cpan.org/";
+        $base = "https://www.cpan.org/";
     } else {
         my @missing_modules = grep { ! $CPAN::META->has_usable($_) } qw(HTTP::Tiny Net::SSLeay IO::Socket::SSL);
         my $miss = join ", ", map { "'$_'" } @missing_modules;
@@ -503,29 +503,6 @@ to get
 #-> sub CPAN::FTP::localize ;
 sub localize_1995ff {
     my($self,$file,$aslocal,$force,$with_defaults) = @_;
-    if ($^O eq 'MacOS') {
-        # Comment by AK on 2000-09-03: Uniq short filenames would be
-        # available in CHECKSUMS file
-        my($name, $path) = File::Basename::fileparse($aslocal, '');
-        if (length($name) > 31) {
-            $name =~ s/(
-                        \.(
-                           readme(\.(gz|Z))? |
-                           (tar\.)?(gz|Z) |
-                           tgz |
-                           zip |
-                           pm\.(gz|Z)
-                          )
-                       )$//x;
-            my $suf = $1;
-            my $size = 31 - length($suf);
-            while (length($name) > $size) {
-                chop $name;
-            }
-            $name .= $suf;
-            $aslocal = File::Spec->catfile($path, $name);
-        }
-    }

     return $aslocal if $self->have_promising_aslocal($aslocal, $force);
     my($maybe_restore) = 0;
@@ -599,7 +576,6 @@ sub localize_1995ff {
     } else {
         @levels = @all_levels;
     }
-    @levels = qw/dleasy/ if $^O eq 'MacOS';
     my($levelno);
     local $ENV{FTP_PASSIVE} =
         exists $CPAN::Config->{ftp_passive} ?
diff --git a/cpan/CPAN/lib/CPAN/FirstTime.pm b/cpan/CPAN/lib/CPAN/FirstTime.pm
index 8934f4a2c3..023e48b9b2 100644
--- a/cpan/CPAN/lib/CPAN/FirstTime.pm
+++ b/cpan/CPAN/lib/CPAN/FirstTime.pm
@@ -11,7 +11,7 @@ use File::Spec ();
 use CPAN::Mirrors ();
 use CPAN::Version ();
 use vars qw($VERSION $auto_config);
-$VERSION = "5.5317";
+$VERSION = "5.5319";

 =head1 NAME

@@ -454,8 +454,8 @@ Policy on building prerequisites (follow, ask or ignore)?
 =item pushy_https

 Boolean. Defaults to true. If this option is true, the cpan shell will
-use https://cpan.org/ to download stuff from the CPAN. It will fall
-back to http://cpan.org/ if it can't handle https for some reason
+use https://www.cpan.org/ to download stuff from the CPAN. It will fall
+back to http://www.cpan.org/ if it can't handle https for some reason
 (missing modules, missing programs). Whenever it falls back to the
 http protocol, it will issue a warning.

@@ -1037,7 +1037,7 @@ sub init {
     {
         my $path = $CPAN::Config->{'pager'} ||
             $ENV{PAGER} || find_exe("less",\@path) ||
-                find_exe("more",\@path) || ($^O eq 'MacOS' ? $ENV{EDITOR} : 0 )
+                find_exe("more",\@path) || 0
                     || "more";
         my_dflt_prompt(pager => $path, $matcher);
     }
@@ -1051,12 +1051,8 @@ sub init {
         }
         $path ||= $ENV{SHELL};
         $path ||= $ENV{COMSPEC} if $^O eq "MSWin32";
-        if ($^O eq 'MacOS') {
-            $CPAN::Config->{'shell'} = 'not_here';
-        } else {
-            $path ||= 'sh', $path =~ s,\\,/,g if $^O eq 'os2'; # Cosmetic only
-            my_dflt_prompt(shell => $path, $matcher);
-        }
+        $path ||= 'sh', $path =~ s,\\,/,g if $^O eq 'os2'; # Cosmetic only
+        my_dflt_prompt(shell => $path, $matcher);
     }

     {
@@ -1360,7 +1356,7 @@ sub init {
         }
         else {
             # Hint: as of 2021-11: to get http, use http://www.cpan.org/
-            $CPAN::Config->{urllist} = [ 'https://cpan.org/' ];
+            $CPAN::Config->{urllist} = [ 'https://www.cpan.org/' ];
             $CPAN::Frontend->myprint(
                 "We initialized your 'urllist' to @{$CPAN::Config->{urllist}}. Type 'o conf init urllist' to change it.\n"
             );
@@ -1568,15 +1564,10 @@ sub _init_external_progs {

     if (!$matcher or "@external_progs" =~ /$matcher/) {
         my $old_warn = $^W;
-        local $^W if $^O eq 'MacOS';
         local $^W = $old_warn;
         my $progname;
         for $progname (@external_progs) {
             next if $matcher && $progname !~ /$matcher/;
-            if ($^O eq 'MacOS') {
-                $CPAN::Config->{$progname} = 'not_here';
-                next;
-            }

             my $progcall = $progname;
             unless ($matcher) {
diff --git a/cpan/CPAN/lib/CPAN/Tarzip.pm b/cpan/CPAN/lib/CPAN/Tarzip.pm
index 6517cb8fd7..244fbbcd88 100644
--- a/cpan/CPAN/lib/CPAN/Tarzip.pm
+++ b/cpan/CPAN/lib/CPAN/Tarzip.pm
@@ -4,7 +4,7 @@ use strict;
 use vars qw($VERSION @ISA $BUGHUNTING);
 use CPAN::Debug;
 use File::Basename qw(basename);
-$VERSION = "5.5013";
+$VERSION = "5.5014";
 # module is internal to CPAN.pm

 @ISA = qw(CPAN::Debug); ## no critic
@@ -414,9 +414,6 @@ Can't continue cutting file '$file'.
                 $CPAN::Frontend->mydie("Could not untar with Archive::Tar.");
         }

-        Mac::BuildTools::convert_files([$tar->list_files], 1)
-            if ($^O eq 'MacOS');
-
         return 1;
     }
 }