Do not always build static and dynamic
Do not always build static and dynamic

Currently, the static and dynamic version of the libraries are always
built as add_library is called twice. Instead, this patch will use the
standard CMake variable BUILD_SHARED_LIBS to know if the static or the
dynamic version must be built.

Signed-off-by: Fabrice Fontaine <edf03f3512e0539bc34442e6bd5d9ea573f7ba37@orange.com>

gatzka/cJSON,etodd/cJSON,DaveGamble/cJSON,kbranigan/cJSON,gatzka/cJSON,FSMaxB/cJSON,FSMaxB/cJSON,DaveGamble/cJSON,DaveGamble/cJSON,gatzka/cJSON,DaveGamble/cJSON,FSMaxB/cJSON,gatzka/cJSON,FSMaxB/cJSON,FSMaxB/cJSON,gatzka/cJSON