Remove unnecessary dependencies and minor fixes.