In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/87e064040e3ca3b6e8dfae243dfe4af76c7eb323?hp=eb863851dc760d12b53aa443481ac97240430aa7>

- Log -----------------------------------------------------------------
commit 87e064040e3ca3b6e8dfae243dfe4af76c7eb323
Author: Nicholas Clark <[email protected]>
Date:   Tue Sep 15 14:56:44 2009 +0100

    Ensure that the perl build doesn't read any installed sitecustomize script.
    
    But not the tests yet.
    
    We need to avoid running a sitecustomize script as it may have side effects
    that cause the build to fail, or worse, complete but with buggy side 
effects.

M       Makefile.SH
M       perl.c
M       vms/descrip_mms.template
M       win32/Makefile
M       win32/makefile.mk

commit 404ad9dc9dfa2116d2907212d3650df6870ff9bc
Author: Nicholas Clark <[email protected]>
Date:   Tue Sep 15 13:56:31 2009 +0100

    Avoid setting $! if the sitecustomize script doesn't exist.

M       perl.c
-----------------------------------------------------------------------

Summary of changes:
 Makefile.SH              |    2 +-
 perl.c                   |    9 +++++++--
 vms/descrip_mms.template |    2 +-
 win32/Makefile           |    2 +-
 win32/makefile.mk        |    2 +-
 5 files changed, 11 insertions(+), 6 deletions(-)

diff --git a/Makefile.SH b/Makefile.SH
index 83f1ad1..58c4449 100644
--- a/Makefile.SH
+++ b/Makefile.SH
@@ -982,7 +982,7 @@ uni.data: miniperl$(EXE_EXT) $(CONFIGPM) 
lib/unicore/mktables $(nonxs_ext)
 # But also this ensures that all extensions are built before we try to scan
 # them, which picks up Devel::PPPort's documentation.
 pod/perltoc.pod: $(perltoc_pod_prereqs) perl$(EXE_EXT) $(ext) pod/buildtoc
-       $(LDLIBPTH) $(RUN) ./perl$(EXE_EXT) -Ilib pod/buildtoc --build-toc -q
+       $(LDLIBPTH) $(RUN) ./perl$(EXE_EXT) -f -Ilib pod/buildtoc --build-toc -q
 
 pod/perlapi.pod pod/perlintern.pod: miniperl$(EXE_EXT) autodoc.pl embed.fnc
        $(LDLIBPTH) $(RUN) ./miniperl$(EXE_EXT) -Ilib autodoc.pl
diff --git a/perl.c b/perl.c
index 7876adf..e80b9e4 100644
--- a/perl.c
+++ b/perl.c
@@ -1940,10 +1940,15 @@ S_parse_body(pTHX_ char **env, XSINIT_t xsinit)
     }
     }
 
-#ifdef USE_SITECUSTOMIZE
+#if defined(USE_SITECUSTOMIZE) && !defined(PERL_IS_MINIPERL)
     if (!minus_f) {
+       /* SITELIB_EXP is a function call on Win32.
+          The games with local $! are to avoid setting errno if there is no
+          sitecustomize script.  */
+       const char *const sitelib = SITELIB_EXP;
        (void)Perl_av_create_and_unshift_one(aTHX_ &PL_preambleav,
-                                            Perl_newSVpvf(aTHX_ "BEGIN { do 
'%s/sitecustomize.pl' }", SITELIB_EXP));
+                                            Perl_newSVpvf(aTHX_
+                                                          "BEGIN { do {local 
$!; -f '%s/sitecustomize.pl'} && do '%s/sitecustomize.pl' }", sitelib, 
sitelib));
     }
 #endif
 
diff --git a/vms/descrip_mms.template b/vms/descrip_mms.template
index 747aeac..f55ef18 100644
--- a/vms/descrip_mms.template
+++ b/vms/descrip_mms.template
@@ -448,7 +448,7 @@ pod = $(pod0) $(pod1) $(pod2) $(pod3) $(pod4) $(pod5) 
$(pod6) $(pod7) $(pod8) $(
 
 [.pod]perltoc.pod : [.pod]perldelta.pod [.pod]perlapi.pod [.pod]perlintern.pod 
 [.pod]perlmodlib.pod extra.pods $(PERL_EXE)
        @ define/user_mode $(DBG)PERLSHR SYS$DISK:[]$(DBG)perlshr$(E)
-       $(PERL) [.pod]buildtoc "-q" "--build-toc"
+       $(PERL) "-f" [.pod]buildtoc "-q" "--build-toc"
 
 archcorefiles : $(ac) $(ARCHAUTO)time.stamp
        @ $(NOOP)
diff --git a/win32/Makefile b/win32/Makefile
index 9f6fa3d..d4eb178 100644
--- a/win32/Makefile
+++ b/win32/Makefile
@@ -1145,7 +1145,7 @@ utils: $(PERLEXE) $(X2P)
        $(PERLEXE) $(ICWD) ..\pod\perlmodlib.pl -q
 
 ..\pod\perltoc.pod: $(PERLEXE) Extensions Extensions_nonxs
-       $(PERLEXE) ..\pod\buildtoc --build-toc -q
+       $(PERLEXE) -f ..\pod\buildtoc --build-toc -q
 
 # Note that the pod cleanup in this next section is parsed (and regenerated
 # by pod/buildtoc so please check that script before making changes here
diff --git a/win32/makefile.mk b/win32/makefile.mk
index e9f54ad..a4dc36a 100644
--- a/win32/makefile.mk
+++ b/win32/makefile.mk
@@ -1470,7 +1470,7 @@ utils: $(PERLEXE) $(X2P)
        $(PERLEXE) $(ICWD) ..\pod\perlmodlib.pl -q
 
 ..\pod\perltoc.pod: $(PERLEXE) Extensions Extensions_nonxs
-       $(PERLEXE) ..\pod\buildtoc --build-toc -q
+       $(PERLEXE) -f ..\pod\buildtoc --build-toc -q
 
 # Note that the pod cleanup in this next section is parsed (and regenerated
 # by pod/buildtoc so please check that script before making changes here

--
Perl5 Master Repository

Reply via email to