blob: 03a15fc3f79b8cb24b54bd90457b003f07921085 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
|
include(RunCMake)
run_cmake(no_parameters)
run_cmake(unknown_meta_operation)
foreach(command IN ITEMS
"function" "ENDFUNCTION"
"macro" "endMACRO"
"if" "elseif" "else" "endif"
"while" "endwhile"
"foreach" "endforeach"
)
message(STATUS "Running call_invalid_command for ${command}...")
run_cmake_with_options(call_invalid_command -Dcommand=${command})
endforeach()
run_cmake(call_valid_command)
run_cmake(call_double_evaluation)
run_cmake(call_expanded_command)
run_cmake(call_expanded_command_and_arguments)
run_cmake(call_expanded_command_with_explicit_argument)
run_cmake(call_expand_command_name)
run_cmake(call_expand_function_name)
run_cmake(call_message)
run_cmake(call_message_fatal_error)
run_cmake(call_no_parameters)
run_cmake(call_preserve_arguments)
run_cmake(call_unknown_function)
run_cmake(eval_expand_command_name)
run_cmake(eval_expanded_command_and_arguments)
run_cmake(eval_extra_parameters_between_eval_and_code)
run_cmake(eval_message)
run_cmake(eval_message_fatal_error)
run_cmake(eval_no_code)
run_cmake(eval_no_parameters)
run_cmake(eval_variable_outside_message)
run_cmake(defer_call)
run_cmake(defer_call_add_subdirectory)
run_cmake(defer_call_enable_language)
run_cmake(defer_call_ids)
foreach(command IN ITEMS
"function" "endfunction"
"macro" "endmacro"
"if" "elseif" "else" "endif"
"while" "endwhile"
"foreach" "endforeach"
"return"
)
message(STATUS "Running defer_call_invalid_command for ${command}...")
run_cmake_with_options(defer_call_invalid_command -Dcommand=${command})
endforeach()
run_cmake(defer_call_invalid_directory)
run_cmake(defer_call_error)
run_cmake(defer_call_missing_directory)
run_cmake(defer_call_policy_PUSH)
run_cmake(defer_call_syntax_error)
run_cmake_with_options(defer_call_trace --trace-expand)
run_cmake_with_options(defer_call_trace_json --trace --trace-format=json-v1)
run_cmake(defer_cancel_call_unknown_argument)
run_cmake(defer_cancel_call_invalid_directory)
run_cmake(defer_cancel_call_id)
run_cmake(defer_cancel_call_id_var)
run_cmake(defer_directory_empty)
run_cmake(defer_directory_missing)
run_cmake(defer_directory_multiple)
run_cmake(defer_id_empty)
run_cmake(defer_id_missing)
run_cmake(defer_id_multiple)
run_cmake(defer_id_var_empty)
run_cmake(defer_id_var_missing)
run_cmake(defer_id_var_multiple)
run_cmake(defer_get_call_ids_missing_var)
run_cmake(defer_get_call_ids_too_many_args)
run_cmake(defer_get_call_ids_invalid_directory)
run_cmake(defer_get_call_ids_id)
run_cmake(defer_get_call_ids_id_var)
run_cmake(defer_get_call_missing_id)
run_cmake(defer_get_call_missing_var)
run_cmake(defer_get_call_too_many_args)
run_cmake(defer_get_call_id_empty)
run_cmake(defer_get_call_unknown_argument)
run_cmake(defer_get_call_id)
run_cmake(defer_get_call_id_var)
run_cmake(defer_missing_arg)
run_cmake(defer_missing_call)
run_cmake(defer_unknown_option)
# Default log level
run_cmake_command(
get_message_log_level_none
${CMAKE_COMMAND}
-P ${RunCMake_SOURCE_DIR}/get_message_log_level.cmake
)
# Log level from cache
run_cmake_command(
get_message_log_level_cache
${CMAKE_COMMAND}
-DCMAKE_MESSAGE_LOG_LEVEL=TRACE
-P ${RunCMake_SOURCE_DIR}/get_message_log_level.cmake
)
# Log level from regular variable
run_cmake_command(
get_message_log_level_var
${CMAKE_COMMAND}
-DNEW_LOG_LEVEL=TRACE
-P ${RunCMake_SOURCE_DIR}/get_message_log_level.cmake
)
# Log level from command line
run_cmake_command(
get_message_log_level_cli
${CMAKE_COMMAND}
--log-level=DEBUG
-P ${RunCMake_SOURCE_DIR}/get_message_log_level.cmake
)
# Log level from command line, it has higher priority over a cache variable
run_cmake_command(
get_message_log_level_cli_and_cache
${CMAKE_COMMAND}
--log-level=DEBUG
-DCMAKE_MESSAGE_LOG_LEVEL=TRACE
-P ${RunCMake_SOURCE_DIR}/get_message_log_level.cmake
)
# Log level from command line, it has higher priority over a regular variable
run_cmake_command(
get_message_log_level_cli_and_var
${CMAKE_COMMAND}
--log-level=DEBUG
-DNEW_LOG_LEVEL=TRACE
-P ${RunCMake_SOURCE_DIR}/get_message_log_level.cmake
)
# Log level from variable, it has higher priority over a cache variable
run_cmake_command(
get_message_log_level_var_and_cache
${CMAKE_COMMAND}
-DNEW_LOG_LEVEL=DEBUG
-DCMAKE_MESSAGE_LOG_LEVEL=TRACE
-P ${RunCMake_SOURCE_DIR}/get_message_log_level.cmake
)
|