From: Jonas Devlieghere Date: Tue, 31 Jan 2023 23:33:46 +0000 (-0800) Subject: [lldb] Use ${CMAKE_COMMAND} -E remove instead of remove_directory X-Git-Tag: upstream/17.0.6~18993 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9f8fd57cb6638f8137d82b1ceb02845626816b4f;p=platform%2Fupstream%2Fllvm.git [lldb] Use ${CMAKE_COMMAND} -E remove instead of remove_directory We no longer need to remove a directory downstream and also contrary to my previous observations, remove_directory isn't sufficient to remove a regular file. Differential revision: https://reviews.llvm.org/D143024 --- diff --git a/lldb/cmake/modules/AddLLDB.cmake b/lldb/cmake/modules/AddLLDB.cmake index a5be4af..251c2957 100644 --- a/lldb/cmake/modules/AddLLDB.cmake +++ b/lldb/cmake/modules/AddLLDB.cmake @@ -246,10 +246,8 @@ function(lldb_add_to_buildtree_lldb_framework name subdir) # Create a custom target to remove the copy again from LLDB.framework in the # build tree. - # Intentionally use remove_directory because the target can be a either a - # file or directory and using remove_directory is harmless for files. add_custom_target(${name}-cleanup - COMMAND ${CMAKE_COMMAND} -E remove_directory ${copy_dest} + COMMAND ${CMAKE_COMMAND} -E remove ${copy_dest} COMMENT "Removing ${name} from LLDB.framework") add_dependencies(lldb-framework-cleanup ${name}-cleanup)