+# Make links to ordinary names if installbin directory isn't current directory.
+
+if (!$versiononly && ! samepath($installbin, 'x2p')) {
+ safe_unlink("$installbin/a2p$exe_ext");
+ copy("x2p/a2p$exe_ext", "$installbin/a2p$exe_ext");
+ chmod(0755, "$installbin/a2p$exe_ext");
+}
+
+# cppstdin is just a script, but it is architecture-dependent, so
+# it can't safely be shared. Place it in $installbin.
+# Note that Configure doesn't build cppstin if it isn't needed, so
+# we skip this if cppstdin doesn't exist.
+if (! $versiononly && (-f 'cppstdin') && (! samepath($installbin, '.'))) {
+ safe_unlink("$installbin/cppstdin");
+ copy("cppstdin", "$installbin/cppstdin");
+ chmod(0755, "$installbin/cppstdin");
+}
+
+# Install scripts.
+
+mkpath($installscript, 1, 0777);
+
+if (! $versiononly) {
+ for (@scripts) {
+ (my $base = $_) =~ s#.*/##;
+ copy($_, "$installscript/$base");
+ chmod(0755, "$installscript/$base");
+ }
+}
+
+# pstruct should be a link to c2ph
+
+if (! $versiononly) {
+ safe_unlink("$installscript/pstruct$scr_ext");
+ if ($^O eq 'dos' or $Is_VMS) {
+ copy("$installscript/c2ph$scr_ext", "$installscript/pstruct$scr_ext");
+ } else {
+ link("$installscript/c2ph$scr_ext", "$installscript/pstruct$scr_ext");
+ }
+}
+
+# Install pod pages. Where? I guess in $installprivlib/pod
+# ($installprivlib/pods for cygwin).
+
+my $pod = $Is_Cygwin ? 'pods' : 'pod';
+unless ( $versiononly && !($installprivlib =~ m/\Q$ver/)) {
+ mkpath("${installprivlib}/$pod", 1, 0777);
+
+ # If Perl 5.003's perldiag.pod is there, rename it.
+ if (open POD, "${installprivlib}/$pod/perldiag.pod") {
+ read POD, $_, 4000;
+ close POD;
+ # Some of Perl 5.003's diagnostic messages ended with periods.
+ if (/^=.*\.$/m) {
+ my ($from, $to) = ("${installprivlib}/$pod/perldiag.pod",
+ "${installprivlib}/$pod/perldiag-5.003.pod");
+ print " rename $from $to";
+ rename($from, $to)
+ or warn "Couldn't rename $from to $to: $!\n"
+ unless $nonono;
+ }
+ }
+
+ for (@pods) {
+ # $_ is a name like pod/perl.pod
+ (my $base = $_) =~ s#.*/##;
+ copy_if_diff($_, "${installprivlib}/$pod/${base}");
+ }
+
+}
+