dzn: add a couple of debug-flags
This adds two debug-flags that has been useful while debugging things for me.
- A flag to wait for the debugger on start-up
- A flag to redirect stdout/stderr
The second patch might not quite be the right approach, it might be better to add a separate environment var to specify a path where we log stuff a bit more targeted instead, perhaps.
Even better would be to somehow convince all relevant logging to go to os_log_message()
/ OutputDebugStringA()
, but that seems like a time consuming task...