https://bugs.winehq.org/show_bug.cgi?id=40330
--- Comment #4 from Kyle Auble kyle.auble@zoho.com --- Hi Adam,
First let me apologize for not responding sooner. I just stumbled across this bug report while checking for any old bugs I was subscribed to. I honestly don't remember getting a notice; it probably came right when I was dropping off the internet for a while.
Anyways, by now you've probably either moved on or upgraded to newer versions that work, but I have an idea about what might be happening. My best guess is that if you follow the new instructions on the wiki, passing the "-Og" compiler flag rather than "-g -O1" (even if you still use GCC v4.8), it should work.
I see you figured out that you need to pass "-fsanitize=address" to the linker in addition to the compiler. That was an omission from the Building Wine page that has since been fixed. The problems you saw after that though may have come from not passing all 3 of the "-fno-..." flags mentioned on the wiki.
I think "-lasan -lthread" is completely redundant as long as you also pass "-fsanitize=address" to the linker, but without all 3 "-fno-..." flags, it's very possible the compiler optimized away something ASan would require to hook into Wine at execution.
The "-Og" flag is nice since it asks the compiler (so essentially the compiler devs) to select exactly the optimizations you need for debugging tools. That way you don't have to worry about any of the "-fno-..." flags anymore.
Of course, if you (or anyone else) still has this problem, and the new instructions don't fix it, definitely update us here. I'll try to keep a closer eye on the report and look into it more if needed.