mirror of
https://github.com/love2d/love.git
synced 2026-08-16 08:11:02 +02:00
Remove references to old LOVE_ENABLE_module_implementation defines
As far as I know they are no longer used, as autotools was the primary (only) user and it now switches entire modules. I've also taken the opportunity to clean up the default list in src/common/config.h. Oh yeah, and this fixes linux builds not having graphics or audio backends. --HG-- branch : minor
This commit is contained in:
+12
-33
@@ -137,50 +137,29 @@
|
||||
# define LOVE_LITTLE_ENDIAN 1
|
||||
# endif
|
||||
#else
|
||||
# define LOVE_ENABLE_AUDIO
|
||||
# define LOVE_ENABLE_AUDIO_NULL
|
||||
# define LOVE_ENABLE_AUDIO_OPENAL
|
||||
# define LOVE_ENABLE_BOX2D
|
||||
# define LOVE_ENABLE_DDSPARSE
|
||||
# define LOVE_ENABLE_ENET
|
||||
# define LOVE_ENABLE_EVENT
|
||||
# define LOVE_ENABLE_EVENT_SDL
|
||||
# define LOVE_ENABLE_FILESYSTEM
|
||||
# define LOVE_ENABLE_FILESYSTEM_PHYSFS
|
||||
# define LOVE_ENABLE_FONT
|
||||
# define LOVE_ENABLE_FONT_FREETYPE
|
||||
# define LOVE_ENABLE_GRAPHICS
|
||||
# define LOVE_ENABLE_GRAPHICS_OPENGL
|
||||
# define LOVE_ENABLE_IMAGE
|
||||
# define LOVE_ENABLE_IMAGE_MAGPIE
|
||||
# define LOVE_ENABLE_JOYSTICK
|
||||
# define LOVE_ENABLE_JOYSTICK_SDL
|
||||
# define LOVE_ENABLE_KEYBOARD
|
||||
# define LOVE_ENABLE_KEYBOARD_SDL
|
||||
# define LOVE_ENABLE_LOVE
|
||||
# define LOVE_ENABLE_LUASOCKET
|
||||
# define LOVE_ENABLE_LUAUTF8
|
||||
# define LOVE_ENABLE_AUDIO
|
||||
# define LOVE_ENABLE_EVENT
|
||||
# define LOVE_ENABLE_FILESYSTEM
|
||||
# define LOVE_ENABLE_FONT
|
||||
# define LOVE_ENABLE_GRAPHICS
|
||||
# define LOVE_ENABLE_IMAGE
|
||||
# define LOVE_ENABLE_JOYSTICK
|
||||
# define LOVE_ENABLE_KEYBOARD
|
||||
# define LOVE_ENABLE_MATH
|
||||
# define LOVE_ENABLE_MOUSE
|
||||
# define LOVE_ENABLE_MOUSE_SDL
|
||||
# define LOVE_ENABLE_NOISE1234
|
||||
# define LOVE_ENABLE_PHYSICS
|
||||
# define LOVE_ENABLE_PHYSICS_BOX2D
|
||||
# define LOVE_ENABLE_SOUND
|
||||
# define LOVE_ENABLE_SOUND_LULLABY
|
||||
# define LOVE_ENABLE_SYSTEM
|
||||
# define LOVE_ENABLE_SYSTEM_SDL
|
||||
# define LOVE_ENABLE_THREAD
|
||||
# define LOVE_ENABLE_THREAD_SDL
|
||||
# define LOVE_ENABLE_TIMER
|
||||
# define LOVE_ENABLE_TOUCH
|
||||
# define LOVE_ENABLE_TOUCH_SDL
|
||||
# define LOVE_ENABLE_UTF8
|
||||
# define LOVE_ENABLE_VIDEO
|
||||
# define LOVE_ENABLE_VIDEO_THEORA
|
||||
# define LOVE_ENABLE_WINDOW
|
||||
# define LOVE_ENABLE_WINDOW_SDL
|
||||
# define LOVE_ENABLE_WUFF
|
||||
|
||||
# define LOVE_ENABLE_ENET
|
||||
# define LOVE_ENABLE_LUASOCKET
|
||||
# define LOVE_ENABLE_LUAUTF8
|
||||
#endif
|
||||
|
||||
// Check we have a sane configuration
|
||||
|
||||
@@ -524,7 +524,6 @@ extern "C" int luaopen_love_audio(lua_State *L)
|
||||
{
|
||||
Audio *instance = instance();
|
||||
|
||||
#ifdef LOVE_ENABLE_AUDIO_OPENAL
|
||||
if (instance == nullptr)
|
||||
{
|
||||
// Try OpenAL first.
|
||||
@@ -539,9 +538,7 @@ extern "C" int luaopen_love_audio(lua_State *L)
|
||||
}
|
||||
else
|
||||
instance->retain();
|
||||
#endif
|
||||
|
||||
#ifdef LOVE_ENABLE_AUDIO_NULL
|
||||
if (instance == nullptr)
|
||||
{
|
||||
// Fall back to nullaudio.
|
||||
@@ -554,7 +551,6 @@ extern "C" int luaopen_love_audio(lua_State *L)
|
||||
std::cout << e.what() << std::endl;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (instance == nullptr)
|
||||
return luaL_error(L, "Could not open any audio module.");
|
||||
|
||||
@@ -30,9 +30,7 @@
|
||||
#include "common/Reference.h"
|
||||
#include "math/wrap_Transform.h"
|
||||
|
||||
#ifdef LOVE_ENABLE_GRAPHICS_OPENGL
|
||||
#include "opengl/Graphics.h"
|
||||
#endif
|
||||
|
||||
#include <cassert>
|
||||
#include <cstring>
|
||||
@@ -2637,11 +2635,7 @@ extern "C" int luaopen_love_graphics(lua_State *L)
|
||||
Graphics *instance = instance();
|
||||
if (instance == nullptr)
|
||||
{
|
||||
#ifdef LOVE_ENABLE_GRAPHICS_OPENGL
|
||||
luax_catchexcept(L, [&](){ instance = new love::graphics::opengl::Graphics(); });
|
||||
#else
|
||||
return luaL_error(L, "LOVE was compiled without any love.graphics backend!");
|
||||
#endif
|
||||
}
|
||||
else
|
||||
instance->retain();
|
||||
|
||||
@@ -168,12 +168,12 @@ static const luaL_Reg modules[] = {
|
||||
#if defined(LOVE_ENABLE_SYSTEM)
|
||||
{ "love.system", luaopen_love_system },
|
||||
#endif
|
||||
#if defined(LOVE_ENABLE_TIMER)
|
||||
{ "love.timer", luaopen_love_timer },
|
||||
#endif
|
||||
#if defined(LOVE_ENABLE_THREAD)
|
||||
{ "love.thread", luaopen_love_thread },
|
||||
#endif
|
||||
#if defined(LOVE_ENABLE_TIMER)
|
||||
{ "love.timer", luaopen_love_timer },
|
||||
#endif
|
||||
#if defined(LOVE_ENABLE_TOUCH)
|
||||
{ "love.touch", luaopen_love_touch },
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user