sets dependencies and linking in the library