From 1b90f4a9c472e674d707cbc01520423d305f6b17 Mon Sep 17 00:00:00 2001 From: Eisuke Kawashima Date: Tue, 10 Dec 2024 09:10:27 +0900 Subject: [PATCH] build: mark CMake variables advanced #31412 The variables are not marked as advanced, thus they appear in e.g. `ccmake`. --- CMakeLists.txt | 5 +++++ cmake/Deps.cmake | 2 ++ src/nvim/CMakeLists.txt | 1 + 3 files changed, 8 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 9723de9176..ae5704cfe4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -187,6 +187,7 @@ if(NOT PREFER_LUA) find_program(LUA_PRG NAMES luajit) endif() find_program(LUA_PRG NAMES lua5.1 lua5.2 lua) +mark_as_advanced(LUA_PRG) if(NOT LUA_PRG) message(FATAL_ERROR "Failed to find a Lua 5.1-compatible interpreter") endif() @@ -200,6 +201,7 @@ message(STATUS "Using Lua interpreter: ${LUA_PRG}") if(NOT LUA_GEN_PRG) set(LUA_GEN_PRG "${LUA_PRG}" CACHE FILEPATH "Path to the lua used for code generation.") endif() +mark_as_advanced(LUA_GEN_PRG) message(STATUS "Using Lua interpreter for code generation: ${LUA_GEN_PRG}") option(COMPILE_LUA "Pre-compile Lua sources into bytecode (for sources that are included in the binary)" ON) @@ -219,6 +221,7 @@ if(COMPILE_LUA AND NOT WIN32) endif() endif() endif() +mark_as_advanced(LUAC_PRG) if(LUAC_PRG) message(STATUS "Using Lua compiler: ${LUAC_PRG}") endif() @@ -229,7 +232,9 @@ if(CI_LINT) set(LINT_REQUIRED "REQUIRED") endif() find_program(SHELLCHECK_PRG shellcheck ${LINT_REQUIRED}) +mark_as_advanced(SHELLCHECK_PRG) find_program(STYLUA_PRG stylua ${LINT_REQUIRED}) +mark_as_advanced(STYLUA_PRG) set(STYLUA_DIRS runtime scripts src test contrib) diff --git a/cmake/Deps.cmake b/cmake/Deps.cmake index 519826654f..5902ca6970 100644 --- a/cmake/Deps.cmake +++ b/cmake/Deps.cmake @@ -19,6 +19,7 @@ if(APPLE) endif() find_program(CACHE_PRG NAMES ccache sccache) +mark_as_advanced(CACHE_PRG) if(CACHE_PRG) set(CMAKE_C_COMPILER_LAUNCHER ${CMAKE_COMMAND} -E env CCACHE_SLOPPINESS=pch_defines,time_macros ${CACHE_PRG}) list(APPEND DEPS_CMAKE_CACHE_ARGS -DCMAKE_C_COMPILER_LAUNCHER:STRING=${CMAKE_C_COMPILER_LAUNCHER}) @@ -27,6 +28,7 @@ endif() # MAKE_PRG if(UNIX) find_program(MAKE_PRG NAMES gmake make) + mark_as_advanced(MAKE_PRG) if(NOT MAKE_PRG) message(FATAL_ERROR "GNU Make is required to build the dependencies.") else() diff --git a/src/nvim/CMakeLists.txt b/src/nvim/CMakeLists.txt index cffdcf0415..cce8ab5b25 100644 --- a/src/nvim/CMakeLists.txt +++ b/src/nvim/CMakeLists.txt @@ -826,6 +826,7 @@ target_link_libraries(libnvim PRIVATE main_lib PUBLIC libuv) #------------------------------------------------------------------------------- find_program(CLANG_TIDY_PRG clang-tidy) +mark_as_advanced(CLANG_TIDY_PRG) set(EXCLUDE_CLANG_TIDY typval_encode.c.h ui_events.in.h) if(WIN32) list(APPEND EXCLUDE_CLANG_TIDY