2

I can't find this anywhere.

I've installed json-spirit on my ubuntu server with apt-get install json-spirit-dev.

What linker flag has to be used with g++ to use json-spirit?

1 Answers1

2

The only library listed in that package is called libjson_spirit.a. You can link with it by adding -ljson_spirit to your linker step.

Carl Norum
  • 219,201
  • 40
  • 422
  • 469
  • oh cool, ty! now I know what to look for in the future. tyvm for the extra info! –  Jul 03 '13 at 00:32
  • how did you know that `-ljson_spirit` comes from `libjson_spirit.a`? –  Jul 03 '13 at 00:35
  • 2
    Check the description `-l` flag in the [GCC documentation](http://gcc.gnu.org/onlinedocs/gcc-4.8.1/gcc/Link-Options.html#Link-Options): "...`-l` surrounds *library* with `lib` and `.a`..." – Carl Norum Jul 03 '13 at 00:38