diff --git a/cocos/base/ccMacros.h b/cocos/base/ccMacros.h index 525066f2c4..17398234c9 100644 --- a/cocos/base/ccMacros.h +++ b/cocos/base/ccMacros.h @@ -45,7 +45,7 @@ extern bool CC_DLL cc_assert_script_compatible(const char* msg); { \ if (!(cond)) \ { \ - if (!cc_assert_script_compatible(msg) && strlen(msg)) \ + if (msg && *msg && !cc_assert_script_compatible(msg)) \ cocos2d::log("Assert failed: %s", msg); \ CC_ASSERT(cond); \ } \ diff --git a/extensions/scripting/lua-bindings/CMakeLists.txt b/extensions/scripting/lua-bindings/CMakeLists.txt index 5590dacdb3..87f91e51ed 100644 --- a/extensions/scripting/lua-bindings/CMakeLists.txt +++ b/extensions/scripting/lua-bindings/CMakeLists.txt @@ -161,6 +161,10 @@ add_library(${ADXE_LUA_LIB} STATIC ${lua_bindings_files}) target_link_libraries(${ADXE_LUA_LIB} ${ADXE_CORE_LIB}) add_dependencies(${ADXE_LUA_LIB} ${ADXE_CORE_LIB}) +if(MSVC) + target_compile_options(${ADXE_LUA_LIB} PRIVATE /bigobj) +endif() + get_target_property(lua_ext_depend thirdparty CC_LUA_DEPEND) target_link_libraries(${ADXE_LUA_LIB} ${lua_ext_depend})