- add build time debug flag
- fix windows architecture detection