aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rw-r--r--cmake/GenerateHelptags.cmake.in39
-rw-r--r--runtime/CMakeLists.txt2
3 files changed, 2 insertions, 41 deletions
diff --git a/Makefile b/Makefile
index 717cf2f68d..ec7f5c7bce 100644
--- a/Makefile
+++ b/Makefile
@@ -101,7 +101,7 @@ else
endif
helptags: | nvim
- +$(BUILD_CMD) -C build helptags
+ +$(BUILD_CMD) -C build runtime/doc/tags
# Builds help HTML _and_ checks for invalid help tags.
helphtml: | nvim helptags
diff --git a/cmake/GenerateHelptags.cmake.in b/cmake/GenerateHelptags.cmake.in
deleted file mode 100644
index db6f15b1be..0000000000
--- a/cmake/GenerateHelptags.cmake.in
+++ /dev/null
@@ -1,39 +0,0 @@
-if(DEFINED ENV{DESTDIR})
- file(TO_CMAKE_PATH
- $ENV{DESTDIR}/@CMAKE_INSTALL_FULL_DATADIR@/nvim/runtime/doc
- HELPTAGS_WORKING_DIRECTORY)
-else()
- file(TO_CMAKE_PATH
- @CMAKE_INSTALL_FULL_DATADIR@/nvim/runtime/doc
- HELPTAGS_WORKING_DIRECTORY)
-endif()
-
-message(STATUS "Generating helptags in ${HELPTAGS_WORKING_DIRECTORY}")
-if(EXISTS ${HELPTAGS_WORKING_DIRECTORY}/)
- message(STATUS "${HELPTAGS_WORKING_DIRECTORY} already exists")
- # If the doc directory already exists, helptags could fail due to duplicate
- # tags. Tell the user to remove the directory and try again.
- set(TROUBLESHOOTING "\nRemove \"${HELPTAGS_WORKING_DIRECTORY}\" and try again.")
-endif()
-
-# Workaround for hanging "yes | nvim -c 'helptags ++t .'"
-# and therefore hanging "yes | make install":
-# Set INPUT_FILE to an empty file, causing execute_process
-# to disregard other standard input (such as "yes |").
-set(EMPTY_FILE ${CMAKE_CURRENT_BINARY_DIR}/.GenerateHelptags)
-file(WRITE ${EMPTY_FILE} "")
-execute_process(
- COMMAND ${CMAKE_CURRENT_BINARY_DIR}/bin/nvim
- -u NONE
- -es
- -c "helptags ++t ."
- -c quit
- WORKING_DIRECTORY ${HELPTAGS_WORKING_DIRECTORY}
- INPUT_FILE ${EMPTY_FILE}
- OUTPUT_VARIABLE err
- ERROR_VARIABLE err
- RESULT_VARIABLE res)
-
-if(NOT res EQUAL 0)
- message(FATAL_ERROR "Generating helptags failed: ${err} - ${res}${TROUBLESHOOTING}")
-endif()
diff --git a/runtime/CMakeLists.txt b/runtime/CMakeLists.txt
index f3bfd786ad..d66e04f5f2 100644
--- a/runtime/CMakeLists.txt
+++ b/runtime/CMakeLists.txt
@@ -78,7 +78,7 @@ add_custom_command(OUTPUT ${GENERATED_HELP_TAGS}
add_custom_target(doc_html
COMMAND make html
DEPENDS
- helptags
+ ${GENERATED_HELP_TAGS}
WORKING_DIRECTORY "${GENERATED_RUNTIME_DIR}/doc"
)