moai / moai-dev

This is the development repo of Moai SDK.
http://getmoai.com
944 stars 313 forks source link

Build broken on Windows 10 using CMake #1215

Open programadorthi opened 5 years ago

programadorthi commented 5 years ago

https://github.com/moai/moai-dev/blob/b01816fe862b6b2fc7f53e6ada0d1544927d9d87/src/moai-core/MOAILuaRuntime.cpp#L829

This above line I did fix changing to call: return this->mState.IsValid(); because is the same logic.

https://github.com/moai/moai-dev/blob/b01816fe862b6b2fc7f53e6ada0d1544927d9d87/src/moai-sim/MOAIFrameBuffer.cpp#L63

This above line I did fix changing for the code below. I didn't know if it is correct but it works:

MOAILuaSharedPtr< int > empty;

self->mGrabNextFrame = self->mFrameImage != empty;

https://github.com/moai/moai-dev/blob/b01816fe862b6b2fc7f53e6ada0d1544927d9d87/cmake/cmake/third-party/sdl2/CMakeLists.txt#L5

The SDL2 third-party is using version 2.0.4 but there is 2.0.9 in submodules folder only. Changed to 2.0.9 line 5 and line 11 works.

https://github.com/moai/moai-dev/blob/b01816fe862b6b2fc7f53e6ada0d1544927d9d87/src/zl-gfx/ZLGfxDevice.cpp#L127

This variable majorVersion is not declared in the class. I changed to sMajorVersion.

I didn't make a pull request because I don't know if these changes are correct.