summaryrefslogtreecommitdiff
path: root/win32
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>1999-05-14 19:55:04 +0000
committerGurusamy Sarathy <gsar@cpan.org>1999-05-14 19:55:04 +0000
commitcf11f4bfc3057837b3293e13b8edc0381b78e551 (patch)
tree6506864f101c1d092024f0c2df78b318b926c33e /win32
parent349ad1feae90fecd2b4cb0dcda7c5ee192a81508 (diff)
downloadperl-cf11f4bfc3057837b3293e13b8edc0381b78e551.tar.gz
on win32, look for "site/5.XXX/lib" if "site/5.XXXYY/lib" isn't
found (brings sitelib intuition in line with privlib) p4raw-id: //depot/perl@3423
Diffstat (limited to 'win32')
-rw-r--r--win32/win32.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/win32/win32.c b/win32/win32.c
index 7dad2cfaef..858f86e6b0 100644
--- a/win32/win32.c
+++ b/win32/win32.c
@@ -245,9 +245,10 @@ get_emd_part(char **prev_path, char *trailing_path, ...)
Renew(*prev_path, newsize, char);
(*prev_path)[oldsize-1] = ';';
strcpy(&(*prev_path)[oldsize], mod_name);
+ return *prev_path;
}
- return *prev_path;
+ return Nullch;
}
char *
@@ -294,6 +295,12 @@ win32_get_sitelib(char *pl)
* ";$EMD/" . ((-d $EMD/../../../$]) ? "../../.." : "../.."). "/site/$]/lib"; */
sprintf(pathstr, "site/%s/lib", pl);
str1 = get_emd_part(path1, pathstr, ARCHNAME, "bin", pl, Nullch);
+ if (!str1 && strlen(pl) == 7) {
+ /* pl may have been SUBVERSION-specific; try again without
+ * SUBVERSION */
+ sprintf(pathstr, "site/%.5s/lib", pl);
+ str1 = get_emd_part(path1, pathstr, ARCHNAME, "bin", pl, Nullch);
+ }
/* $HKCU{'sitelib'} || $HKLM{'sitelib'} . ---; */
path2 = &SvPVX(sv2);