mirror of
https://github.com/neovim/neovim
synced 2025-07-16 01:01:49 +00:00
build: cmake fixes
- add EXTERNALPROJECT_OPTIONS variable to main build - use `REQUIRED` keyword for IWYU. - remove check_c_compiler_flag checks when `ENABLE_COMPILER_SUGGESTIONS` is `ON`. If we explicitly enable it then we probably want it to give an error if it doesn't exist, rather than silently skip it. - Move dependency interface libraries to their find module and use them as a pseudo-imported target. - Remove BUSTED_OUTPUT_TYPE. It's not used and we can reintroduce it again if something similar is needed. - Use LINK_OPTIONS intead of LINK_FLAGS when generating the `--version` output.
This commit is contained in:
@ -34,18 +34,16 @@ set(DEPS_INCLUDE_FLAGS "-I${DEPS_INSTALL_DIR}/include -I${DEPS_INSTALL_DIR}/incl
|
||||
|
||||
option(USE_BUNDLED "Use bundled dependencies." ON)
|
||||
|
||||
option(USE_BUNDLED_UNIBILIUM "Use the bundled unibilium." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_LIBVTERM "Use the bundled libvterm." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_LIBUV "Use the bundled libuv." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_MSGPACK "Use the bundled msgpack." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_LIBVTERM "Use the bundled libvterm." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_LPEG "Use the bundled lpeg." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_LUA "Use the bundled version of lua." OFF)
|
||||
option(USE_BUNDLED_LUAJIT "Use the bundled version of luajit." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_LUV "Use the bundled version of luv." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_LPEG "Use the bundled lpeg." ${USE_BUNDLED})
|
||||
#XXX(tarruda): Lua is only used for debugging the functional test client, don't
|
||||
# build it unless explicitly requested
|
||||
option(USE_BUNDLED_LUA "Use the bundled version of lua." OFF)
|
||||
option(USE_BUNDLED_TS_PARSERS "Use the bundled treesitter parsers." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_MSGPACK "Use the bundled msgpack." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_TS "Use the bundled treesitter runtime." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_TS_PARSERS "Use the bundled treesitter parsers." ${USE_BUNDLED})
|
||||
option(USE_BUNDLED_UNIBILIUM "Use the bundled unibilium." ${USE_BUNDLED})
|
||||
|
||||
if(USE_BUNDLED AND MSVC)
|
||||
option(USE_BUNDLED_GETTEXT "Use the bundled version of gettext." ON)
|
||||
|
@ -7,10 +7,6 @@ function(BuildLuajit)
|
||||
"TARGET"
|
||||
"CONFIGURE_COMMAND;BUILD_COMMAND;INSTALL_COMMAND;DEPENDS"
|
||||
${ARGN})
|
||||
if(NOT _luajit_CONFIGURE_COMMAND AND NOT _luajit_BUILD_COMMAND
|
||||
AND NOT _luajit_INSTALL_COMMAND)
|
||||
message(FATAL_ERROR "Must pass at least one of CONFIGURE_COMMAND, BUILD_COMMAND, INSTALL_COMMAND")
|
||||
endif()
|
||||
if(NOT _luajit_TARGET)
|
||||
set(_luajit_TARGET "luajit")
|
||||
endif()
|
||||
|
@ -2,7 +2,6 @@ ExternalProject_Add(treesitter
|
||||
URL ${TREESITTER_URL}
|
||||
URL_HASH SHA256=${TREESITTER_SHA256}
|
||||
DOWNLOAD_DIR ${DEPS_DOWNLOAD_DIR}/treesitter
|
||||
INSTALL_DIR ${DEPS_INSTALL_DIR}
|
||||
PATCH_COMMAND ${CMAKE_COMMAND} -E copy
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/cmake/TreesitterCMakeLists.txt
|
||||
${DEPS_BUILD_DIR}/src/treesitter/CMakeLists.txt
|
||||
|
@ -6,7 +6,6 @@ endif()
|
||||
project(${PARSERLANG} C)
|
||||
|
||||
add_compile_options(-w)
|
||||
set(CMAKE_C_STANDARD 99)
|
||||
|
||||
add_library(markdown MODULE
|
||||
tree-sitter-markdown/src/parser.c
|
||||
|
Reference in New Issue
Block a user