mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-03-16 16:32:47 +00:00
Merge bitcoin/bitcoin#33144: build: Set AUTHOR_WARNING on warnings
fa6497ba71e9573d341c1c051af09b3ec2fc8d74 build: Set AUTHOR_WARNING on warnings (MarcoFalke)
Pull request description:
Now that the cmake setting `-Werror=dev` is set since commit 6a13a6106e3c1ebe95ba6430184d6260a7b942bd for the CI, guix and the dev cmake preset, it could make sense to notify developers about any warnings.
So do that with a single `AUTHOR_WARNING`.
This can be tested by introducing a bug, like:
```diff
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6017775fa7..5610e03c66 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -589,7 +589,7 @@ set(Python3_FIND_FRAMEWORK LAST CACHE STRING "")
# improves compatibility with Python version managers that use shims.
set(Python3_FIND_UNVERSIONED_NAMES FIRST CACHE STRING "")
mark_as_advanced(Python3_FIND_FRAMEWORK Python3_FIND_UNVERSIONED_NAMES)
-find_package(Python3 3.10 COMPONENTS Interpreter)
+find_package(Python3 3.210 COMPONENTS Interpreter)
if(NOT TARGET Python3::Interpreter)
list(APPEND configure_warnings
"Minimum required Python not found."
```
Fixes https://github.com/bitcoin/bitcoin/issues/31476.
ACKs for top commit:
l0rinc:
ACK fa6497ba71e9573d341c1c051af09b3ec2fc8d74
purpleKarrot:
ACK fa6497ba71e9573d341c1c051af09b3ec2fc8d74
stickies-v:
ACK fa6497ba71e9573d341c1c051af09b3ec2fc8d74
hebasto:
ACK fa6497ba71e9573d341c1c051af09b3ec2fc8d74, this effectively allows us to use `-Werror=dev` to automatically catch any warning.
sedited:
ACK fa6497ba71e9573d341c1c051af09b3ec2fc8d74
Tree-SHA512: df3b7fa88451527d6a950bd6ebe46e96d1d2f6447c2b53cbe26c6ece0b63a41663a0accfc0ee20c03bc40328363d46f0e7ad88aab1be9b383ad7ff2621363a30
This commit is contained in:
commit
e19df67332
@ -690,6 +690,7 @@ if(configure_warnings)
|
||||
message(WARNING "${warning}")
|
||||
endforeach()
|
||||
message(" ******\n")
|
||||
message(AUTHOR_WARNING "Warnings have been encountered!")
|
||||
endif()
|
||||
|
||||
# We want all build properties to be encapsulated properly.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user