Skip to content

Commit 25277a1

Browse files
committed
Fix nits
1 parent b97a3fd commit 25277a1

File tree

2 files changed

+15
-4
lines changed

2 files changed

+15
-4
lines changed

cmake/cmake/modules/FindRE2C.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ re2c_target(
6262
* `<input>` - The re2c template file input. Relative source file path is
6363
interpreted as being relative to the current source directory.
6464
* `<output>` - The output file. Relative output file path is interpreted as
65-
being relative to the current source directory.
65+
being relative to the current binary directory.
6666
* `HEADER` - Generate a <header> file. Relative header file path is interpreted
6767
as being relative to the current binary directory.
6868
* `OPTIONS` - List of additional options to pass to re2c command-line tool.

cmake/cmake/modules/PHP/ConfigureFile.cmake

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,15 @@ php_configure_file(
1818
)
1919
```
2020
21-
* `VARIABLES`
21+
* `INPUT` or `CONTENT` specify the input template (either a file or a content
22+
string). Relative <template-file> is interpreted as being relative to the
23+
current source directory.
2224
23-
Pairs of variable names and values. Variable values support generator
24-
expressions.
25+
* `OUTPUT` specifies the output file. Relative file path is interpreted as being
26+
relative to the current binary directory.
27+
28+
* `VARIABLES` represent the pairs of variable names and values. Variable values
29+
support generator expressions.
2530
2631
The `$<INSTALL_PREFIX>` generator expression can be used in variable values,
2732
which is replaced with installation prefix either set via the
@@ -155,6 +160,12 @@ function(php_configure_file)
155160
"${CMAKE_CURRENT_FUNCTION} expects either INPUT or CONTENT keyword to "
156161
"specify template."
157162
)
163+
elseif(parsed_INPUT AND parsed_CONTENT)
164+
message(
165+
FATAL_ERROR
166+
"${CMAKE_CURRENT_FUNCTION} requires either INPUT or CONTENT keyword. To "
167+
"specify input template only one is required."
168+
)
158169
endif()
159170

160171
if(NOT parsed_OUTPUT)

0 commit comments

Comments
 (0)