In S_incpush, omit subdirs when PERL_IS_MINIPERL.
authorCraig A. Berry <craigberry@mac.com>
Fri, 4 Mar 2011 22:35:16 +0000 (16:35 -0600)
committerCraig A. Berry <craigberry@mac.com>
Fri, 4 Mar 2011 22:35:16 +0000 (16:35 -0600)
The new logic in S_parse_body that loads lib/buildcustomize.pl in
miniperl relies on lib being in $INC[0], which it won't be if we've
loaded version- and architecture-specific directories before lib.

Since miniperl isn't installed and can't do dynamic loading, it
doesn't really need those subdirectories, so skip loading them
for miniperl.

perl.c

diff --git a/perl.c b/perl.c
index 6bb9f46..491c036 100644 (file)
--- a/perl.c
+++ b/perl.c
@@ -4384,8 +4384,12 @@ S_incpush(pTHX_ const char *const dir, STRLEN len, U32 flags)
 {
     dVAR;
     const U8 using_sub_dirs
+#ifdef PERL_IS_MINIPERL
+        = 0;
+#else
        = (U8)flags & (INCPUSH_ADD_VERSIONED_SUB_DIRS
                       |INCPUSH_ADD_ARCHONLY_SUB_DIRS|INCPUSH_ADD_OLD_VERS);
+#endif
     const U8 add_versioned_sub_dirs
        = (U8)flags & INCPUSH_ADD_VERSIONED_SUB_DIRS;
     const U8 add_archonly_sub_dirs