From 1c68cbf70f1d1b9aaa6a927943d4f1c075ce8d1c Mon Sep 17 00:00:00 2001 From: Daniel Dragan Date: Thu, 21 May 2015 17:06:27 -0400 Subject: refactor win32_get_*lib() funcs to match rest of PERL_IMPLICIT_SYS API The front end of PERL_IMPLICIT_SYS is PerlEnv_*/PerlSock_*/PerlProc_*/etc macros. These are either macroed to C vtable calls when PERL_IMPLICIT_SYS is on, or to the backend raw win32_*() functions when PERL_IMPLICIT_SYS is off. win32_get_*() were not following this convention. All this code looks like a hack as if someone didn't have perms to edit perl.c, but they did have perms to edit /win32, so they devise a scheme of hooking "unhooked" win32_get_*() functions with win32.h macros for win32_get_*() to call the Perl*() virutalization macros, and rename the original function bodies in win32.c to g_win32_get_*() as to not make a macro loop. Undo all of this hack by having perl.c call correct PerlEnv_* macro. This refactoring will be useful for a future patch in #123658 to disable win32 registry lookups. --- win32/config_H.vc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'win32/config_H.vc') diff --git a/win32/config_H.vc b/win32/config_H.vc index 1253e7502d..3444bce59c 100644 --- a/win32/config_H.vc +++ b/win32/config_H.vc @@ -3056,7 +3056,7 @@ * in programs that are not prepared to deal with ~ expansion at run-time. */ #define PRIVLIB "c:\\perl\\lib" /**/ -#define PRIVLIB_EXP (win32_get_privlib(PERL_VERSION_STRING, NULL)) /**/ +#define PRIVLIB_EXP (PerlEnv_lib_path(PERL_VERSION_STRING, NULL)) /**/ /* CAN_PROTOTYPE: * If defined, this macro indicates that the C compiler can handle @@ -3223,7 +3223,7 @@ * be tacked onto this variable to generate a list of directories to search. */ #define SITELIB "c:\\perl\\site\\lib" /**/ -#define SITELIB_EXP (win32_get_sitelib(PERL_VERSION_STRING, NULL)) /**/ +#define SITELIB_EXP (PerlEnv_sitelib_path(PERL_VERSION_STRING, NULL)) /**/ #define SITELIB_STEM "" /**/ /* Size_t_size: -- cgit v1.2.1