raylua v4.0a
This commit is contained in:
parent
95d558cb98
commit
262a663355
@ -25,26 +25,29 @@ local ar = os.getenv "AR" or "ar"
|
||||
local windres = os.getenv "WINDRES" or "windres"
|
||||
|
||||
-- TODO: Use current lua interpreter
|
||||
local lua = os.getenv "LUA" or "luajit\\src\\luajit"
|
||||
local lua = os.getenv "LUA"
|
||||
local needs_luajit_built = not (os.getenv "LUA")
|
||||
|
||||
local cflags = os.getenv "CFLAGS" or "-O2 -s"
|
||||
local ldflags = os.getenv "LDFLAGS" or "-O2 -s -lm"
|
||||
|
||||
local modules = "raymath rlgl easings gestures physac raygui"
|
||||
local graphics = os.getenv "GRAPHICS" or "GRAPHICS_API_OPENGL_33"
|
||||
local graphics = os.getenv "GRAPHICS" or "GRAPHICS_API_OPENGL_43"
|
||||
|
||||
cflags = cflags .. " -Iluajit/src -Iraygui/src -Iraylib/src"
|
||||
ldflags = ldflags .. " luajit/src/libluajit.a raylib/src/libraylib.a luajit/src/libluajit.a"
|
||||
cflags = cflags .. " -Iluajit/src -Iraygui/src -Iraylib/src".. " -D" .. graphics
|
||||
|
||||
cflags = cflags .. " -D" .. graphics
|
||||
|
||||
local exe_ldflags = ""
|
||||
local raylua_so_path = "raylua.so" -- assume unix-like by default
|
||||
local so_ldflags = ldflags
|
||||
|
||||
if los.type() == "linux" then
|
||||
ldflags = ldflags .. " -ldl -pthread"
|
||||
so_ldflags = ldflags .. " -llua5.1"
|
||||
lua = lua or "luajit/src/luajit"
|
||||
elseif los.type() == "win32" then
|
||||
ldflags = ldflags .. " -lopengl32 -lgdi32 -lwinmm -static "
|
||||
so_ldflags = ldflags .. " -llua5.1.dll"
|
||||
raylua_so_path = "raylua.dll"
|
||||
lua = lua or "luajit\\src\\luajit"
|
||||
end
|
||||
|
||||
local libluajit
|
||||
@ -143,4 +146,12 @@ local raylua_e = c.link("raylua_e",
|
||||
false,
|
||||
"raylua_e",
|
||||
cc
|
||||
)
|
||||
)
|
||||
|
||||
local raylua_so = c.link(raylua_so_path,
|
||||
saphire.merge(raylua_obj, { libraylib }),
|
||||
so_ldflags,
|
||||
true,
|
||||
raylua_so_path,
|
||||
cc
|
||||
)
|
||||
|
2
raylib
2
raylib
@ -1 +1 @@
|
||||
Subproject commit 99f6707e2c80be2ac4c169fd6986ff2fd8d181a7
|
||||
Subproject commit 0851960397f02a477d80eda2239f90fae14dec64
|
@ -16,7 +16,7 @@
|
||||
|
||||
local load = loadstring
|
||||
|
||||
raylua.version = "v4.0-dev"
|
||||
raylua.version = "v4.0a"
|
||||
|
||||
function raylua.repl()
|
||||
print("> raylua " .. raylua.version .. " <")
|
||||
|
@ -130,7 +130,6 @@ void SetExitKey(int key)
|
||||
int GetKeyPressed(void)
|
||||
int GetCharPressed(void)
|
||||
bool IsGamepadAvailable(int gamepad)
|
||||
bool IsGamepadName(int gamepad, const char *name)
|
||||
const char *GetGamepadName(int gamepad)
|
||||
bool IsGamepadButtonPressed(int gamepad, int button)
|
||||
bool IsGamepadButtonDown(int gamepad, int button)
|
||||
|
Loading…
Reference in New Issue
Block a user