Skip to content

Commit c90f44a

Browse files
committed
build: use CMAKE_COMMAND instead of hardcoded cmake
This ensures that the cmake used to build is the cmake invoked when running the custom command. In the case that `cmake` is not in PATH, you would fail to invoke the command, failing the build.
1 parent 4ac77b7 commit c90f44a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -230,8 +230,8 @@ endif()
230230
# So for now, make a copy so we don't have to do a coordinated commit across
231231
# all the swift projects to change this assumption.
232232
add_custom_command(TARGET dispatch POST_BUILD
233-
COMMAND cmake -E make_directory .libs
234-
COMMAND cmake -E copy $<TARGET_FILE:dispatch> .libs
233+
COMMAND ${CMAKE_COMMAND} -E make_directory .libs
234+
COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:dispatch> .libs
235235
COMMENT "Copying libdispatch to .libs")
236236

237237
install(TARGETS

0 commit comments

Comments
 (0)