Added cmake files for tools and libmpq.
Fixed misconfigured cmake file for pcre.