Add cygperl*.dll to packlist
authorJerry D. Hedden <jdhedden@cpan.org>
Mon, 25 Aug 2008 10:47:24 +0000 (06:47 -0400)
committerH.Merijn Brand <h.m.brand@xs4all.nl>
Mon, 25 Aug 2008 15:56:16 +0000 (15:56 +0000)
From: "Jerry D. Hedden" <jdhedden@cpan.org>
Message-ID: <1ff86f510808250747s1e0c42demb2d4ac8dc5d33925@mail.gmail.com>

p4raw-id: //depot/perl@34226

installperl

index b014f80..e496b06 100755 (executable)
@@ -365,12 +365,24 @@ if ($Is_VMS) {  # We did core file selection during build
     map { s|^$coredir/||i; } @corefiles = <$coredir/*.*>;
 }
 elsif ($Is_Cygwin) { # On Cygwin symlink it to CORE to make Makefile happy
+    @corefiles = <*.h libperl*.* perl*$Config{lib_ext}>;
     my $coredll = "$installarchlib/CORE/$libperl";
+    safe_unlink($coredll);
     ( $Config{'d_link'} eq 'define' &&
-      eval { CORE::link "$installbin/$libperl", $coredll } ) ||
-    eval { symlink "$installbin/$libperl", $coredll }  ||
-    copy("$installbin/$libperl", $coredll);
-    @corefiles = <*.h libperl*.* perl*$Config{lib_ext}>;
+      eval {
+          CORE::link("$installbin/$libperl", $coredll);
+          $packlist->{$coredll} = { from => "$installbin/$libperl",
+                                    type => 'link' };
+      }
+    ) ||
+    eval {
+        symlink("$installbin/$libperl", $coredll);
+        $packlist->{$coredll} = { from => "$installbin/$libperl",
+                                  type => 'link' };
+    } ||
+    ( copy("$installbin/$libperl", $coredll) &&
+      push(@corefiles, $coredll)
+    )
 } else {
     # [als] hard-coded 'libperl' name... not good!
     @corefiles = <*.h libperl*.* perl*$Config{lib_ext}>;