From: Craig A. Berry Date: Sat, 24 Nov 2001 12:45:44 +0000 (-0600) Subject: make PPPort/harness build on VMS X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=d6ec9fa3b3319f35131489112ca8c41e368dd1c8;p=p5sagit%2Fp5-mst-13.2.git make PPPort/harness build on VMS Message-Id: <5.1.0.14.2.20011124030253.01bd4b98@exchi01> (with tweaks, and combined with Sarathy's #13242) p4raw-id: //depot/perl@13244 --- diff --git a/configure.com b/configure.com index 28ba93b..d8323ea 100644 --- a/configure.com +++ b/configure.com @@ -2498,6 +2498,7 @@ $ IF F$EXTRACT(0,4,line) .EQS. "ext/" THEN - xxx = F$EXTRACT(4,line_len - 16,line) $ IF xxx .EQS. "DynaLoader" THEN goto ext_loop ! omit $ IF xxx .EQS. "SDBM_File/sdbm" THEN goto ext_loop ! sub extension - omit +$ IF xxx .EQS. "Devel/PPPort/harness" THEN goto ext_loop ! sub extension - omit $ IF F$EXTRACT(0,8,line) .EQS. "vms/ext/" THEN - xxx = "VMS/" + F$EXTRACT(8,line_len - 20,line) $ known_extensions = known_extensions + " ''xxx'" diff --git a/ext/Devel/PPPort/harness/Makefile.PL b/ext/Devel/PPPort/harness/Makefile.PL index 13ba56d..0059272 100644 --- a/ext/Devel/PPPort/harness/Makefile.PL +++ b/ext/Devel/PPPort/harness/Makefile.PL @@ -14,17 +14,31 @@ WriteMakefile( ); -sub MY::postamble {<<'EOM'}; +sub MY::postamble { + + use File::Spec; + + my $libdir = File::Spec->catdir(File::Spec->updir(), File::Spec->updir(), + File::Spec->updir(), File::Spec->updir(), + 'lib'); + my $blibdir = File::Spec->catdir(File::Spec->curdir(), 'blib'); + my $pmfile = File::Spec->catfile(File::Spec->updir(), 'PPPort.pm'); + my $retval = <<'EOM'; sweep: $(RM_F) pm_to_blib Harness.c Harness$(OBJ_EXT) module2$(OBJ_EXT) module3$(OBJ_EXT) ppport.h - $(RM_RF) ./blib +EOM + + $retval .= "\t\$(RM_RF) $blibdir\n\n"; + $retval .= "Harness.c : ppport.h\n\n"; + $retval .= "module2.c module3.c : ppport.h\n\t\$(NOECHO) \$(NOOP)\n\n"; + $retval .= "ppport.h: $pmfile\n"; -Harness.c module2.c module3.c : ppport.h + my $Ilibdir = $^O eq 'VMS' ? qq{"-I$libdir"} : qq{-I$libdir}; -ppport.h: ../PPPort.pm - $(PERL) -I../../../../lib -e "require '../PPPort.pm'; Devel::PPPort::WriteFile('ppport.h')" - -EOM + $retval .= qq[\t\$(PERL) $Ilibdir -e "require qq{$pmfile}; Devel::PPPort::WriteFile(qq{ppport.h})"]; + + return $retval; +} sub MY::install { "install ::\n" };