From 06b7561e785afc9ad0bb66b789a450b96605fd97 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 19 Feb 2018 21:10:16 +0100 Subject: [PATCH] build: remove contents of build/runtime/doc/* surgically (#8024) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Only remove the directory contents. If the directory itself is removed, then `sudo make install` creates a root-owned …/doc/ directory. That breaks the next non-root build. This was an accident of 0b1904d835a2. Note: the following does not work, because it misses renamed help files (which would no longer be in the build-tree definition) COMMAND ${CMAKE_COMMAND} -E remove ${BUILDDOCFILES} ${GENERATED_HELP_TAGS} --- runtime/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/CMakeLists.txt b/runtime/CMakeLists.txt index 0172f630cd..b3907fdf37 100644 --- a/runtime/CMakeLists.txt +++ b/runtime/CMakeLists.txt @@ -71,7 +71,7 @@ foreach(DF ${DOCFILES}) endforeach() add_custom_target(helptags - COMMAND ${CMAKE_COMMAND} -E remove_directory ${GENERATED_RUNTIME_DIR}/doc + COMMAND ${CMAKE_COMMAND} -E remove ${GENERATED_RUNTIME_DIR}/doc/* COMMAND ${CMAKE_COMMAND} -E copy_directory ${PROJECT_SOURCE_DIR}/runtime/doc ${GENERATED_RUNTIME_DIR}/doc COMMAND "${PROJECT_BINARY_DIR}/bin/nvim"