summaryrefslogtreecommitdiff
path: root/vms
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2013-06-12 14:42:15 +0200
committerNicholas Clark <nick@ccl4.org>2013-06-13 15:19:21 +0200
commitb78ac7159b42a0e0bd59ab07411d2f5ef09e1d7e (patch)
tree402f6c1ac5e8d7abfa1ae5a6d81f06d06506cdf9 /vms
parentf6b3c354c9a2b091250502d4d877969b8a1185a0 (diff)
downloadperl-b78ac7159b42a0e0bd59ab07411d2f5ef09e1d7e.tar.gz
write_buildcustomize.pl no longer writes to STDOUT
write_buildcustomize.pl now opens lib/buildcustomize.pl itself, instead of writing to STDOUT and relying on the Makefile to set up redirection. This means that an empty lib/buildcustomize.pl is not created if write_buildcustomize.pl fails to compile (for whatever reason), and permits write_buildcustomize.pl to delete (or attempt to delete) the output file if it detects an error. Hard code the output file name (lib/buildcustomize.pl), as it's the same on all platforms, and @ARGV is already used to optionally pass a directory for write_buildcustomize.pl to change to before running. Experimentation suggests that various make utilities don't delete a file created by redirection even if an error occurs. Hence this should be more robust. Add -f to the miniperl commandline when running write_buildcustomize.pl to avoid reading in any existing lib/buildcustomize.pl. write_buildcustomize.pl doesn't need the setup provided by lib/buildcustomize.pl, and running it might cause errors which prevents writing out a correct version, making an incomplete build harder to recover from.
Diffstat (limited to 'vms')
-rw-r--r--vms/descrip_mms.template2
1 files changed, 1 insertions, 1 deletions
diff --git a/vms/descrip_mms.template b/vms/descrip_mms.template
index 7f919719a0..7ccc84b2c8 100644
--- a/vms/descrip_mms.template
+++ b/vms/descrip_mms.template
@@ -350,7 +350,7 @@ miniperl : $(DBG)miniperl$(E) vmspipe.com
[.lib]buildcustomize.pl : miniperlmain$(O), $(DBG)libperlmini$(OLB) $(CRTL) write_buildcustomize.pl [.lib.VMS]Filespec.pm
Link $(LINKFLAGS)/NoDebug/Trace/NoMap/NoFull/NoCross/Exe=$(MINIPERL_EXE) miniperlmain$(O), $(DBG)libperlmini$(OLB)/Library/Include=globals $(CRTLOPTS)
- $(MINIPERL) write_buildcustomize.pl > [.lib]buildcustomize.pl
+ $(MINIPERL) "-f" write_buildcustomize.pl
$(DBG)miniperl$(E) : miniperlmain$(O), $(DBG)libperlmini$(OLB) $(CRTL)
Link $(LINKFLAGS)/Trace/Exe=$(MMS$TARGET) miniperlmain$(O), $(DBG)libperlmini$(OLB)/Library/Include=globals $(CRTLOPTS)