开发者

compling error on libmicrohttpd using ld

开发者 https://www.devze.com 2023-03-19 18:04 出处:网络
http://www.gnu.org/s/libmicrohttpd/tutorial.html#Hello-browser-example gcc helloworld.c-lmicrohttpd -I/opt/local/include/

http://www.gnu.org/s/libmicrohttpd/tutorial.html#Hello-browser-example

gcc helloworld.c -lmicrohttpd -I/opt/local/include/

helloworld.c: In function ‘answer_to_connection’: helloworld.c:18: warning: incompatible implicit declaration of built-in function ‘strlen’ ld: library not found for -lmicrohttpd collect2: ld returned 1 exit status

I开发者_JAVA百科 am using snow leopard with latest xcode and installed libmicrohttpd using macports


never used OSX but you need something like: -L/opt/local/lib

Check where the lib resides.. the linked docs says -L$PATH_TO_LIBMHD_INCLUDES

0

精彩评论

暂无评论...
验证码 换一张
取 消