mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-02-25 13:05:04 +00:00
[mlir] Emit errors if global constructors are found within lib/
Summary: This avoids adding any additional global constructors, like cl::opt. There is a temporary exception on IR/, which has a few cl::opts that require a bit of plumbing to remove. Differential Revision: https://reviews.llvm.org/D77824
This commit is contained in:
parent
ebf22a4935
commit
3db57d14ec
@ -1,3 +1,6 @@
|
||||
# Enable errors for any global constructors.
|
||||
add_flag_if_supported("-Werror=global-constructors" WERROR_GLOBAL_CONSTRUCTOR)
|
||||
|
||||
add_subdirectory(Analysis)
|
||||
add_subdirectory(Conversion)
|
||||
add_subdirectory(Dialect)
|
||||
|
@ -1,3 +1,6 @@
|
||||
# TODO: Remove the need for global constructors within IR/
|
||||
add_flag_if_supported("-Wno-global-constructors" WNO_GLOBAL_CONSTRUCTOR_MLIR_IR)
|
||||
|
||||
file(GLOB globbed *.c *.cpp)
|
||||
add_mlir_library(MLIRIR
|
||||
${globbed}
|
||||
|
Loading…
x
Reference in New Issue
Block a user