mirror of
https://github.com/love2d/love.git
synced 2026-08-19 20:19:42 +02:00
Windows: Slight changes to ARM64 support.
* Disable NSIS installer if we're compiling for Windows ARM64. * Allow arbitrary files to be added as LOVE_EXTRA_DLLS
This commit is contained in:
+22
-8
@@ -53,12 +53,15 @@ else()
|
|||||||
set(LOVE_TARGET_PLATFORM x86)
|
set(LOVE_TARGET_PLATFORM x86)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(APPLE)
|
|
||||||
option(LOVE_JIT "Use LuaJIT" FALSE)
|
if(APPLE OR MEGA_ARM64)
|
||||||
|
set(LOVE_DEFAULT_JIT FALSE)
|
||||||
else()
|
else()
|
||||||
option(LOVE_JIT "Use LuaJIT" TRUE)
|
set(LOVE_DEFAULT_JIT TRUE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
option(LOVE_JIT "Use LuaJIT" ${LOVE_DEFAULT_JIT})
|
||||||
|
|
||||||
if(LOVE_JIT)
|
if(LOVE_JIT)
|
||||||
if(APPLE)
|
if(APPLE)
|
||||||
message(WARNING "JIT not supported yet on Mac.")
|
message(WARNING "JIT not supported yet on Mac.")
|
||||||
@@ -119,12 +122,16 @@ if(MEGA)
|
|||||||
${MEGA_OPENAL}
|
${MEGA_OPENAL}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# LOVE_EXTRA_DLLS are non-runtime DLLs which should be bundled with the
|
||||||
|
# love binary in installers, etc. It's only needed for external
|
||||||
|
# (non-CMake) targets, i.e. LuaJIT.
|
||||||
|
if(NOT DEFINED LOVE_EXTRA_DLLS)
|
||||||
|
set(LOVE_EXTRA_DLLS)
|
||||||
|
endif()
|
||||||
|
|
||||||
if(LOVE_JIT)
|
if(LOVE_JIT)
|
||||||
set(LOVE_LUA_LIBRARY ${MEGA_LUAJIT_LIB})
|
set(LOVE_LUA_LIBRARY ${MEGA_LUAJIT_LIB})
|
||||||
# LOVE_EXTRA_DLLS are non-runtime DLLs which should be bundled with the
|
set(LOVE_EXTRA_DLLS ${LOVE_EXTRA_DLLS} ${MEGA_LUAJIT_DLL})
|
||||||
# love binary in installers, etc. It's only needed for external
|
|
||||||
# (non-CMake) targets, i.e. LuaJIT.
|
|
||||||
set(LOVE_EXTRA_DLLS ${MEGA_LUAJIT_DLL})
|
|
||||||
set(LOVE_EXTRA_DEPENDECIES luajit)
|
set(LOVE_EXTRA_DEPENDECIES luajit)
|
||||||
|
|
||||||
set(LOVE_INCLUDE_DIRS
|
set(LOVE_INCLUDE_DIRS
|
||||||
@@ -1998,6 +2005,14 @@ message(STATUS "Version: ${LOVE_VERSION_STR}")
|
|||||||
###################################
|
###################################
|
||||||
install(TARGETS ${LOVE_EXE_NAME} ${LOVE_CONSOLE_EXE_NAME} ${LOVE_LIB_NAME} RUNTIME DESTINATION .)
|
install(TARGETS ${LOVE_EXE_NAME} ${LOVE_CONSOLE_EXE_NAME} ${LOVE_LIB_NAME} RUNTIME DESTINATION .)
|
||||||
|
|
||||||
|
# Our install script (and NSIS) doesn't fully support Windows ARM64 yet.
|
||||||
|
if(MEGA_ARM64)
|
||||||
|
set(CPACK_GENERATOR ZIP)
|
||||||
|
set(CPACK_SYSTEM_NAME woa64)
|
||||||
|
else()
|
||||||
|
set(CPACK_GENERATOR ZIP NSIS)
|
||||||
|
endif()
|
||||||
|
|
||||||
# Extra DLLs.
|
# Extra DLLs.
|
||||||
if(LOVE_EXTRA_DLLS)
|
if(LOVE_EXTRA_DLLS)
|
||||||
foreach(DLL ${LOVE_EXTRA_DLLS})
|
foreach(DLL ${LOVE_EXTRA_DLLS})
|
||||||
@@ -2040,7 +2055,6 @@ install(FILES
|
|||||||
${CMAKE_CURRENT_SOURCE_DIR}/extra/nsis/game.ico
|
${CMAKE_CURRENT_SOURCE_DIR}/extra/nsis/game.ico
|
||||||
DESTINATION .)
|
DESTINATION .)
|
||||||
|
|
||||||
set(CPACK_GENERATOR ZIP NSIS)
|
|
||||||
set(CPACK_PACKAGE_NAME "love")
|
set(CPACK_PACKAGE_NAME "love")
|
||||||
set(CPACK_PACKAGE_VENDOR "love2d.org")
|
set(CPACK_PACKAGE_VENDOR "love2d.org")
|
||||||
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "LOVE -- It's awesome")
|
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "LOVE -- It's awesome")
|
||||||
|
|||||||
@@ -262,11 +262,9 @@ std::vector<Window::ContextAttribs> Window::getContextAttribsList() const
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!preferGLES)
|
const char *gleshint = SDL_GetHint("LOVE_GRAPHICS_USE_OPENGLES");
|
||||||
{
|
if (gleshint != nullptr)
|
||||||
const char *gleshint = SDL_GetHint("LOVE_GRAPHICS_USE_OPENGLES");
|
|
||||||
preferGLES = (gleshint != nullptr && gleshint[0] != '0');
|
preferGLES = (gleshint != nullptr && gleshint[0] != '0');
|
||||||
}
|
|
||||||
|
|
||||||
// Do we want a debug context?
|
// Do we want a debug context?
|
||||||
bool debug = love::graphics::isDebugEnabled();
|
bool debug = love::graphics::isDebugEnabled();
|
||||||
|
|||||||
Reference in New Issue
Block a user