-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
configure failed on OS X with LuaJIT and workaround #1110
Comments
Does the OSX luajit .pc file contain these options? |
|
Then I think luajit should add that to their .pc file. That's what these files are for, after all. (I was just afraid waf would filter out these flags.) |
That's why I called it a workaround. LuaJIT doesn't use autotools and the .pc file is fixed instead of generated. Those options are only for 64-bit OS X main executables. FYI: You can take a look at the popular ngx_lua project (https://github.com/openresty/lua-nginx-module) which makes heavy use of LuaJIT. It detects the OS type and the lua engine then adds the needed LDFLAGS. |
Yeah, that lua-nginx-module config script demonstrates exactly what we do not want. It hardcodes the possible installation paths on every platform. I'd argue LuaJIT should just either fix their .pc file, or their memory allocator code (which requires these options). To make matters worse, you couldn't use a libmpv linked to luajit, because that would require the application using libmpv to know about these luajit options. What's wrong with using plain Lua, btw.? |
PS: of course one problem is that official upstream Lua doesn't even have a .pc file (these are added by distros etc.), but so far relying on .pc worked relatively well. |
Of course I can use the official lua, but I am a LuaJIT lover since I learned from it a lot. Is there any plan to make mpv on OS X an app package so that I can open movies from Finder? And lua will make it more interesting when you can control it with a piece of lua script. |
It is already, see the homebrew formula. |
I just run the python script TOOLS/osxbundle.py.
I checked
Then I run the generated mpv.app, everything is fine but mpv halts when I press Cmd+0/1/2 to zoom the window, F is ok. I tried to run mpv from terminal, the result is the same. |
Closing, LuaJIT's .pc file should be fixed instead. |
LuaJIT ships with a broken .pc file on OS X (see #1110), and leaving Lua52 last was done only to improve libquvi interoperability.
For reference: brew installed luajit does provide these flags now and compilation works so this is no longer an issue.
(However, it still doesn't work as mpv fails to initialize it for reasons I don't know yet.) |
./waf configure
failed on my OS X 10.9.4 with luajit-2.0.3.The workaround is to configure with the following command line:
LDFLAGS="-pagezero_size 10000 -image_base 100000000" ./waf configure --lua=luajit
It is a LuaJIT issue when running on 64-bit OS X and is documented in http://luajit.org/install.html .
The text was updated successfully, but these errors were encountered: