meson: Respect --default-library option
By using shared_library() we force build of only a shared library, change it to library() to build static, shared or both depending on what user asked in build options.
Also simplify generation of pkg-config file, meson knows private libraries and requires, no need to specify them.