mirror of
https://github.com/monero-project/monero.git
synced 2026-07-28 14:47:15 -07:00
trezor: suppress generated protobuf deprecation warnings
This commit is contained in:
@@ -161,6 +161,15 @@ if(Protobuf_FOUND AND USE_DEVICE_TREZOR)
|
||||
file(READ "${_proto_out_dir}/${file}" file_content)
|
||||
string(REPLACE "PROTOBUF_DEPRECATED_ENUM" ""
|
||||
updated_content "${file_content}")
|
||||
string(PREPEND updated_content
|
||||
"#if defined(__GNUC__)\n"
|
||||
"#pragma GCC diagnostic push\n"
|
||||
"#pragma GCC diagnostic ignored \"-Wdeprecated-declarations\"\n"
|
||||
"#endif\n")
|
||||
string(APPEND updated_content
|
||||
"#if defined(__GNUC__)\n"
|
||||
"#pragma GCC diagnostic pop\n"
|
||||
"#endif\n")
|
||||
file(WRITE "${_proto_out_dir}/${file}" "${updated_content}")
|
||||
endforeach ()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user