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

failed compile on mac #112

Closed
zhaozg opened this issue Aug 17, 2017 · 4 comments
Closed

failed compile on mac #112

zhaozg opened this issue Aug 17, 2017 · 4 comments

Comments

@zhaozg
Copy link
Contributor

zhaozg commented Aug 17, 2017

make CFLAGS=-I/usr/local/lua

6 warnings generated.
src/lchttppost.c:119:12: warning: unused function 'lcurl_hpost_to_s' [-Wunused-function]
static int lcurl_hpost_to_s(lua_State *L){
           ^
1 warning generated.
ld: library not found for -lrt
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [lcurl.so] Error 1
bash-3.2$ uname -a
Darwin MacBook-Air 16.7.0 Darwin Kernel Version 16.7.0: Thu Jun 15 17:36:27 PDT 2017; root:xnu-3789.70.16~2/RELEASE_X86_64 x86_64
bash-3.2$ 
@moteus
Copy link
Member

moteus commented Aug 21, 2017

First warning already solved on master. When I implement this function I take a breake to think is it should
be used to convert form to string or use get method instead. :)

About second one. I do not maintain this makefile. But problem is pretty obvious.
You do not need link with real time library on OSX. In fact I do not think it is needed
to link with it at all. Rockspec does not do it. May be it required if using static version
of libcurl? So PR are welcome.

@msva ping

@msva
Copy link
Contributor

msva commented Aug 21, 2017

Well, actually I have no working MacOS X at this moment, so I can't properly test for the fix, but I can indeed drop linking against librt just in case.
I'll try to look into in today's evening.

@moteus
Copy link
Member

moteus commented Aug 22, 2017

@zhaozg can you please checkout current master

@zhaozg
Copy link
Contributor Author

zhaozg commented Aug 27, 2017

Fixed

@zhaozg zhaozg closed this as completed Aug 27, 2017
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