mirror of
https://gitee.com/openharmony/third_party_vulkan-loader
synced 2024-12-03 13:10:50 +00:00
build: gh672 Fix CMake CXX_FLAGS inheritance
Some sub-projects were overwriting CMAKE_CXX_FLAGS instead of inheriting from the parent. This keeps any user settings outside or above the top CMakeLists.txt file from reaching these sub-projects. These fixes include preserving the inheritance, adding extra flags to turn off warnings (mostly in autogen code) because the top level turns on Wall, and trivial code fixes to avoid the need to add a setting to turn off a warning for those trivial fixes. These changes should have no impact on Windows. Change-Id: I0c3c175cb5058f26a259ee3f4fde9fdaf3e6b00d
This commit is contained in:
parent
a7c3421bc0
commit
eff15fc378
@ -68,9 +68,8 @@ if (WIN32)
|
||||
set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -D_CRT_SECURE_NO_WARNINGS /bigobj")
|
||||
set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -D_CRT_SECURE_NO_WARNINGS /bigobj")
|
||||
else()
|
||||
set (CMAKE_CXX_FLAGS "-std=c++11")
|
||||
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wpointer-arith")
|
||||
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wpointer-arith")
|
||||
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wpointer-arith -Wno-unused-function")
|
||||
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wpointer-arith -Wno-unused-function")
|
||||
endif()
|
||||
|
||||
add_custom_command(OUTPUT vk_dispatch_table_helper.h
|
||||
|
@ -1505,7 +1505,7 @@ VK_LAYER_EXPORT VKAPI_ATTR PFN_vkVoidFunction VKAPI_CALL vkGetInstanceProcAddr(V
|
||||
return addr;
|
||||
|
||||
wrapped_inst_obj *inst;
|
||||
auto vk_inst = unwrap_instance(instance, &inst);
|
||||
(void)unwrap_instance(instance, &inst);
|
||||
VkLayerInstanceDispatchTable* pTable = &inst->layer_disp;
|
||||
|
||||
// EXT_debug_report
|
||||
|
Loading…
Reference in New Issue
Block a user