obslua: Ignore maybe-unitialized warning with SWIG and GCC

Only with SWIG version earlier than 4.1 because it is fixed upstream.
https://github.com/swig/swig/commit/fa2f9dc5da405586ba3857dd515ae84b7868819f
This commit is contained in:
tytan652
2022-07-18 14:56:04 +02:00
committed by Ryan Foster
parent 2d7e854476
commit f147be2d68
+4
View File
@@ -61,4 +61,8 @@ elseif(OS_MACOS)
MACHO_COMPATIBILITY_VERSION 0)
endif()
if(CMAKE_C_COMPILER_ID STREQUAL "GNU" AND SWIG_VERSION VERSION_LESS "4.1")
target_compile_options(obslua PRIVATE -Wno-maybe-uninitialized)
endif()
setup_script_plugin_target(obslua)