File tree Expand file tree Collapse file tree 1 file changed +13
-6
lines changed Expand file tree Collapse file tree 1 file changed +13
-6
lines changed Original file line number Diff line number Diff line change @@ -80,13 +80,20 @@ add_custom_command(
80
80
)
81
81
unset (qm_files)
82
82
83
- set_property (
84
- SOURCE
85
- ${CMAKE_CURRENT_BINARY_DIR} /qrc_bitcoin.cpp
86
- ${CMAKE_CURRENT_BINARY_DIR} /qrc_bitcoin_locale.cpp
87
- PROPERTY COMPILE_OPTIONS
88
- -Wno-trailing-whitespace
83
+ include (TryAppendCXXFlags)
84
+ try_append_cxx_flags("-Wtrailing-whitespace"
85
+ RESULT_VAR cxx_supports_w_trailing_whitespace
86
+ SKIP_LINK
89
87
)
88
+ if (cxx_supports_w_trailing_whitespace)
89
+ set_property (
90
+ SOURCE
91
+ ${CMAKE_CURRENT_BINARY_DIR} /qrc_bitcoin.cpp
92
+ ${CMAKE_CURRENT_BINARY_DIR} /qrc_bitcoin_locale.cpp
93
+ PROPERTY COMPILE_OPTIONS
94
+ -Wno-trailing-whitespace
95
+ )
96
+ endif ()
90
97
91
98
# The bitcoinqt sources have to include headers in
92
99
# order to parse them to collect translatable strings.
You can’t perform that action at this time.
0 commit comments