Skip to content
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

dlopen failed: cannot locate symbol "floor" referenced by ... #77

Open
dauuricus opened this issue Sep 6, 2021 · 2 comments
Open

dlopen failed: cannot locate symbol "floor" referenced by ... #77

dauuricus opened this issue Sep 6, 2021 · 2 comments

Comments

@dauuricus
Copy link

lua-cjson 2.1.0-1

using termux pkg luarocks on armv7a android

u0_a185@localhost ~/luatest> lua -e "require 'cjson'"
lua: error loading module 'cjson' from file
 '/data/data/com.termux/files/usr/lib/lua/5.3/cjson.so':
    dlopen failed: cannot locate symbol "floor" referenced by "/data/data/com.termux/files/usr/lib/lua/5.3/cjson.so"...                                                           stack traceback:
[C]: in ?
[C]: in function 'require'
(command line):1: in main chunk
[C]: in ?
@jwzl
Copy link

jwzl commented Sep 16, 2021

I alse meeted, and how to fix it ? thanks!

@dosimple
Copy link

dosimple commented Dec 8, 2022

Adding -lm to the linking step solves the problem:

gcc -shared -lm -o cjson.so lua_cjson.o strbuf.o fpconv.o

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants