cmake: added static library support

CMake provides BUILD_SHARED_LIBS option to choose library type in add_library
when it is not set explicity. Need to use this option
Merge pull request #58 from drizt/master

cmake: added static library support