http://bugs.winehq.org/show_bug.cgi?id=34813
--- Comment #1 from Ken Thomases ken@codeweavers.com 2013-10-28 20:48:54 CDT --- The problem is Address Space Layout Randomization (ASLR). Dyld is being loaded into a random address in the process, which invalidates an assumption made in dlls/dbghelp/macho_module.c:macho_load_file(). That assumes that the address of the symbol "_dyld_all_image_infos" in /usr/lib/dyld is where the dynamic loader image info will be found in all processes.
In the presence of ASLR, it's difficult to find where that dyld info really is.
The only viable approach I've found is to use Mach's task_info() function with the TASK_DYLD_INFO flavor. This requires that the caller have the debuggee's Mach task port name. A task can obtain its own task port name, but to obtain the task port name of another task requires privileges. Wine processes do send their task port to the wineserver at startup, though. So, it would be possible for the debugger to request that the wineserver obtain the debuggee's dyld info and return it.
(The TASK_DYLD_INFO flavor isn't declared in the 10.5 SDK, so we may need to keep the existing approach as a fallback until we abandon support for 10.5.)