ouzel
ouzel copied to clipboard
CMake build scripts
Added CMake support and fixed some compile errors. Compiles on latest version on Windows/Mac/Linux, but fail to compile on some older platforms(likely a compiler problem).
Summary:
- #undef linux on linux, because linux is defined by the compiler and used as an identifier.
- Added github CI.
- Cast return value of MAKEINTATOM to LPCWSTR because some functions expect a LPCWSTR not LPTSTR
- Make closeSocket a wrapper function on Windows because the compiler complains.
- Call to CreateMasteringVoice in IXAudio2CreateMasteringVoice is not valid.
- Most HRESULT error codes are larger than INT_MAX. Wrapped them in an 'enum ErrorCode'. Use ErrorCode in each ErrorCategory::message(). Also convert HRESULT to ErrorCode before passing to std::system_error.