I am trying the use of ".local" at the bottom of this:
https://learn.microsoft.com/en-us/windows/win32/dlls/dynamic-link-library-redirection
My application is called pdptest.exe so I created a dummy
text file called pdptest.exe.local
I wanted it to use my own msvcrt.dll in the same directory.
Nothing happened - it still used the normal one provided
by Windows 10.
Then I recompiled pdptest.exe - and voila, it worked - ie
it executed my msvcrt.dll when I ran pdptest.
Then I created another directory and copied pdptest.exe,
pdptest.exe.local and msvcrt.dll to it.
It didn't work - ie it went to the Windows-provided one.
Any idea what is happening?
Although that's still not what I want.
What I would like to be able to do is have my existing
unchanged executables that depend on msvcrt.dll and
that I have put into my c:\winpath execute an msvcrt.dll
from a specified directory, or follow the PATH variable
or some other variable. Or even if they execute an
msvcrt.dll that is in c:\winpath, that would also be ok.
I don't want to create a ".local" dummy file for every
single one of my executables. Nor do I want to change
any of my executables.
Any idea how to do that?
BTW, I wasn't able to rename msvcrt.dll to msvcrt.dxx
in c:\windows\syswow64 so that I could put in my own.
I really want different windows to be able to have a
different PATH variable, so normally syswow64 is
right, and default, but I in select windows I can
change my PATH and start getting my own msvcrt.dll
executed, because all the programs I will be running
will work nicely with that one.
I checked knowndlls as described here:
https://learn.microsoft.com/en-us/windows/win32/dlls/dynamic-link-library-search-order
and msvcrt is on the list.
Maybe I need to delete that?
Thanks. Paul.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 379 |
Nodes: | 16 (2 / 14) |
Uptime: | 42:50:03 |
Calls: | 8,141 |
Calls today: | 4 |
Files: | 13,085 |
Messages: | 5,857,851 |