On 9/9/21 9:05 AM, Esme Povirk (she/they) wrote:
Actually, the "clever" solution may be to base any changes in loader behavior on the path of the dll, not how it was loaded. If a library is dynamically loading dependencies on Windows, it's already going to ensure it loads them based on its own location.
Is that guaranteed? Is there any reason that an application can't put DLLs in system32?
Granted, I don't actually know if there even are any libraries that do this. I guess that if there are, it'd break building everything as static as well, so maybe it doesn't matter.