From 1ef1a809b51dd066f799619451fba8b2a456b361 Mon Sep 17 00:00:00 2001 From: CocosRobot Date: Mon, 14 Jul 2014 08:53:13 +0000 Subject: [PATCH 1/3] [AUTO]: updating luabinding automatically --- .../auto/api/TransitionPageTurn.lua | 4 -- .../auto/api/TransitionProgress.lua | 4 -- .../lua-bindings/auto/lua_cocos2dx_auto.cpp | 70 ------------------- .../lua-bindings/auto/lua_cocos2dx_auto.hpp | 2 - 4 files changed, 80 deletions(-) diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua b/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua index fa8d58c4fc..1c655d6fab 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionPageTurn.lua @@ -33,8 +33,4 @@ -- @param #mat4_table mat4 -- @param #unsigned int int --------------------------------- --- @function [parent=#TransitionPageTurn] TransitionPageTurn --- @param self - return nil diff --git a/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua b/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua index dd78bcf0e7..d05379f82b 100644 --- a/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua +++ b/cocos/scripting/lua-bindings/auto/api/TransitionProgress.lua @@ -11,8 +11,4 @@ -- @param #cc.Scene scene -- @return TransitionProgress#TransitionProgress ret (return value: cc.TransitionProgress) --------------------------------- --- @function [parent=#TransitionProgress] TransitionProgress --- @param self - return nil diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp index c64da13f70..c5c34c2ae2 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.cpp @@ -39201,40 +39201,6 @@ int lua_cocos2dx_TransitionPageTurn_create(lua_State* tolua_S) #endif return 0; } -int lua_cocos2dx_TransitionPageTurn_constructor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::TransitionPageTurn* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cobj = new cocos2d::TransitionPageTurn(); - cobj->autorelease(); - int ID = (int)cobj->_ID ; - int* luaID = &cobj->_luaID ; - toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionPageTurn"); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "TransitionPageTurn",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionPageTurn_constructor'.",&tolua_err); -#endif - - return 0; -} - static int lua_cocos2dx_TransitionPageTurn_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionPageTurn)"); @@ -39247,7 +39213,6 @@ int lua_register_cocos2dx_TransitionPageTurn(lua_State* tolua_S) tolua_cclass(tolua_S,"TransitionPageTurn","cc.TransitionPageTurn","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionPageTurn"); - tolua_function(tolua_S,"new",lua_cocos2dx_TransitionPageTurn_constructor); tolua_function(tolua_S,"actionWithSize",lua_cocos2dx_TransitionPageTurn_actionWithSize); tolua_function(tolua_S,"initWithDuration",lua_cocos2dx_TransitionPageTurn_initWithDuration); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionPageTurn_create); @@ -39293,40 +39258,6 @@ int lua_cocos2dx_TransitionProgress_create(lua_State* tolua_S) #endif return 0; } -int lua_cocos2dx_TransitionProgress_constructor(lua_State* tolua_S) -{ - int argc = 0; - cocos2d::TransitionProgress* cobj = nullptr; - bool ok = true; - -#if COCOS2D_DEBUG >= 1 - tolua_Error tolua_err; -#endif - - - - argc = lua_gettop(tolua_S)-1; - if (argc == 0) - { - if(!ok) - return 0; - cobj = new cocos2d::TransitionProgress(); - cobj->autorelease(); - int ID = (int)cobj->_ID ; - int* luaID = &cobj->_luaID ; - toluafix_pushusertype_ccobject(tolua_S, ID, luaID, (void*)cobj,"cc.TransitionProgress"); - return 1; - } - CCLOG("%s has wrong number of arguments: %d, was expecting %d \n", "TransitionProgress",argc, 0); - return 0; - -#if COCOS2D_DEBUG >= 1 - tolua_error(tolua_S,"#ferror in function 'lua_cocos2dx_TransitionProgress_constructor'.",&tolua_err); -#endif - - return 0; -} - static int lua_cocos2dx_TransitionProgress_finalize(lua_State* tolua_S) { printf("luabindings: finalizing LUA object (TransitionProgress)"); @@ -39339,7 +39270,6 @@ int lua_register_cocos2dx_TransitionProgress(lua_State* tolua_S) tolua_cclass(tolua_S,"TransitionProgress","cc.TransitionProgress","cc.TransitionScene",nullptr); tolua_beginmodule(tolua_S,"TransitionProgress"); - tolua_function(tolua_S,"new",lua_cocos2dx_TransitionProgress_constructor); tolua_function(tolua_S,"create", lua_cocos2dx_TransitionProgress_create); tolua_endmodule(tolua_S); std::string typeName = typeid(cocos2d::TransitionProgress).name(); diff --git a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp index a14e56b1b4..42b0e17ab0 100644 --- a/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp +++ b/cocos/scripting/lua-bindings/auto/lua_cocos2dx_auto.hpp @@ -1611,8 +1611,6 @@ int register_all_cocos2dx(lua_State* tolua_S); - - From 5e10575ab05f4e6bc087cfda1d93c828b88fd044 Mon Sep 17 00:00:00 2001 From: Dhilan007 Date: Mon, 14 Jul 2014 17:53:55 +0800 Subject: [PATCH 2/3] disable warn on zero-sized structures. --- cocos/2d/CCFontAtlasCache.cpp | 6 +++--- cocos/2d/CCFontAtlasCache.h | 1 - cocos/Android.mk | 4 ++-- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/cocos/2d/CCFontAtlasCache.cpp b/cocos/2d/CCFontAtlasCache.cpp index bad6c9f733..f088da6319 100644 --- a/cocos/2d/CCFontAtlasCache.cpp +++ b/cocos/2d/CCFontAtlasCache.cpp @@ -22,11 +22,11 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ****************************************************************************/ - -#include - #include "2d/CCFontAtlasCache.h" +#include +#include + #include "2d/CCFontFNT.h" #include "2d/CCFontFreeType.h" #include "CCFontCharMap.h" diff --git a/cocos/2d/CCFontAtlasCache.h b/cocos/2d/CCFontAtlasCache.h index 800948ba44..4e2c17c687 100644 --- a/cocos/2d/CCFontAtlasCache.h +++ b/cocos/2d/CCFontAtlasCache.h @@ -26,7 +26,6 @@ #ifndef _CCFontAtlasCache_h_ #define _CCFontAtlasCache_h_ -#include #include #include "2d/CCFontAtlas.h" diff --git a/cocos/Android.mk b/cocos/Android.mk index 219098f275..92ff9a8b65 100644 --- a/cocos/Android.mk +++ b/cocos/Android.mk @@ -223,9 +223,9 @@ LOCAL_WHOLE_STATIC_LIBRARIES += cocos2dxandroid_static # define the macro to compile through support/zip_support/ioapi.c LOCAL_CFLAGS := -DUSE_FILE32API -LOCAL_CPPFLAGS := -Wno-deprecated-declarations +LOCAL_CPPFLAGS := -Wno-deprecated-declarations -Wno-extern-c-compat LOCAL_EXPORT_CFLAGS := -DUSE_FILE32API -LOCAL_EXPORT_CPPFLAGS := -Wno-deprecated-declarations +LOCAL_EXPORT_CPPFLAGS := -Wno-deprecated-declarations -Wno-extern-c-compat include $(BUILD_STATIC_LIBRARY) From cc0a27e83ec969728f3821c771d3e4898ec97df3 Mon Sep 17 00:00:00 2001 From: Ricardo Quesada Date: Mon, 14 Jul 2014 18:39:36 -0700 Subject: [PATCH 3/3] default OS Target for OS X is 10.7 --- .../proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj | 2 ++ 1 file changed, 2 insertions(+) diff --git a/templates/cpp-template-default/proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj b/templates/cpp-template-default/proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj index 20dc740a62..15fe6d6f6b 100644 --- a/templates/cpp-template-default/proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj +++ b/templates/cpp-template-default/proj.ios_mac/HelloCpp.xcodeproj/project.pbxproj @@ -941,6 +941,7 @@ "$(SRCROOT)/../cocos2d/external", "$(SRCROOT)/../cocos2d/external/chipmunk/include/chipmunk", ); + MACOSX_DEPLOYMENT_TARGET = 10.7; ONLY_ACTIVE_ARCH = YES; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx; @@ -969,6 +970,7 @@ "$(SRCROOT)/../cocos2d/external", "$(SRCROOT)/../cocos2d/external/chipmunk/include/chipmunk", ); + MACOSX_DEPLOYMENT_TARGET = 10.7; OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1"; PRODUCT_NAME = "$(TARGET_NAME)"; SDKROOT = macosx;