Checking for dependencies with cmake