Cleaned up and started refactoring NS/QZ wrappers for Mac