Change 20303 by [EMAIL PROTECTED] on 2003/07/29 11:33:37

        Integrate:
        [ 20297]
        Green light from Stas.
        
        [ 20298]
        DEC OSF/1 3.x did (does) not do sizer -v.
        
        [ 20299]
        README.hpux now mentions the http mirror for prebuilt gcc binaries
        
        [ 20300]
        Cleanup the sv_gets() logic for platforms with small stacks.
        (I think hogging 8K of stack sounds like bad behaviour on any
        platform, big stack or not.)
        
        [ 20301]
        Subject: [perl #23134] Problems compiling 5.8.0 on alpha-dec_osf 3.2
        From: Chaskiel M Grundman (via RT) <[EMAIL PROTECTED]>
        Date: 26 Jul 2003 21:44:06 -0000
        Message-ID: <[EMAIL PROTECTED]>
        
        Helps (the admittedly old) DEC OSF/1 3.x and harms not newer
        releases 4.x and 5.x.
        
        [ 20302]
        Subject: DESTDIR in perl-5.8.1 package?
        From: Michael Schroeder <[EMAIL PROTECTED]>
        Date: Fri, 11 Jul 2003 14:48:41 +0200
        Message-ID: <[EMAIL PROTECTED]>
        
        Subject: Re: DESTDIR in perl-5.8.1 package?
        From: Michael Schroeder <[EMAIL PROTECTED]>
        Date: Mon, 14 Jul 2003 12:00:25 +0200
        Message-ID: <[EMAIL PROTECTED]>
        
        (blindly prepending and s///ing away the $destdir does not work
         at least in VMS, but the --destdir should help rpm builders
         and the like)

Affected files ...

... //depot/maint-5.8/perl/INSTALL#17 integrate
... //depot/maint-5.8/perl/Makefile.SH#22 integrate
... //depot/maint-5.8/perl/README.hpux#5 integrate
... //depot/maint-5.8/perl/hints/dec_osf.sh#8 integrate
... //depot/maint-5.8/perl/installman#2 integrate
... //depot/maint-5.8/perl/installperl#11 integrate
... //depot/maint-5.8/perl/perl.h#43 integrate
... //depot/maint-5.8/perl/sv.c#62 integrate

Differences ...

==== //depot/maint-5.8/perl/INSTALL#17 (text) ====
Index: perl/INSTALL
--- perl/INSTALL#16~20254~      Mon Jul 28 02:48:25 2003
+++ perl/INSTALL        Tue Jul 29 04:33:37 2003
@@ -650,6 +650,17 @@
     cd /opt/perl # Or wherever you specified as $prefix
     tar xvf perl5-archive.tar
 
+Alternatively, perl honors the DESTDIR variable in the make install
+call. DESTDIR is automatically prepended to all the installation paths.
+With DESTDIR, the above example can we written as:
+
+    sh Configure -Dprefix=/opt/perl -des
+    make
+    make test
+    make install DESTDIR=/tmp/perl5
+    cd /tmp/perl5/opt/perl
+    tar cvf /tmp/perl5-archive.tar .
+
 =head2 Site-wide Policy settings
 
 After Configure runs, it stores a number of common site-wide "policy"

==== //depot/maint-5.8/perl/Makefile.SH#22 (text) ====
Index: perl/Makefile.SH
--- perl/Makefile.SH#21~20271~  Mon Jul 28 08:18:57 2003
+++ perl/Makefile.SH    Tue Jul 29 04:33:37 2003
@@ -788,11 +788,11 @@
                cd ../pod; $(MAKE) compile; \
        else :; \
        fi
-       $(LDLIBPTH) ./perl installperl $(INSTALLFLAGS) $(STRIPFLAGS)
+       $(LDLIBPTH) ./perl installperl --destdir=$(DESTDIR) $(INSTALLFLAGS) 
$(STRIPFLAGS)
        $(MAKE) extras.install
 
 install.man:   all installman
-       $(LDLIBPTH) ./perl installman $(INSTALLFLAGS)
+       $(LDLIBPTH) ./perl installman --destdir=$(DESTDIR) $(INSTALLFLAGS)
 
 # XXX Experimental. Hardwired values, but useful for testing.
 # Eventually Configure could ask for some of these values.

==== //depot/maint-5.8/perl/README.hpux#5 (text) ====
Index: perl/README.hpux
--- perl/README.hpux#4~19704~   Fri Jun  6 22:24:27 2003
+++ perl/README.hpux    Tue Jul 29 04:33:37 2003
@@ -301,8 +301,9 @@
 are often multiple versions of the same package available).
 
 Above mentioned distributions are depots. H.Merijn Brand has made prebuilt
-gcc binaries available on https://www.beepz.com/personal/merijn/ for
-HP-UX 10.20 and HP-UX 11.00 in both 32- and 64-bit versions. These are
+gcc binaries available on https://www.beepz.com/personal/merijn/ and/or
+http://www.cmve.net/~merijn/ for HP-UX 10.20 and HP-UX 11.00 in both 32-
+and 64-bit versions. Most likely 11i will be available soon. These are
 bzipped tar archives that also include recent GNU binutils and GNU gdb.
 Read the instructions on that page to rebuild gcc using itself.
 

==== //depot/maint-5.8/perl/hints/dec_osf.sh#8 (text) ====
Index: perl/hints/dec_osf.sh
--- perl/hints/dec_osf.sh#7~19891~      Mon Jun 30 02:39:29 2003
+++ perl/hints/dec_osf.sh       Tue Jul 29 04:33:37 2003
@@ -225,6 +225,9 @@
 # the basic lddlflags used always
 lddlflags='-shared -expect_unresolved "*"'
 
+# Intentional leading tab.
+       myosvers="`/usr/sbin/sizer -v 2>/dev/null || head -1 /etc/motd`"
+
 # Fancy compiler suites use optimising linker as well as compiler.
 # <[EMAIL PROTECTED]>
 case "`uname -r`" in
@@ -234,7 +237,7 @@
 *)            if $test "X$optimize" = "X$undef"; then
                       lddlflags="$lddlflags -msym"
               else
-                 case "`/usr/sbin/sizer -v`" in
+                 case "$myosvers" in
                  *4.0D*)
                      # QAR 56761: -O4 + .so may produce broken code,
                      # fixed in 4.0E or better.
@@ -286,7 +289,7 @@
 # emulate_eaccess().
 
 # Fixed in V5.0A.
-case "`/usr/sbin/sizer -v`" in
+case "$myosvers" in
 *5.0[A-Z]*|*5.[1-9]*|*[6-9].[0-9]*)
        : ok
        ;;
@@ -360,7 +363,7 @@
 # after it has prompted the user for whether to use long doubles.
 case "$uselongdouble" in
 $define|true|[yY]*)
-       case "`/usr/sbin/sizer -v`" in
+       case "$myosvers" in
        *[1-4].0*)      cat >&4 <<EOF
 
 ***
@@ -412,7 +415,7 @@
 esac
 EOCBU
 
-case "`/usr/sbin/sizer -v`" in
+case "$myosvers" in
 *[1-4].0*) d_modfl=undef ;; # must wait till 5.0
 esac
 

==== //depot/maint-5.8/perl/installman#2 (xtext) ====
Index: perl/installman
--- perl/installman#1~17645~    Fri Jul 19 12:29:57 2002
+++ perl/installman     Tue Jul 29 04:33:37 2003
@@ -41,15 +41,15 @@
 my %opts;
 GetOptions( \%opts,
             qw( man1dir=s man1ext=s man3dir=s man3ext=s batchlimit=i
-                notify n help silent S verbose V)) 
+                destdir=s notify n help silent S verbose V)) 
        || die $usage;
 die $usage if $opts{help};
 
-$opts{man1dir} = $Config{'installman1dir'}
+$opts{man1dir} = "$opts{destdir}$Config{'installman1dir'}"
     unless defined($opts{man1dir}); 
 $opts{man1ext} = $Config{'man1ext'}
     unless defined($opts{man1ext}); 
-$opts{man3dir} = $Config{'installman3dir'}
+$opts{man3dir} = "$opts{destdir}$Config{'installman3dir'}"
     unless defined($opts{man3dir}); 
 $opts{man3ext} = $Config{'man3ext'}
     unless defined($opts{man3ext}); 
@@ -61,13 +61,13 @@
 
 -x  "./perl$Config{exe_ext}" 
   or warn "./perl$Config{exe_ext} not found!  Have you run make?\n";
--d  $Config{'installprivlib'}
+-d  "$opts{destdir}$Config{'installprivlib'}"
        || warn "Perl library directory $Config{'installprivlib'} not found.
                Have you run make install?.  (Installing anyway.)\n";
 -x "t/perl$Config{exe_ext}"            || warn "WARNING: You've never run 'make 
test'!!!",
        "  (Installing anyway.)\n";
 
-$packlist = ExtUtils::Packlist->new("$Config{installarchlib}/.packlist");
+$packlist = 
ExtUtils::Packlist->new("$opts{destdir}/$Config{installarchlib}/.packlist");
 
 
 # Install the main pod pages.
@@ -163,11 +163,13 @@
     foreach my $page (@to_process) {
        my($pod, $tmp, $manpage) = @$page;
 
-        print "  $manpage\n";
+       my $xmanpage = $manpage;
+       $xmanpage =~ s/^\Q$opts{'destdir'}\E// if $opts{'destdir'};
+        print "  $xmanpage\n";
        if (!$opts{notify} && $parser->parse_from_file($pod, $tmp)) {
             if (-s $tmp) {
                 if (rename($tmp, $manpage)) {
-                    $packlist->{$manpage} = { type => 'file' };
+                    $packlist->{$xmanpage} = { type => 'file' };
                     next;
                 }
             }

==== //depot/maint-5.8/perl/installperl#11 (xtext) ====
Index: perl/installperl
--- perl/installperl#10~20241~  Sun Jul 27 13:07:20 2003
+++ perl/installperl    Tue Jul 29 04:33:37 2003
@@ -62,6 +62,7 @@
                    : $perl;
 
 $otherperls = 1;
+my $destdir = '';
 while (@ARGV) {
     $nonono = 1 if $ARGV[0] eq '-n';
     $dostrip = 1 if $ARGV[0] eq '-s';
@@ -74,6 +75,7 @@
     $archname = 1 if $ARGV[0] eq '-A';
     $nwinstall = 1 if $ARGV[0] eq '-netware';
     $nopods = 1 if $ARGV[0] eq '-p';
+    $destdir = $1 if $ARGV[0] =~ /^-?-destdir=(.*)$/;
     if ($ARGV[0] eq '-?' or $ARGV[0] =~ /^-?-h/) {
        print <<"EOT";
 Usage $0: [switches]
@@ -170,13 +172,13 @@
        if $patchlevel != $Config{'PERL_VERSION'};
 
 # Fetch some frequently-used items from %Config
-my $installbin = $Config{installbin};
-my $installscript = $Config{installscript};
-my $installprivlib = $Config{installprivlib};
-my $installarchlib = $Config{installarchlib};
-my $installsitelib = $Config{installsitelib};
-my $installsitearch = $Config{installsitearch};
-my $installman1dir = $Config{installman1dir};
+my $installbin = "$destdir$Config{installbin}";
+my $installscript = "$destdir$Config{installscript}";
+my $installprivlib = "$destdir$Config{installprivlib}";
+my $installarchlib = "$destdir$Config{installarchlib}";
+my $installsitelib = "$destdir$Config{installsitelib}";
+my $installsitearch = "$destdir$Config{installsitearch}";
+my $installman1dir = "$destdir$Config{installman1dir}";
 my $man1ext = $Config{man1ext};
 my $libperl = $Config{libperl};
 # Shared library and dynamic loading suffixes.
@@ -691,7 +693,11 @@
     my($from,$to) = @_;
     my($success) = 0;
 
-    print $verbose ? "  ln $from $to\n" : "  $to\n" unless $silent;
+    my $xfrom = $from;
+    $xfrom =~ s/^\Q$destdir\E// if $destdir;
+    my $xto = $to;
+    $xto =~ s/^\Q$destdir\E// if $destdir;
+    print $verbose ? "  ln $xfrom $xto\n" : "  $xto\n" unless $silent;
     eval {
        CORE::link($from, $to)
            ? $success++
@@ -699,18 +705,18 @@
              ? die "AFS"  # okay inside eval {}
              : die "Couldn't link $from to $to: $!\n"
          unless $nonono;
-       $packlist->{$to} = { from => $from, type => 'link' };
+       $packlist->{$xto} = { from => $xfrom, type => 'link' };
     };
     if ($@) {
        warn $@;
-       print $verbose ? "  cp $from $to\n" : "  $to\n" unless $silent;
-       print "  creating new version of $to\n"
+       print $verbose ? "  cp $from $xto\n" : "  $xto\n" unless $silent;
+       print "  creating new version of $xto\n"
                 if $Is_VMS and -e $to and !$silent;
        File::Copy::copy($from, $to)
            ? $success++
            : warn "Couldn't copy $from to $to: $!\n"
          unless $nonono;
-       $packlist->{$to} = { type => 'file' };
+       $packlist->{$xto} = { type => 'file' };
     }
     $success;
 }
@@ -728,12 +734,14 @@
 sub copy {
     my($from,$to) = @_;
 
-    print $verbose ? "  cp $from $to\n" : "  $to\n" unless $silent;
-    print "  creating new version of $to\n" if $Is_VMS and -e $to and !$silent;
+    my $xto = $to;
+    $xto =~ s/^\Q$destdir\E// if $destdir;
+    print $verbose ? "  cp $from $xto\n" : "  $xto\n" unless $silent;
+    print "  creating new version of $xto\n" if $Is_VMS and -e $to and !$silent;
     File::Copy::copy($from, $to)
        || warn "Couldn't copy $from to $to: $!\n"
       unless $nonono;
-    $packlist->{$to} = { type => 'file' };
+    $packlist->{$xto} = { type => 'file' };
 }
 
 sub samepath {
@@ -796,7 +804,9 @@
            #This might not work because $archname might have changed.
            unlink("$installarchlib/$name");
        }
-       $packlist->{"$installlib/$name"} = { type => 'file' };
+       my $xname = "$installlib/$name";
+       $xname =~ s/^\Q$destdir\E// if $destdir;
+       $packlist->{$xname} = { type => 'file' };
        if ($force || compare($_, "$installlib/$name") || $nonono) {
            unlink("$installlib/$name");
            mkpath("$installlib/$dir", $verbose, 0777);
@@ -841,6 +851,8 @@
 sub copy_if_diff {
     my($from,$to)[EMAIL PROTECTED];
     return 1 if (($^O eq 'VMS') && (-d $from));
+    my $xto = $to;
+    $xto =~ s/^\Q$destdir\E// if $destdir;
     my $perlpodbadsymlink;
     if ($from =~ m!^pod/perl[\w-]+\.pod$! &&
        -l $from &&
@@ -853,7 +865,7 @@
        $perlpodbadsymlink = 1;
     }
     -f $from || $perlpodbadsymlink || warn "$0: $from not found";
-    $packlist->{$to} = { type => 'file' };
+    $packlist->{$xto} = { type => 'file' };
     if ($force || compare($from, $to) || $nonono) {
        safe_unlink($to);   # In case we don't have write permissions.
        if ($nonono) {

==== //depot/maint-5.8/perl/perl.h#43 (text) ====
Index: perl/perl.h
--- perl/perl.h#42~20254~       Mon Jul 28 02:48:25 2003
+++ perl/perl.h Tue Jul 29 04:33:37 2003
@@ -691,11 +691,6 @@
 #  define WIN32SCK_IS_STDSCK           /* don't pull in custom wsock layer */
 #endif
 
-/* In Tru64 use the 4.4BSD struct msghdr, not the 4.3 one */
-#if defined(__osf__) && defined(__alpha) && !defined(_SOCKADDR_LEN)
-#  define _SOCKADDR_LEN
-#endif
-
 #if defined(HAS_SOCKET) && !defined(VMS) && !defined(WIN32) /* VMS/WIN32 handle 
sockets via vmsish.h/win32.h */
 # include <sys/socket.h>
 # if defined(USE_SOCKS) && defined(I_SOCKS)

==== //depot/maint-5.8/perl/sv.c#62 (text) ====
Index: perl/sv.c
--- perl/sv.c#61~20271~ Mon Jul 28 08:18:57 2003
+++ perl/sv.c   Tue Jul 29 04:33:37 2003
@@ -6334,15 +6334,23 @@
     }
    else
     {
-#ifndef EPOC
-       /*The big, slow, and stupid way */
-       STDCHAR buf[8192];
+       /*The big, slow, and stupid way. */
+
+      /* Any stack-challenged places. */
+#if defined(EPOC) || 1
+      /* EPOC: need to work around SDK features.         *
+       * On WINS: MS VC5 generates calls to _chkstk,     *
+       * if a "large" stack frame is allocated.          *
+       * gcc on MARM does not generate calls like these. */
+#   define USEHEAPINSTEADOFSTACK
+#endif
+
+#ifdef USEHEAPINSTEADOFSTACK
+       STDCHAR *buf = 0;
+       New(0, buf, 8192, STDCHAR);
+       assert(buf);
 #else
-       /* Need to work around EPOC SDK features          */
-       /* On WINS: MS VC5 generates calls to _chkstk,    */
-       /* if a `large' stack frame is allocated          */
-       /* gcc on MARM does not generate calls like these */
-       STDCHAR buf[1024];
+       STDCHAR buf[8192];
 #endif
 
 screamer2:
@@ -6391,6 +6399,10 @@
            if (!(cnt < sizeof(buf) && PerlIO_eof(fp)))
                goto screamer2;
        }
+
+#ifdef USEHEAPINSTEADOFSTACK
+       Safefree(buf);
+#endif
     }
 
     if (rspara) {              /* have to do this both before and after */
End of Patch.

Reply via email to