mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-01 11:22:21 -06:00
This option only has an effect if at least one of the other LOG_<step> options is enabled. If an error occurs for a step which has logging to file enabled, that step's output will be printed to the console. For cases where a large amount of output is recorded, just the end of that output may be printed to the console.
21 lines
590 B
CMake
21 lines
590 B
CMake
include(ExternalProject)
|
|
|
|
set(dummyOutput [[
|
|
This is some dummy output with some long lines to ensure formatting is preserved
|
|
Including lines with leading spaces
|
|
|
|
And also blank lines
|
|
]])
|
|
|
|
ExternalProject_Add(FailsWithOutput
|
|
SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}
|
|
CONFIGURE_COMMAND ""
|
|
BUILD_COMMAND ${CMAKE_COMMAND} -E echo ${dummyOutput}
|
|
COMMAND ${CMAKE_COMMAND} -E env # missing command, forces fail
|
|
TEST_COMMAND ""
|
|
INSTALL_COMMAND ""
|
|
LOG_BUILD YES
|
|
LOG_OUTPUT_ON_FAILURE YES
|
|
USES_TERMINAL_BUILD YES
|
|
)
|