raylib-lua icon indicating copy to clipboard operation
raylib-lua copied to clipboard

[tool] rLuaLauncher won't compile on macOS

Open evanwalsh opened this issue 7 years ago • 5 comments

I've tried my hardest to get this to compile on macOS and I'm not sure what I'm doing wrong. I've installed raylib via Homebrew and tried the commands from the comments to no success:

gcc -o rlualauncher rlualauncher.c -I../../src -I../../src/external/lua/include \
  -L../../src/external/lua/lib -lraylib -lopengl32 -lgdi32 -llua53 -std=c99 -Wall -Wl,--subsystem
In file included from rlualauncher.c:45:
../../src/raylib-lua.h:103:10: fatal error: 'raymath.h' file not found
#include "raymath.h"
         ^~~~~~~~~~~
1 error generated.

I tried pointing it at a local clone of the main raylib repository, but that generates even more errors and warnings. Should I try compiling raylib myself instead of using my package manager's version?

evanwalsh avatar Sep 21 '18 13:09 evanwalsh

Hi @evanwalsh!

I'm afraid raylib-lua is broken right now, it was based on raylib 1.7 and lately I was working on the update to raylib 2.0 but it's not finished yet... I can try to take a look this weekend but I can not promise anything... sorry.

Do you need Lua? Why not you take a look to the original C raylib version?

raysan5 avatar Sep 21 '18 14:09 raysan5

@raysan5 What a quick response! 😄 No pressure on any updates. I was just trying to toy around with this. I was interested in the Lua version as an alternative to Love2D (and as a chance to experiment with Fennel).

Thanks for all your hard work!

evanwalsh avatar Sep 21 '18 14:09 evanwalsh

Hi, hope you guys do not mind if I chime in.

I was experimenting with raylib-lua in hope to create a module so that I can create binding for Urn. This goes in the same direction like @evanwalsh with Fennl :) I soon found out, that many several compile errors occur. I thought this is because of me, until I saw that several function changed either parameters, function naming, or aren't avilable anymore. At that point I concluded->raylib-lua must be tailored to some older raylib version. Now I I just found this issue thread which seems to confirm my assumption. Anyway, I started to fix some things in the lua wrapper. Maybe at some point we can merge our work and create the bingings for other Fennel/Lua. Best regards!

paines avatar Jan 16 '19 08:01 paines

Hi @paines, sorry for the confusion with the old version, I hope it didn't take much time before you realised it. Just added a warning note in README.

Anyway, I started to fix some things in the lua wrapper. Maybe at some point we can merge our work and create the bingings for other Fennel/Lua.

That's great, any contributions is welcome! Are you working on src/raylib-lua.h? I expect to be able to generate that file automatically with rLuaParser but I was having some issues with parsing due to side cases.

raysan5 avatar Jan 16 '19 09:01 raysan5

Are you working on src/raylib-lua.h?

Exactly! But now that you mentioned rLuaParser, i will first take a look into that. Thanks for mentioning!

paines avatar Jan 16 '19 09:01 paines