https://bugs.winehq.org/show_bug.cgi?id=42481
--- Comment #4 from Ken Thomases ken@codeweavers.com --- (In reply to jobstz from comment #0)
With the introduction of SIP (System integrity protection) there is no longer any propagation of DYLD_* environment variables to child processes.
This is not quite accurate. DYLD_* variables are only stripped when exec-ing protected binaries. There is no general prohibition against them propagating to child processes. Unfortunately, the system-provided script interpreters, such as /bin/sh, are protected binaries. So, DYLD_* variables are stripped when a shell script is started.
But, for example, if one had a wine script to wrap the launching of the wine executable and that script itself were to set DYLD_* variables before running the wineloader executable, those variables would be inherited by and affect the operation of the wineloader process as desired.
I don't know exactly what Homebrew does for its Wine install or how it currently tries to use DYLD_* variables. Mechanisms are available to avoid this problem, at least in theory.