lloyd / yajl

A fast streaming JSON parsing library in C.
http://lloyd.github.com/yajl
ISC License
2.15k stars 435 forks source link

Static library builds as libyajl_s.a and nothing can find it #209

Open adamnovak opened 6 years ago

adamnovak commented 6 years ago

The build system names the static library with a _s suffix, as libyajl_s.a. This causes problems like https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=877285 downstream because you can't use the expected -lyajl linker flag to link against it. You need to specify -lyajl_s. Notably, the pkg-config file that gets generated from the build does not tell pkg-config about this. Running pkg-config --static --libs yajl still recommends -lyajl as the appropriate linker flag, which causes downstream builds using pkg-config to find the static library to fail.

The build system should call the static library libyajl.a on Linux, as static and dynamic libraries on Linux are supposed to have the same name.