build: use main cmake modules with third-party (#10330)

This is meant to make it possible to use `find_package(LuaJit)` etc with
the third-party CMake project in general.

Followup to https://github.com/neovim/neovim/pull/10297/files#r296439576.
This commit is contained in:
Daniel Hahler 2019-06-25 17:34:28 +02:00 committed by GitHub
parent e13ae7cae6
commit 3e6f06f5d2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 2 deletions

View File

@ -6,7 +6,7 @@ project(NVIM_DEPS)
include(CheckCCompilerFlag)
# Point CMake at any custom modules we may ship
list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake")
list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake" "${PROJECT_SOURCE_DIR}/../cmake")
# In Windows/MSVC CMAKE_BUILD_TYPE changes the paths/linking of the build
# recipes (libuv, msgpack), make sure it is set

View File

@ -59,7 +59,6 @@ if(UNIX OR (MINGW AND CMAKE_CROSSCOMPILING))
list(APPEND LUAROCKS_OPTS
--with-lua=${HOSTDEPS_INSTALL_DIR})
else()
list(APPEND CMAKE_MODULE_PATH "../cmake")
find_package(LuaJit)
if(LUAJIT_FOUND)
list(APPEND LUAROCKS_OPTS