Skip to content

Commit 7f4d0a1

Browse files
committed
Sync error messages
1 parent a7083c9 commit 7f4d0a1

35 files changed

+90
-96
lines changed

cmake/Zend/cmake/Fibers.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ block()
192192
message(CHECK_FAIL "no")
193193
message(
194194
FATAL_ERROR
195-
"Fibers are not available on this platform, ucontext.h not found"
195+
"Fibers are not available on this platform, <ucontext.h> not found."
196196
)
197197
endif()
198198
message(CHECK_PASS "yes, ucontext")

cmake/cmake/ConfigureChecks.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -619,7 +619,7 @@ php_search_libraries(
619619
TARGET php_config INTERFACE
620620
)
621621
if(NOT HAVE_INET_NTOP)
622-
message(FATAL_ERROR "Cannot find inet_ntop which is required.")
622+
message(FATAL_ERROR "Cannot find 'inet_ntop()' which is required.")
623623
endif()
624624

625625
# The inet_pton() is mostly in C library (Solaris 11.4, illumos...)
@@ -787,7 +787,7 @@ endif()
787787
# Check GCOV.
788788
if(PHP_GCOV)
789789
if(NOT CMAKE_C_COMPILER_ID STREQUAL "GNU")
790-
message(FATAL_ERROR "GCC is required for using PHP_GCOV='ON'")
790+
message(FATAL_ERROR "GCC is required for using PHP_GCOV='ON'.")
791791
endif()
792792

793793
if(CMAKE_C_COMPILER_LAUNCHER MATCHES "ccache")

cmake/cmake/Flags.cmake

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ endif()
182182
if(PHP_MEMORY_SANITIZER AND PHP_ADDRESS_SANITIZER)
183183
message(
184184
FATAL_ERROR
185-
"MemorySanitizer and AddressSanitizer are mutually exclusive"
185+
"MemorySanitizer and AddressSanitizer are mutually exclusive."
186186
)
187187
endif()
188188

@@ -228,7 +228,7 @@ if(PHP_MEMORY_SANITIZER)
228228
message(CHECK_PASS "Success")
229229
else()
230230
message(CHECK_FAIL "Failed")
231-
message(FATAL_ERROR "MemorySanitizer is not available")
231+
message(FATAL_ERROR "MemorySanitizer is not available.")
232232
endif()
233233
endif()
234234

@@ -276,7 +276,7 @@ if(PHP_ADDRESS_SANITIZER)
276276
message(CHECK_PASS "Success")
277277
else()
278278
message(CHECK_FAIL "Failed")
279-
message(FATAL_ERROR "AddressSanitizer is not available")
279+
message(FATAL_ERROR "AddressSanitizer is not available.")
280280
endif()
281281
endif()
282282

@@ -411,7 +411,7 @@ if(PHP_UNDEFINED_SANITIZER)
411411
message(CHECK_PASS "Success")
412412
else()
413413
message(CHECK_FAIL "Failed")
414-
message(FATAL_ERROR "UndefinedBehaviorSanitizer is not available")
414+
message(FATAL_ERROR "UndefinedBehaviorSanitizer is not available.")
415415
endif()
416416
endif()
417417

cmake/cmake/Requirements.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ if(CMAKE_C_COMPILER_ID STREQUAL "SunPro")
1616
FATAL_ERROR
1717
"Using unsupported compiler: Oracle Developer Studio.\n"
1818
"Please, install a compatible C compiler such as GNU C or Clang. You can "
19-
"set CMAKE_C_COMPILER (and CMAKE_CXX_COMPILER) to the compiler path on the "
20-
"system."
19+
"set 'CMAKE_C_COMPILER' (and 'CMAKE_CXX_COMPILER') variables to the "
20+
"compiler path on the system."
2121
)
2222
endif()
2323

@@ -40,7 +40,7 @@ cmake_pop_check_state()
4040

4141
if(PHP_IS_EBCDIC)
4242
message(CHECK_FAIL "EBCDIC")
43-
message(FATAL_ERROR "PHP does not support EBCDIC targets")
43+
message(FATAL_ERROR "PHP does not support EBCDIC targets.")
4444
else()
4545
message(CHECK_PASS "ASCII")
4646
endif()

cmake/cmake/modules/FindCclient.cmake

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -296,25 +296,23 @@ if(Cclient_INCLUDE_DIR AND Cclient_LIBRARY)
296296
string(
297297
APPEND
298298
_reason
299-
"Sanity check failed: utf8_mime2text() has new signature, but "
300-
"U8T_CANONICAL is missing. This should not happen. Check CMake logs for "
301-
"additional information. "
299+
"Sanity check failed: 'utf8_mime2text()' has new signature, but "
300+
"'U8T_CANONICAL' is missing. This should not happen. "
302301
)
303302
elseif(NOT HAVE_NEW_MIME2TEXT AND _HAVE_U8T_DECOMPOSE)
304303
string(
305304
APPEND
306305
_reason
307-
"Sanity check failed: utf8_mime2text() has old signature, but "
308-
"U8T_CANONICAL is present. This should not happen. Check CMake logs for "
309-
"additional information."
306+
"Sanity check failed: 'utf8_mime2text()' has old signature, but "
307+
"'U8T_CANONICAL' is present. This should not happen. "
310308
)
311309
else()
312310
set(_cclient_sanity_check_2 TRUE)
313311
endif()
314312
endif()
315313

316314
if(NOT _cclient_sanity_check_2)
317-
string(APPEND _reason "Sanity check failed: mail_newbody() not found. ")
315+
string(APPEND _reason "Sanity check failed: 'mail_newbody()' not found. ")
318316
endif()
319317

320318
################################################################################

cmake/cmake/modules/FindDTrace.cmake

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -138,27 +138,27 @@ function(dtrace_target)
138138
)
139139

140140
if(parsed_UNPARSED_ARGUMENTS)
141-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
141+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
142142
endif()
143143

144144
if(parsed_KEYWORDS_MISSING_VALUES)
145145
message(FATAL_ERROR "Missing values for: ${parsed_KEYWORDS_MISSING_VALUES}")
146146
endif()
147147

148148
if(NOT ARGV0)
149-
message(FATAL_ERROR "dtrace_target expects a target name")
149+
message(FATAL_ERROR "${CMAKE_CURRENT_FUNCTION} expects a target name.")
150150
endif()
151151

152152
if(NOT parsed_INPUT)
153-
message(FATAL_ERROR "dtrace_target expects an input filename")
153+
message(FATAL_ERROR "${CMAKE_CURRENT_FUNCTION} expects an input filename.")
154154
endif()
155155

156156
if(NOT parsed_HEADER)
157-
message(FATAL_ERROR "dtrace_target expects a header filename")
157+
message(FATAL_ERROR "${CMAKE_CURRENT_FUNCTION} expects a header filename.")
158158
endif()
159159

160160
if(NOT parsed_SOURCES)
161-
message(FATAL_ERROR "dtrace_target expects a list of source files")
161+
message(FATAL_ERROR "${CMAKE_CURRENT_FUNCTION} expects source files.")
162162
endif()
163163

164164
if(NOT IS_ABSOLUTE "${parsed_INPUT}")

cmake/cmake/modules/FindMC.cmake

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,23 +160,26 @@ function(mc_target)
160160
)
161161

162162
if(parsed_UNPARSED_ARGUMENTS)
163-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
163+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
164164
endif()
165165

166166
if(parsed_KEYWORDS_MISSING_VALUES)
167167
message(FATAL_ERROR "Missing values for: ${parsed_KEYWORDS_MISSING_VALUES}")
168168
endif()
169169

170170
if(NOT parsed_NAME)
171-
message(FATAL_ERROR "mc_target expects a target name")
171+
message(FATAL_ERROR "${CMAKE_CURRENT_FUNCTION} expects a target name.")
172172
endif()
173173

174174
if(NOT parsed_INPUT)
175-
message(FATAL_ERROR "mc_target expects an input filename")
175+
message(FATAL_ERROR "${CMAKE_CURRENT_FUNCTION} expects an input filename.")
176176
endif()
177177

178178
if(NOT MC_FOUND)
179-
message(WARNING "[MC][${parsed_NAME}] Message compiler is missing. Skipping")
179+
message(
180+
WARNING
181+
"[MC][${parsed_NAME}] Message compiler is missing. Skipping."
182+
)
180183
return()
181184
endif()
182185

cmake/cmake/modules/PHP/AddCustomCommand.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ function(php_add_custom_command)
6969
)
7070

7171
if(parsed_UNPARSED_ARGUMENTS)
72-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
72+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
7373
endif()
7474

7575
if(NOT ARGV0)

cmake/cmake/modules/PHP/CheckAttribute.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,11 +92,11 @@ function(_php_check_attribute what attribute result)
9292
)
9393

9494
if(parsed_UNPARSED_ARGUMENTS)
95-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
95+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
9696
endif()
9797

9898
if(NOT ARGC EQUAL 3)
99-
message(FATAL_ERROR "Missing arguments")
99+
message(FATAL_ERROR "Missing arguments.")
100100
endif()
101101

102102
if(NOT what MATCHES "^(function|variable)$")
@@ -118,7 +118,7 @@ function(_php_check_attribute what attribute result)
118118
cmake_language(CALL _php_check_attribute_get_${what}_code ${attribute} code)
119119

120120
if(NOT code)
121-
message(FATAL_ERROR "Unsupported attribute '${attribute}'")
121+
message(FATAL_ERROR "Unsupported attribute '${attribute}'.")
122122
endif()
123123

124124
check_source_compiles(C "${code}" ${result})

cmake/cmake/modules/PHP/CheckCompilerFlag.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,11 @@ function(php_check_compiler_flag lang flag result)
5858
)
5959

6060
if(parsed_UNPARSED_ARGUMENTS)
61-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
61+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
6262
endif()
6363

6464
if(NOT ARGC EQUAL 3)
65-
message(FATAL_ERROR "Missing arguments")
65+
message(FATAL_ERROR "Missing arguments.")
6666
endif()
6767

6868
if(NOT CMAKE_REQUIRED_QUIET)

cmake/cmake/modules/PHP/ConfigureFile.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,13 +57,13 @@ function(_php_configure_file_parse_variables)
5757
)
5858

5959
if(parsed_UNPARSED_ARGUMENTS)
60-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
60+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
6161
endif()
6262

6363
if(NOT ARGV0)
6464
message(
6565
FATAL_ERROR
66-
"${CMAKE_CURRENT_FUNCTION} expects 1st argument"
66+
"${CMAKE_CURRENT_FUNCTION} expects 1st argument."
6767
)
6868
endif()
6969

@@ -153,7 +153,7 @@ function(php_configure_file)
153153
)
154154

155155
if(parsed_UNPARSED_ARGUMENTS)
156-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
156+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
157157
endif()
158158

159159
if(NOT parsed_INPUT AND NOT parsed_CONTENT)

cmake/cmake/modules/PHP/Extensions.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ function(_php_extensions_sort)
142142
)
143143

144144
if(parsed_UNPARSED_ARGUMENTS)
145-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
145+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
146146
endif()
147147

148148
set(result ${ARGV0})

cmake/cmake/modules/PHP/Install.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ function(_php_install_set_absolute_special var)
5959
else()
6060
message(
6161
FATAL_ERROR
62-
"CMAKE_INSTALL_${var} is not a special-case GNU standard variable")
62+
"CMAKE_INSTALL_${var} is not a special-case GNU standard variable.")
6363
endif()
6464

6565
if(IS_ABSOLUTE "${CMAKE_INSTALL_${var}}")

cmake/cmake/modules/PHP/PkgConfigGenerator.cmake

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,8 @@ function(_pkgconfig_parse_variables variables)
6767
if(NOT modulus EQUAL 0)
6868
message(
6969
FATAL_ERROR
70-
"The keyword VARIABLES must be a list of pairs - variable-name and "
71-
"value (it must contain an even number of items)."
70+
"The keyword VARIABLES must be a list of pairs - variable-name and value "
71+
"(it must contain an even number of items)."
7272
)
7373
endif()
7474

@@ -138,19 +138,25 @@ function(pkgconfig_generate_pc)
138138
)
139139

140140
if(parsed_UNPARSED_ARGUMENTS)
141-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
141+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
142142
endif()
143143

144144
if(parsed_TARGET AND NOT TARGET ${parsed_TARGET})
145-
message(FATAL_ERROR "${parsed_TARGET} is not a target")
145+
message(FATAL_ERROR "${parsed_TARGET} is not a target.")
146146
endif()
147147

148148
if(NOT ARGV0)
149-
message(FATAL_ERROR "pkgconfig_generate_pc expects a template file name")
149+
message(
150+
FATAL_ERROR
151+
"${CMAKE_CURRENT_FUNCTION} expects a template file name."
152+
)
150153
endif()
151154

152155
if(NOT ARGV1)
153-
message(FATAL_ERROR "pkgconfig_generate_pc expects an output file name")
156+
message(
157+
FATAL_ERROR
158+
"${CMAKE_CURRENT_FUNCTION} expects an output file name."
159+
)
154160
endif()
155161

156162
set(template "${ARGV0}")

cmake/cmake/modules/PHP/SearchLibraries.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -182,11 +182,11 @@ function(php_search_libraries)
182182
)
183183

184184
if(parsed_UNPARSED_ARGUMENTS)
185-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
185+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
186186
endif()
187187

188188
if(NOT parsed_HEADERS)
189-
message(FATAL_ERROR "php_search_libraries: missing HEADERS")
189+
message(FATAL_ERROR "${CMAKE_CURRENT_FUNCTION}: missing HEADERS")
190190
endif()
191191

192192
set(symbol ${ARGV0})
@@ -220,7 +220,7 @@ function(php_search_libraries)
220220
list(GET parsed_TARGET 0 target)
221221

222222
if(NOT TARGET ${target})
223-
message(FATAL_ERROR "Bad TARGET arguments: ${target} is not a target")
223+
message(FATAL_ERROR "Bad TARGET arguments: ${target} is not a target.")
224224
endif()
225225

226226
list(LENGTH parsed_TARGET length)

cmake/cmake/modules/PHP/Set.cmake

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -323,14 +323,14 @@ endfunction()
323323
# Validate parsed arguments.
324324
function(_php_set_validate_arguments arguments)
325325
if(parsed_UNPARSED_ARGUMENTS)
326-
message(FATAL_ERROR "Bad arguments: ${parsed_UNPARSED_ARGUMENTS}")
326+
message(FATAL_ERROR "Unrecognized arguments: ${parsed_UNPARSED_ARGUMENTS}")
327327
endif()
328328

329329
if(
330330
NOT DEFINED parsed_VALUE
331331
AND (NOT DEFINED parsed_CHOICES OR NOT parsed_TYPE STREQUAL "STRING")
332332
)
333-
message(FATAL_ERROR "Missing VALUE argument")
333+
message(FATAL_ERROR "Missing VALUE argument.")
334334
endif()
335335

336336
if(NOT parsed_TYPE)
@@ -340,22 +340,22 @@ function(_php_set_validate_arguments arguments)
340340
endif()
341341

342342
if(DEFINED parsed_CHOICES AND NOT parsed_TYPE STREQUAL "STRING")
343-
message(FATAL_ERROR "CHOICES argument can be only used with TYPE STRING")
343+
message(FATAL_ERROR "CHOICES argument can be only used with TYPE STRING.")
344344
endif()
345345

346346
list(FIND arguments ELSE_VALUE elseValueIndex)
347347
if(NOT DEFINED parsed_IF AND NOT elseValueIndex EQUAL -1)
348-
message(FATAL_ERROR "Redundant ELSE_VALUE argument without IF condition")
348+
message(FATAL_ERROR "Redundant ELSE_VALUE argument without IF condition.")
349349
elseif(
350350
DEFINED parsed_IF
351351
AND NOT DEFINED parsed_ELSE_VALUE
352352
AND NOT elseValueIndex EQUAL -1
353353
)
354-
message(FATAL_ERROR "Missing ELSE_VALUE argument")
354+
message(FATAL_ERROR "Missing ELSE_VALUE argument.")
355355
endif()
356356

357357
if(NOT DEFINED parsed_DOC)
358-
message(FATAL_ERROR "Missing DOC argument")
358+
message(FATAL_ERROR "Missing DOC argument.")
359359
endif()
360360
endfunction()
361361

cmake/ext/bz2/CMakeLists.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,7 @@ if(TARGET BZip2::BZip2)
8989
message(
9090
FATAL_ERROR
9191
"BZip2 package is not working as expected. The bz2 extension requires "
92-
"BZip2 library (libbzip2) version ${PHP_BZIP2_MIN_VERSION} or later. "
93-
"Please see the CMake logs."
92+
"BZip2 library (libbzip2) version ${PHP_BZIP2_MIN_VERSION} or later."
9493
)
9594
endif()
9695
endif()

cmake/ext/curl/CMakeLists.txt

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -172,11 +172,7 @@ if(TARGET CURL::libcurl)
172172
)
173173

174174
if(NOT HAVE_CURL_EASY_PERFORM)
175-
message(
176-
FATAL_ERROR
177-
"The curl_easy_perform() couldn't be found. Please check logs for more "
178-
"information."
179-
)
175+
message(FATAL_ERROR "The 'curl_easy_perform()' couldn't be found.")
180176
endif()
181177
endif()
182178

0 commit comments

Comments
 (0)