diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 2000-01-09 22:27:19 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 2000-01-09 22:27:19 +0000 |
commit | 273cf8d1f309172b4416e78e4a8e80c12d941254 (patch) | |
tree | 641986755e0e9fcd423ac9000b67cb3688ec8cec /win32 | |
parent | 97404f98a6349e3129d8b12b25786316a12e66dc (diff) | |
download | perl-273cf8d1f309172b4416e78e4a8e80c12d941254.tar.gz |
more changes for new-style version numbers (versions numbers on
the filesystem look like 5.5.640, except on DOS-DJGPP and VMS where
they look like 5_5_640; delete @Config{pm_apiversion,xs_apiversion};
split $Config{apiversion} into three, @Config{apirevision,apiversion,
apisubversion} for CPP friendliness; $Config{sitelib} now defaults
to .../site_perl/$version, just like $Config{privlib}, making sitelib
completely independent across versions and substantially eliminating
chances of breaking older installations by overwriting newly built
extensions; all this means compatibility inclusions for @INC will need
to take into account older sitelib versions (this still TODO)
windows, vms, dos tweaks for the above
p4raw-id: //depot/perl@4773
Diffstat (limited to 'win32')
-rw-r--r-- | win32/Makefile | 2 | ||||
-rw-r--r-- | win32/config.bc | 14 | ||||
-rw-r--r-- | win32/config.gc | 14 | ||||
-rw-r--r-- | win32/config.vc | 12 | ||||
-rw-r--r-- | win32/config_H.bc | 51 | ||||
-rw-r--r-- | win32/config_H.gc | 51 | ||||
-rw-r--r-- | win32/config_H.vc | 51 | ||||
-rw-r--r-- | win32/config_h.PL | 4 | ||||
-rw-r--r-- | win32/config_sh.PL | 14 | ||||
-rw-r--r-- | win32/makefile.mk | 2 | ||||
-rw-r--r-- | win32/win32.c | 17 |
11 files changed, 60 insertions, 172 deletions
diff --git a/win32/Makefile b/win32/Makefile index 6cfb264612..5808879b8f 100644 --- a/win32/Makefile +++ b/win32/Makefile @@ -29,7 +29,7 @@ INST_TOP = $(INST_DRV)\perl # versioned installation can be obtained by setting INST_TOP above to a # path that includes an arbitrary version string. # -INST_VER = \5.00564 +INST_VER = \5.5.640 # # Comment this out if you DON'T want your perl installation to have diff --git a/win32/config.bc b/win32/config.bc index 915c733c7f..8dba78c0f1 100644 --- a/win32/config.bc +++ b/win32/config.bc @@ -19,7 +19,9 @@ afs='false' alignbytes='8' ansi2knr='' aphostname='' -apiversion='~PERL_APIVERSION~' +apirevision='~PERL_API_REVISION~' +apisubversion='~PERL_API_SUBVERSION~' +apiversion='~PERL_API_VERSION~' ar='tlib /P128' archlib='~INST_TOP~~INST_VER~\lib~INST_ARCH~' archlibexp='~INST_TOP~~INST_VER~\lib~INST_ARCH~' @@ -27,7 +29,7 @@ archname64='' archname='MSWin32' archobjs='' awk='awk' -baserev='5.0' +baserev='5' bash='' bin='~INST_TOP~~INST_VER~\bin~INST_ARCH~' bincompat5005='undef' @@ -572,7 +574,6 @@ pg='' phostname='hostname' pidtype='int' plibpth='' -pm_apiversion='5.005' pmake='' pr='' prefix='~INST_TOP~' @@ -722,12 +723,13 @@ version='~VERSION~' vi='' voidflags='15' xlibpth='/usr/lib/386 /lib/386' -xs_apiversion='~PERL_APIVERSION~' zcat='' zip='zip' PERL_REVISION='~PERL_REVISION~' -PERL_VERSION='~PERL_VERSION~' PERL_SUBVERSION='~PERL_SUBVERSION~' -PERL_APIVERSION='~PERL_APIVERSION~' +PERL_VERSION='~PERL_VERSION~' +PERL_API_REVISION='~PERL_API_REVISION~' +PERL_API_SUBVERSION='~PERL_API_SUBVERSION~' +PERL_API_VERSION='~PERL_API_VERSION~' PATCHLEVEL='~PERL_VERSION~' SUBVERSION='~PERL_SUBVERSION~' diff --git a/win32/config.gc b/win32/config.gc index a5f8d4087c..556ba2b581 100644 --- a/win32/config.gc +++ b/win32/config.gc @@ -19,7 +19,9 @@ afs='false' alignbytes='8' ansi2knr='' aphostname='' -apiversion='~PERL_APIVERSION~' +apirevision='~PERL_API_REVISION~' +apisubversion='~PERL_API_SUBVERSION~' +apiversion='~PERL_API_VERSION~' ar='ar' archlib='~INST_TOP~~INST_VER~\lib~INST_ARCH~' archlibexp='~INST_TOP~~INST_VER~\lib~INST_ARCH~' @@ -27,7 +29,7 @@ archname64='' archname='MSWin32' archobjs='' awk='awk' -baserev='5.0' +baserev='5' bash='' bin='~INST_TOP~~INST_VER~\bin~INST_ARCH~' bincompat5005='undef' @@ -572,7 +574,6 @@ pg='' phostname='hostname' pidtype='int' plibpth='' -pm_apiversion='5.005' pmake='' pr='' prefix='~INST_TOP~' @@ -722,12 +723,13 @@ version='~VERSION~' vi='' voidflags='15' xlibpth='/usr/lib/386 /lib/386' -xs_apiversion='~PERL_APIVERSION~' zcat='' zip='zip' PERL_REVISION='~PERL_REVISION~' -PERL_VERSION='~PERL_VERSION~' PERL_SUBVERSION='~PERL_SUBVERSION~' -PERL_APIVERSION='~PERL_APIVERSION~' +PERL_VERSION='~PERL_VERSION~' +PERL_API_REVISION='~PERL_API_REVISION~' +PERL_API_SUBVERSION='~PERL_API_SUBVERSION~' +PERL_API_VERSION='~PERL_API_VERSION~' PATCHLEVEL='~PERL_VERSION~' SUBVERSION='~PERL_SUBVERSION~' diff --git a/win32/config.vc b/win32/config.vc index 4428c470fa..0e37b3c056 100644 --- a/win32/config.vc +++ b/win32/config.vc @@ -19,7 +19,9 @@ afs='false' alignbytes='8' ansi2knr='' aphostname='' -apiversion='~PERL_APIVERSION~' +apirevision='~PERL_API_REVISION~' +apisubversion='~PERL_API_SUBVERSION~' +apiversion='~PERL_API_VERSION~' ar='lib' archlib='~INST_TOP~~INST_VER~\lib~INST_ARCH~' archlibexp='~INST_TOP~~INST_VER~\lib~INST_ARCH~' @@ -27,7 +29,7 @@ archname64='' archname='MSWin32' archobjs='' awk='awk' -baserev='5.0' +baserev='5' bash='' bin='~INST_TOP~~INST_VER~\bin~INST_ARCH~' bincompat5005='undef' @@ -572,7 +574,6 @@ pg='' phostname='hostname' pidtype='int' plibpth='' -pm_apiversion='5.005' pmake='' pr='' prefix='~INST_TOP~' @@ -722,12 +723,13 @@ version='~VERSION~' vi='' voidflags='15' xlibpth='/usr/lib/386 /lib/386' -xs_apiversion='~PERL_APIVERSION~' zcat='' zip='zip' PERL_REVISION='~PERL_REVISION~' PERL_VERSION='~PERL_VERSION~' PERL_SUBVERSION='~PERL_SUBVERSION~' -PERL_APIVERSION='~PERL_APIVERSION~' +PERL_API_REVISION='~PERL_API_REVISION~' +PERL_API_SUBVERSION='~PERL_API_SUBVERSION~' +PERL_API_VERSION='~PERL_API_VERSION~' PATCHLEVEL='~PERL_VERSION~' SUBVERSION='~PERL_SUBVERSION~' diff --git a/win32/config_H.bc b/win32/config_H.bc index de0fb35bd6..1455fad6b9 100644 --- a/win32/config_H.bc +++ b/win32/config_H.bc @@ -1429,7 +1429,7 @@ * This symbol contains the ~name expanded version of ARCHLIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define ARCHLIB "c:\\perl\\5.00563\\lib\\MSWin32-x86" /**/ +#define ARCHLIB "c:\\perl\\5.5.640\\lib\\MSWin32-x86" /**/ /*#define ARCHLIB_EXP "" /**/ /* BIN: @@ -1440,8 +1440,8 @@ * This symbol is the filename expanded version of the BIN symbol, for * programs that do not want to deal with that at run-time. */ -#define BIN "c:\\perl\\5.00563\\bin\\MSWin32-x86" /**/ -#define BIN_EXP "c:\\perl\\5.00563\\bin\\MSWin32-x86" /**/ +#define BIN "c:\\perl\\5.5.640\\bin\\MSWin32-x86" /**/ +#define BIN_EXP "c:\\perl\\5.5.640\\bin\\MSWin32-x86" /**/ /* INSTALL_USR_BIN_PERL: * This symbol, if defined, indicates that Perl is to be installed @@ -1459,8 +1459,8 @@ * This symbol contains the ~name expanded version of PRIVLIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define PRIVLIB "c:\\perl\\5.00563\\lib" /**/ -#define PRIVLIB_EXP (win32_get_privlib("5.00563")) /**/ +#define PRIVLIB "c:\\perl\\5.5.640\\lib" /**/ +#define PRIVLIB_EXP (win32_get_privlib("5.5.640")) /**/ /* SITEARCH: * This symbol contains the name of the private library for this package. @@ -1477,7 +1477,7 @@ * This symbol contains the ~name expanded version of SITEARCH, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define SITEARCH "c:\\perl\\site\\5.00563\\lib\\MSWin32-x86" /**/ +#define SITEARCH "c:\\perl\\site\\5.5.640\\lib\\MSWin32-x86" /**/ /*#define SITEARCH_EXP "" /**/ /* SITELIB: @@ -1495,8 +1495,8 @@ * This symbol contains the ~name expanded version of SITELIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define SITELIB "c:\\perl\\site\\5.00563\\lib" /**/ -#define SITELIB_EXP (win32_get_sitelib("5.00563")) /**/ +#define SITELIB "c:\\perl\\site\\5.5.640\\lib" /**/ +#define SITELIB_EXP (win32_get_sitelib("5.5.640")) /**/ /* PERL_VENDORLIB_EXP: * This symbol contains the ~name expanded version of VENDORLIB, to be used @@ -2599,41 +2599,6 @@ /*#define USE_SOCKS /**/ #endif -/* PERL_XS_APIVERSION: - * This variable contains the version of the oldest perl binary - * compatible with the present perl. perl.c:incpush() and - * lib/lib.pm will automatically search in c:\\perl\\site\\5.00563\\lib\\MSWin32-x86 for older - * directories across major versions back to xs_apiversion. - * This is only useful if you have a perl library directory tree - * structured like the default one. - * See INSTALL for how this works. - * The versioned site_perl directory was introduced in 5.005, - * so that is the lowest possible value. - * Since this can depend on compile time options (such as - * bincompat) it is set by Configure. Other non-default sources - * of potential incompatibility, such as multiplicity, threads, - * debugging, 64bits, sfio, etc., are not checked for currently, - * though in principle we could go snooping around in old - * Config.pm files. - */ -/* PERL_PM_APIVERSION: - * This variable contains the version of the oldest perl - * compatible with the present perl. (That is, pure perl modules - * written for pm_apiversion will still work for the current - * version). perl.c:incpush() and lib/lib.pm will automatically - * search in c:\\perl\\site\\5.00563\\lib for older directories across major versions - * back to pm_apiversion. This is only useful if you have a perl - * library directory tree structured like the default one. The - * versioned site_perl library was introduced in 5.005, so that's - * the default setting for this variable. It's hard to imagine - * it changing before Perl6. It is included here for symmetry - * with xs_apiveprsion -- the searching algorithms will - * (presumably) be similar. - * See the INSTALL file for how this works. - */ -#define PERL_XS_APIVERSION 5.00563 /* Change to string for tuples?*/ -#define PERL_PM_APIVERSION 5.005 /* Change to string for tuples?*/ - /* HAS_DRAND48_PROTO: * This symbol, if defined, indicates that the system provides * a prototype for the drand48() function. Otherwise, it is up diff --git a/win32/config_H.gc b/win32/config_H.gc index cd4efc2a2e..77187f6785 100644 --- a/win32/config_H.gc +++ b/win32/config_H.gc @@ -1429,7 +1429,7 @@ * This symbol contains the ~name expanded version of ARCHLIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define ARCHLIB "c:\\perl\\5.00563\\lib\\MSWin32-x86" /**/ +#define ARCHLIB "c:\\perl\\5.5.640\\lib\\MSWin32-x86" /**/ /*#define ARCHLIB_EXP "" /**/ /* BIN: @@ -1440,8 +1440,8 @@ * This symbol is the filename expanded version of the BIN symbol, for * programs that do not want to deal with that at run-time. */ -#define BIN "c:\\perl\\5.00563\\bin\\MSWin32-x86" /**/ -#define BIN_EXP "c:\\perl\\5.00563\\bin\\MSWin32-x86" /**/ +#define BIN "c:\\perl\\5.5.640\\bin\\MSWin32-x86" /**/ +#define BIN_EXP "c:\\perl\\5.5.640\\bin\\MSWin32-x86" /**/ /* INSTALL_USR_BIN_PERL: * This symbol, if defined, indicates that Perl is to be installed @@ -1459,8 +1459,8 @@ * This symbol contains the ~name expanded version of PRIVLIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define PRIVLIB "c:\\perl\\5.00563\\lib" /**/ -#define PRIVLIB_EXP (win32_get_privlib("5.00563")) /**/ +#define PRIVLIB "c:\\perl\\5.5.640\\lib" /**/ +#define PRIVLIB_EXP (win32_get_privlib("5.5.640")) /**/ /* SITEARCH: * This symbol contains the name of the private library for this package. @@ -1477,7 +1477,7 @@ * This symbol contains the ~name expanded version of SITEARCH, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define SITEARCH "c:\\perl\\site\\5.00563\\lib\\MSWin32-x86" /**/ +#define SITEARCH "c:\\perl\\site\\5.5.640\\lib\\MSWin32-x86" /**/ /*#define SITEARCH_EXP "" /**/ /* SITELIB: @@ -1495,8 +1495,8 @@ * This symbol contains the ~name expanded version of SITELIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define SITELIB "c:\\perl\\site\\5.00563\\lib" /**/ -#define SITELIB_EXP (win32_get_sitelib("5.00563")) /**/ +#define SITELIB "c:\\perl\\site\\5.5.640\\lib" /**/ +#define SITELIB_EXP (win32_get_sitelib("5.5.640")) /**/ /* PERL_VENDORLIB_EXP: * This symbol contains the ~name expanded version of VENDORLIB, to be used @@ -2599,41 +2599,6 @@ /*#define USE_SOCKS /**/ #endif -/* PERL_XS_APIVERSION: - * This variable contains the version of the oldest perl binary - * compatible with the present perl. perl.c:incpush() and - * lib/lib.pm will automatically search in c:\\perl\\site\\5.00563\\lib\\MSWin32-x86 for older - * directories across major versions back to xs_apiversion. - * This is only useful if you have a perl library directory tree - * structured like the default one. - * See INSTALL for how this works. - * The versioned site_perl directory was introduced in 5.005, - * so that is the lowest possible value. - * Since this can depend on compile time options (such as - * bincompat) it is set by Configure. Other non-default sources - * of potential incompatibility, such as multiplicity, threads, - * debugging, 64bits, sfio, etc., are not checked for currently, - * though in principle we could go snooping around in old - * Config.pm files. - */ -/* PERL_PM_APIVERSION: - * This variable contains the version of the oldest perl - * compatible with the present perl. (That is, pure perl modules - * written for pm_apiversion will still work for the current - * version). perl.c:incpush() and lib/lib.pm will automatically - * search in c:\\perl\\site\\5.00563\\lib for older directories across major versions - * back to pm_apiversion. This is only useful if you have a perl - * library directory tree structured like the default one. The - * versioned site_perl library was introduced in 5.005, so that's - * the default setting for this variable. It's hard to imagine - * it changing before Perl6. It is included here for symmetry - * with xs_apiveprsion -- the searching algorithms will - * (presumably) be similar. - * See the INSTALL file for how this works. - */ -#define PERL_XS_APIVERSION 5.00563 /* Change to string for tuples?*/ -#define PERL_PM_APIVERSION 5.005 /* Change to string for tuples?*/ - /* HAS_DRAND48_PROTO: * This symbol, if defined, indicates that the system provides * a prototype for the drand48() function. Otherwise, it is up diff --git a/win32/config_H.vc b/win32/config_H.vc index 032a9c8cbc..44c2bb3533 100644 --- a/win32/config_H.vc +++ b/win32/config_H.vc @@ -1429,7 +1429,7 @@ * This symbol contains the ~name expanded version of ARCHLIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define ARCHLIB "c:\\perl\\5.00563\\lib\\MSWin32-x86" /**/ +#define ARCHLIB "c:\\perl\\5.5.640\\lib\\MSWin32-x86" /**/ /*#define ARCHLIB_EXP "" /**/ /* BIN: @@ -1440,8 +1440,8 @@ * This symbol is the filename expanded version of the BIN symbol, for * programs that do not want to deal with that at run-time. */ -#define BIN "c:\\perl\\5.00563\\bin\\MSWin32-x86" /**/ -#define BIN_EXP "c:\\perl\\5.00563\\bin\\MSWin32-x86" /**/ +#define BIN "c:\\perl\\5.5.640\\bin\\MSWin32-x86" /**/ +#define BIN_EXP "c:\\perl\\5.5.640\\bin\\MSWin32-x86" /**/ /* INSTALL_USR_BIN_PERL: * This symbol, if defined, indicates that Perl is to be installed @@ -1459,8 +1459,8 @@ * This symbol contains the ~name expanded version of PRIVLIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define PRIVLIB "c:\\perl\\5.00563\\lib" /**/ -#define PRIVLIB_EXP (win32_get_privlib("5.00563")) /**/ +#define PRIVLIB "c:\\perl\\5.5.640\\lib" /**/ +#define PRIVLIB_EXP (win32_get_privlib("5.5.640")) /**/ /* SITEARCH: * This symbol contains the name of the private library for this package. @@ -1477,7 +1477,7 @@ * This symbol contains the ~name expanded version of SITEARCH, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define SITEARCH "c:\\perl\\site\\5.00563\\lib\\MSWin32-x86" /**/ +#define SITEARCH "c:\\perl\\site\\5.5.640\\lib\\MSWin32-x86" /**/ /*#define SITEARCH_EXP "" /**/ /* SITELIB: @@ -1495,8 +1495,8 @@ * This symbol contains the ~name expanded version of SITELIB, to be used * in programs that are not prepared to deal with ~ expansion at run-time. */ -#define SITELIB "c:\\perl\\site\\5.00563\\lib" /**/ -#define SITELIB_EXP (win32_get_sitelib("5.00563")) /**/ +#define SITELIB "c:\\perl\\site\\5.5.640\\lib" /**/ +#define SITELIB_EXP (win32_get_sitelib("5.5.640")) /**/ /* PERL_VENDORLIB_EXP: * This symbol contains the ~name expanded version of VENDORLIB, to be used @@ -2599,41 +2599,6 @@ /*#define USE_SOCKS /**/ #endif -/* PERL_XS_APIVERSION: - * This variable contains the version of the oldest perl binary - * compatible with the present perl. perl.c:incpush() and - * lib/lib.pm will automatically search in c:\\perl\\site\\5.00563\\lib\\MSWin32-x86 for older - * directories across major versions back to xs_apiversion. - * This is only useful if you have a perl library directory tree - * structured like the default one. - * See INSTALL for how this works. - * The versioned site_perl directory was introduced in 5.005, - * so that is the lowest possible value. - * Since this can depend on compile time options (such as - * bincompat) it is set by Configure. Other non-default sources - * of potential incompatibility, such as multiplicity, threads, - * debugging, 64bits, sfio, etc., are not checked for currently, - * though in principle we could go snooping around in old - * Config.pm files. - */ -/* PERL_PM_APIVERSION: - * This variable contains the version of the oldest perl - * compatible with the present perl. (That is, pure perl modules - * written for pm_apiversion will still work for the current - * version). perl.c:incpush() and lib/lib.pm will automatically - * search in c:\\perl\\site\\5.00563\\lib for older directories across major versions - * back to pm_apiversion. This is only useful if you have a perl - * library directory tree structured like the default one. The - * versioned site_perl library was introduced in 5.005, so that's - * the default setting for this variable. It's hard to imagine - * it changing before Perl6. It is included here for symmetry - * with xs_apiveprsion -- the searching algorithms will - * (presumably) be similar. - * See the INSTALL file for how this works. - */ -#define PERL_XS_APIVERSION 5.00563 /* Change to string for tuples?*/ -#define PERL_PM_APIVERSION 5.005 /* Change to string for tuples?*/ - /* HAS_DRAND48_PROTO: * This symbol, if defined, indicates that the system provides * a prototype for the drand48() function. Otherwise, it is up diff --git a/win32/config_h.PL b/win32/config_h.PL index 16e467e915..17f3fc2163 100644 --- a/win32/config_h.PL +++ b/win32/config_h.PL @@ -13,8 +13,8 @@ while (@ARGV && $ARGV[0] =~ /^([\w_]+)=(.*)$/) } my $patchlevel = $opt{INST_VER}; $patchlevel =~ s|^[\\/]||; -$patchlevel =~ s|~VERSION~|$]|g; -$patchlevel ||= $]; +$patchlevel =~ s|~VERSION~|$Config{version}|g; +$patchlevel ||= $Config{version}; $patchlevel = qq["$patchlevel"]; open(SH,"<$name") || die "Cannot open $name:$!"; diff --git a/win32/config_sh.PL b/win32/config_sh.PL index b1c7b9f592..0e1d351c1a 100644 --- a/win32/config_sh.PL +++ b/win32/config_sh.PL @@ -42,8 +42,6 @@ while (@{$optref} && $optref->[0] =~ /^([\w_]+)=(.*)$/) { my $pl_h = '../patchlevel.h'; -$opt{VERSION} = $]; -$opt{INST_VER} =~ s|~VERSION~|$]|g; if (-e $pl_h) { open PL, "<$pl_h" or die "Can't open $pl_h: $!"; while (<PL>) { @@ -53,17 +51,11 @@ if (-e $pl_h) { } close PL; } -elsif ($] =~ /^(\d+)\.(\d\d\d)?(\d\d)?$/) { # should always be true - $opt{PERL_REVISION} = $1; - $opt{PERL_VERSION} = int($2 || 0); - $opt{PERL_SUBVERSION} = $3; - $opt{PERL_APIVERSION} = $]; -} else { - die "Can't parse perl version ($])"; + die "Can't find $pl_h: $!"; } - -$opt{PERL_SUBVERSION} ||= '00'; +$opt{VERSION} = "$opt{PERL_REVISION}.$opt{PERL_VERSION}.$opt{PERL_SUBVERSION}"; +$opt{INST_VER} =~ s|~VERSION~|$opt{VERSION}|g; $opt{'cf_by'} = $ENV{USERNAME} unless $opt{'cf_by'}; $opt{'cf_email'} = $opt{'cf_by'} . '@' . (gethostbyname('localhost'))[0] diff --git a/win32/makefile.mk b/win32/makefile.mk index b7bf93fcf2..01034bb813 100644 --- a/win32/makefile.mk +++ b/win32/makefile.mk @@ -33,7 +33,7 @@ INST_TOP *= $(INST_DRV)\perl # versioned installation can be obtained by setting INST_TOP above to a # path that includes an arbitrary version string. # -INST_VER *= \5.00564 +INST_VER *= \5.5.640 # # Comment this out if you DON'T want your perl installation to have diff --git a/win32/win32.c b/win32/win32.c index 53288af338..43e9b5e876 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -176,12 +176,13 @@ get_emd_part(SV **prev_pathp, char *trailing_path, ...) char *optr; char *strip; int oldsize, newsize; + STRLEN baselen; va_start(ap, trailing_path); strip = va_arg(ap, char *); - sprintf(base, "%5.3f", - (double)PERL_REVISION + ((double)PERL_VERSION / (double)1000)); + sprintf(base, "%d.%d", (int)PERL_REVISION, (int)PERL_VERSION); + baselen = strlen(base); if (!*w32_module_name) { GetModuleFileName((HMODULE)((w32_perldll_handle == INVALID_HANDLE_VALUE) @@ -213,10 +214,10 @@ get_emd_part(SV **prev_pathp, char *trailing_path, ...) /* avoid stripping component if there is no slash, * or it doesn't match ... */ if (!ptr || stricmp(ptr+1, strip) != 0) { - /* ... but not if component matches 5.00X* */ + /* ... but not if component matches m|5\.$patchlevel.*| */ if (!ptr || !(*strip == '5' && *(ptr+1) == '5' - && strncmp(strip, base, 5) == 0 - && strncmp(ptr+1, base, 5) == 0)) + && strncmp(strip, base, baselen) == 0 + && strncmp(ptr+1, base, baselen) == 0)) { *optr = '/'; ptr = optr; @@ -283,12 +284,6 @@ win32_get_sitelib(char *pl) * ";$EMD/" . ((-d $EMD/../../../$]) ? "../../.." : "../.."). "/site/$]/lib"; */ sprintf(pathstr, "site/%s/lib", pl); (void)get_emd_part(&sv1, pathstr, ARCHNAME, "bin", pl, Nullch); - if (!sv1 && strlen(pl) == 7) { - /* pl may have been SUBVERSION-specific; try again without - * SUBVERSION */ - sprintf(pathstr, "site/%.5s/lib", pl); - (void)get_emd_part(&sv1, pathstr, ARCHNAME, "bin", pl, Nullch); - } /* $HKCU{'sitelib'} || $HKLM{'sitelib'} . ---; */ (void)get_regstr(sitelib, &sv2); |