diff options
author | dundargoc <gocdundar@gmail.com> | 2023-11-12 22:04:15 +0100 |
---|---|---|
committer | dundargoc <33953936+dundargoc@users.noreply.github.com> | 2023-11-12 23:43:57 +0100 |
commit | 03c3f7887dbc26c4246ea2eeb135453f3f3ee000 (patch) | |
tree | 80069d8e80c11218ebc7a2befc95abe208fe5cf9 | |
parent | 6d14f3ddab33144966e46487b6039440ac7c43f2 (diff) | |
download | rneovim-03c3f7887dbc26c4246ea2eeb135453f3f3ee000.tar.gz rneovim-03c3f7887dbc26c4246ea2eeb135453f3f3ee000.tar.bz2 rneovim-03c3f7887dbc26c4246ea2eeb135453f3f3ee000.zip |
build: enforce PREFER_LUA
Only search for luajit if PREFER_LUA=OFF. If PREFER_LUA is OFF, then
always prioritize luajit first and then fall back to lua.
-rw-r--r-- | CMakeLists.txt | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index bcfac39098..b57e55f938 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -168,7 +168,10 @@ foreach(CFGNAME ${CMAKE_CONFIGURATION_TYPES}) set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY_${CFGNAME} ${CMAKE_BINARY_DIR}/lib) endforeach() -find_program(LUA_PRG NAMES luajit lua5.1 lua5.2 lua) +if(NOT PREFER_LUA) + find_program(LUA_PRG NAMES luajit) +endif() +find_program(LUA_PRG NAMES lua5.1 lua5.2 lua) if(NOT LUA_PRG) message(FATAL_ERROR "Failed to find a Lua 5.1-compatible interpreter") endif() |