Fixes TLS for statically linked apps in _M mode