mirror of
https://github.com/neovim/neovim.git
synced 2025-12-09 16:12:48 +00:00
Merge #5130 from equalsraf/tb-appveyor
Enable MSYS/MinGW builds in Appveyor
This commit is contained in:
15
third-party/cmake/BuildLuarocks.cmake
vendored
15
third-party/cmake/BuildLuarocks.cmake
vendored
@@ -3,7 +3,7 @@
|
||||
# writing a recipe that is meant for cross-compile, use the HOSTDEPS_* variables
|
||||
# instead of DEPS_* - check the main CMakeLists.txt for a list.
|
||||
|
||||
if(MSVC)
|
||||
if(MSVC OR (MINGW AND NOT CMAKE_CROSSCOMPILING))
|
||||
message(STATUS "Building busted in Windows is not supported (skipping)")
|
||||
else()
|
||||
option(USE_BUNDLED_BUSTED "Use the bundled version of busted to run tests." ON)
|
||||
@@ -46,11 +46,9 @@ endfunction()
|
||||
set(LUAROCKS_BINARY ${HOSTDEPS_BIN_DIR}/luarocks)
|
||||
|
||||
# Arguments for calls to 'luarocks build'
|
||||
if(MSVC)
|
||||
# In native Win32 don't pass the compiler/linker to luarocks, the bundled
|
||||
if(NOT MSVC)
|
||||
# In MSVC don't pass the compiler/linker to luarocks, the bundled
|
||||
# version already knows, and passing them here breaks the build
|
||||
set(LUAROCKS_BUILDARGS CFLAGS=/MT)
|
||||
else()
|
||||
set(LUAROCKS_BUILDARGS CC=${HOSTDEPS_C_COMPILER} LD=${HOSTDEPS_C_COMPILER})
|
||||
endif()
|
||||
|
||||
@@ -67,8 +65,12 @@ if(UNIX OR (MINGW AND CMAKE_CROSSCOMPILING))
|
||||
--prefix=${HOSTDEPS_INSTALL_DIR} --force-config ${LUAROCKS_OPTS}
|
||||
--lua-suffix=jit
|
||||
INSTALL_COMMAND ${MAKE_PRG} bootstrap)
|
||||
elseif(MSVC OR MINGW)
|
||||
|
||||
if(MINGW)
|
||||
set(MINGW_FLAG /MW)
|
||||
endif()
|
||||
|
||||
elseif(MSVC)
|
||||
# Ignore USE_BUNDLED_LUAJIT - always ON for native Win32
|
||||
BuildLuarocks(INSTALL_COMMAND install.bat /FORCECONFIG /NOREG /NOADMIN /Q /F
|
||||
/LUA ${DEPS_INSTALL_DIR}
|
||||
@@ -78,6 +80,7 @@ elseif(MSVC)
|
||||
/P ${DEPS_INSTALL_DIR} /TREE ${DEPS_INSTALL_DIR}
|
||||
/SCRIPTS ${DEPS_BIN_DIR}
|
||||
/CMOD ${DEPS_BIN_DIR}
|
||||
${MINGW_FLAG}
|
||||
/LUAMOD ${DEPS_BIN_DIR}/lua)
|
||||
|
||||
set(LUAROCKS_BINARY ${DEPS_INSTALL_DIR}/2.2/luarocks.bat)
|
||||
|
||||
Reference in New Issue
Block a user