mirror of
https://github.com/neovim/neovim.git
synced 2026-04-27 09:44:07 +00:00
refactor(build): make installation of runtime/ more effective
Currently files to install in runtime/ is detected by recursive glob pattern which has two problems: - cmake needs to do a of work at config time and build/runtime/cmake_install.cmake becomes HUGE (2.5MB, biggest config file) - we need to explicitly specify each file suffix used in the entire runtime, which is duplication of information. These globs specify every single file in a subdirectory. Thus, we can just install every runtime/ subdirectory as a single install command. Furthermore, at the top-level, only .vim and .lua files need to be installed. Further possible refactor: we could move files which does not belong in $PREFIX/runtime out of $REPO/runtime. Then runtime could be installed with a single install_helper(DIRECTORY ...) command.
This commit is contained in:
@@ -167,12 +167,3 @@ function(glob_wrapper outvar)
|
||||
endif()
|
||||
set(${outvar} ${${outvar}} PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
function(globrecurse_wrapper outvar root)
|
||||
if(${CMAKE_VERSION} VERSION_LESS 3.12)
|
||||
file(GLOB_RECURSE ${outvar} RELATIVE ${root} ${ARGN})
|
||||
else()
|
||||
file(GLOB_RECURSE ${outvar} CONFIGURE_DEPENDS RELATIVE ${root} ${ARGN})
|
||||
endif()
|
||||
set(${outvar} ${${outvar}} PARENT_SCOPE)
|
||||
endfunction()
|
||||
|
||||
Reference in New Issue
Block a user