find_package: Test that REQUIRED aborts processing correctly
Verify that the command produces a FATAL_ERROR if and only if the missing package is REQUIRED.
This commit is contained in:
parent
c91a54db37
commit
c5ae733166
|
@ -11,3 +11,9 @@ CMake Warning at MissingConfig.cmake:1 \(find_package\):
|
|||
been installed.
|
||||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)
|
||||
|
||||
|
||||
CMake Warning at MissingConfig.cmake:2 \(message\):
|
||||
This warning must be reachable.
|
||||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)$
|
||||
|
|
|
@ -1 +1,2 @@
|
|||
find_package(NotHere CONFIG)
|
||||
message(WARNING "This warning must be reachable.")
|
||||
|
|
|
@ -10,4 +10,4 @@ CMake Error at MissingConfigRequired.cmake:1 \(find_package\):
|
|||
"NotHere" provides a separate development package or SDK, be sure it has
|
||||
been installed.
|
||||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)
|
||||
CMakeLists.txt:3 \(include\)$
|
||||
|
|
|
@ -1 +1,2 @@
|
|||
find_package(NotHere CONFIG REQUIRED)
|
||||
message(FATAL_ERROR "This error must not be reachable.")
|
||||
|
|
|
@ -19,3 +19,8 @@ CMake Warning \(dev\) at MissingModule.cmake:1 \(find_package\):
|
|||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)
|
||||
This warning is for project developers. Use -Wno-dev to suppress it.
|
||||
|
||||
CMake Warning at MissingModule.cmake:2 \(message\):
|
||||
This warning must be reachable.
|
||||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)$
|
||||
|
|
|
@ -1 +1,2 @@
|
|||
find_package(NotHere MODULE)
|
||||
message(WARNING "This warning must be reachable.")
|
||||
|
|
|
@ -18,4 +18,4 @@ CMake Warning \(dev\) at MissingModuleRequired.cmake:1 \(find_package\):
|
|||
|
||||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)
|
||||
This warning is for project developers. Use -Wno-dev to suppress it.
|
||||
This warning is for project developers. Use -Wno-dev to suppress it.$
|
||||
|
|
|
@ -1 +1,2 @@
|
|||
find_package(NotHere MODULE REQUIRED)
|
||||
message(FATAL_ERROR "This error must not be reachable.")
|
||||
|
|
|
@ -15,3 +15,9 @@ CMake Warning at MissingNormal.cmake:1 \(find_package\):
|
|||
been installed.
|
||||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)
|
||||
|
||||
|
||||
CMake Warning at MissingNormal.cmake:2 \(message\):
|
||||
This warning must be reachable.
|
||||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)$
|
||||
|
|
|
@ -1 +1,2 @@
|
|||
find_package(NotHere)
|
||||
message(WARNING "This warning must be reachable.")
|
||||
|
|
|
@ -14,4 +14,4 @@ CMake Error at MissingNormalRequired.cmake:1 \(find_package\):
|
|||
"NotHere" provides a separate development package or SDK, be sure it has
|
||||
been installed.
|
||||
Call Stack \(most recent call first\):
|
||||
CMakeLists.txt:3 \(include\)
|
||||
CMakeLists.txt:3 \(include\)$
|
||||
|
|
|
@ -1 +1,2 @@
|
|||
find_package(NotHere REQUIRED)
|
||||
message(FATAL_ERROR "This error must not be reachable.")
|
||||
|
|
Loading…
Reference in New Issue