Optionally scan dependencies.