diff options
author | dundargoc <gocdundar@gmail.com> | 2024-01-19 13:21:25 +0100 |
---|---|---|
committer | dundargoc <33953936+dundargoc@users.noreply.github.com> | 2024-01-20 12:59:27 +0100 |
commit | f936a962d04f9937946018cc1386f20bda6fc1de (patch) | |
tree | d9830f132b1ee1de25ad8032b183a500a9baaeeb /runtime | |
parent | ed103cde28dd6aeb8d240240309c26d3f20060f4 (diff) | |
download | rneovim-f936a962d04f9937946018cc1386f20bda6fc1de.tar.gz rneovim-f936a962d04f9937946018cc1386f20bda6fc1de.tar.bz2 rneovim-f936a962d04f9937946018cc1386f20bda6fc1de.zip |
build: create separate targets for nvim with and without runtime files
This distinction is important for correct dependency management, as the
nvim binary is used to create some runtime files. The nvim binary (and
the target to build it) is thus called `nvim_bin` and the target to
build all of nvim (binary+runtime) is called `nvim`.
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/CMakeLists.txt | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/runtime/CMakeLists.txt b/runtime/CMakeLists.txt index a44713d4ce..c9655ad9b9 100644 --- a/runtime/CMakeLists.txt +++ b/runtime/CMakeLists.txt @@ -1,5 +1,9 @@ -set(SYN_VIM_GENERATOR ${PROJECT_SOURCE_DIR}/src/nvim/generators/gen_vimvim.lua) +set(GENERATED_RUNTIME_DIR ${PROJECT_BINARY_DIR}/runtime) + +set(GENERATED_HELP_TAGS ${GENERATED_RUNTIME_DIR}/doc/tags) set(GENERATED_PACKAGE_DIR ${GENERATED_RUNTIME_DIR}/pack/dist/opt) +set(GENERATED_SYN_VIM ${GENERATED_RUNTIME_DIR}/syntax/vim/generated.vim) +set(SYN_VIM_GENERATOR ${PROJECT_SOURCE_DIR}/src/nvim/generators/gen_vimvim.lua) file(MAKE_DIRECTORY ${GENERATED_RUNTIME_DIR}/syntax/vim) @@ -32,7 +36,7 @@ foreach(PACKAGE ${PACKAGES}) COMMAND "${PROJECT_BINARY_DIR}/bin/nvim" -u NONE -i NONE -e --headless -c "helptags doc" -c quit DEPENDS - nvim + nvim_bin nvim_runtime_deps WORKING_DIRECTORY "${GENERATED_PACKAGE_DIR}/${PACKNAME}" ) @@ -66,7 +70,7 @@ add_custom_command(OUTPUT ${GENERATED_HELP_TAGS} COMMAND "${PROJECT_BINARY_DIR}/bin/nvim" -u NONE -i NONE -e --headless -c "helptags ++t doc" -c quit DEPENDS - nvim + nvim_bin nvim_runtime_deps WORKING_DIRECTORY "${GENERATED_RUNTIME_DIR}" ) @@ -81,7 +85,7 @@ add_custom_target(doc_html ) add_custom_target( - runtime ALL + nvim_runtime DEPENDS ${GENERATED_SYN_VIM} ${GENERATED_HELP_TAGS} |