develooper Front page | perl.perl5.porters | Postings from July 2001

blead kit timestamps && the problem with running perl

Thread Next
Peter Prymmer
July 10, 2001 19:32
blead kit timestamps && the problem with running perl
Message ID:

On DYNIX/ptx I had a perl 5.003_05 in my $PATH that repeatedly choked on
trying to run the command:


for each and every file that was compiled during the initial `make`.

On that platform (and Tru64 unix, and OS/390) the relevant portion of the
extracted Makefile looked like so:

proto.h embed.h embedvar.h global.sym objXSUB.h perlapi.h perlapi.c pod/perlintern.pod pod/perlapi.pod: $(OPCODE_PL_OUTPUT)

where the MACRO is given by:

OPCODE_PL_OUTPUT = opcode.h opnames.h pp_proto.h pp.sym

it is intersting to note the time stamps obtained by running various
system supplied tar utilities:

% pwd
% cat
echo targets:
ls -ltr embed.h embedvar.h global.sym objXSUB.h perlapi.c perlapi.h
echo dependencies:
ls -ltr opcode.h opnames.h pp_proto.h pp.sym

% sh
-rw-r--r--   1 pvhp     system     67050 Jul  9 07:49 proto.h
-rw-r--r--   1 pvhp     system      9602 Jul  9 07:49 global.sym
-rw-r--r--   1 pvhp     system    245722 Jul  9 07:49 embed.h
-rw-r--r--   1 pvhp     system     75217 Jul  9 07:49 embedvar.h
-rw-r--r--   1 pvhp     system     77105 Jul  9 07:49 objXSUB.h
-rw-r--r--   1 pvhp     system     84884 Jul  9 07:49 perlapi.c
-rw-r--r--   1 pvhp     system     32584 Jul  9 07:49 perlapi.h
-rw-r--r--   1 pvhp     system     98063 Jul  9 07:49 pod/perlapi.pod
-rw-r--r--   1 pvhp     system      4175 Jul  9 07:49 pod/perlintern.pod
-r-xr-xr-x   1 pvhp     system     77449 Jul  9 07:09
-rw-r--r--   1 pvhp     system     46047 Jul  9 08:29 opcode.h
-rw-r--r--   1 pvhp     system      9001 Jul  9 08:29 opnames.h
-rw-r--r--   1 pvhp     system     10537 Jul  9 08:29 pp_proto.h
-rw-r--r--   1 pvhp     system      5905 Jul  9 08:29 pp.sym

So of course the `perl` will run even during `sh ./makedepend`
as invoked by Configure like so:

Extracting x2p/Makefile (with variable substitutions)
Run make depend now? [y]
sh ./makedepend MAKE=make
make[1]: Entering directory `/tmp/perl_11238'
sh writemain lib/auto/DynaLoader/DynaLoader.a  > writemain.tmp
sh mv-if-diff writemain.tmp perlmain.c

Is Porting/makerel run as part of the perl\@\d{4}.tgz kit assembly?
Should it (or whatever script is run) be updated to run perl
and/or perhaps run:

	touch proto.h global.sym embed.h embedvar.h objXSUB.h perlapi.c perlapi.h pod/perlapi.pod pod/perlintern.pod

before assembling the kits?  I found that I could get a cleaner build
by running the above by hand after running:

    tar -xf perl@11238.tar
    cd perl

but before invoking `sh Configure`.  Thanks.

Peter Prymmer

P.S.  Here is an UNTESTED purely optional patch that I think backports to be almost OK under perl 5.003_05, with the exception of the
$function->(@args) construct still at line 52, (proper testing would look
at generated proto.h, et alia but I have run out of time for today). You
might not want to apply this since ideally the kit would not run `perl` after untarring hence running under older versions of perl
ought to be allowed to fail:

--- perl_11238/	Mon Jul  9 07:09:49 2001
+++ perl/	Tue Jul 10 19:27:34 2001
@@ -251,7 +251,8 @@
 readvars %thread, 'thrdvar.h','T';
 readvars %globvar, 'perlvars.h','G';
-foreach my $sym (sort keys %thread) {
+my $sym;
+foreach $sym (sort keys %thread) {
   warn "$sym in intrpvar.h as well as thrdvar.h\n" if exists $intrp{$sym};
@@ -856,15 +857,15 @@
-foreach my $sym (sort keys %intrp) {
+foreach $sym (sort keys %intrp) {
     print CAPIH bincompat_var('I',$sym);
-foreach my $sym (sort keys %thread) {
+foreach $sym (sort keys %thread) {
     print CAPIH bincompat_var('T',$sym);
-foreach my $sym (sort keys %globvar) {
+foreach $sym (sort keys %globvar) {
     print CAPIH bincompat_var('G',$sym);
@@ -985,7 +986,7 @@
 	if (length $return) {
 	    $decl .= "    $rettype retval;\n";
 	    $retarg .= "retval = ";
-	    $return = "\n    ${return}retval;\n";
+	    $return = "\n    " . $return . "retval;\n";
 	$emitval .= <<EOT
@@ -1011,7 +1012,6 @@
 # XXXX temporary hack
-my $sym;
 for $sym (qw(
End of tweak.

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About