Fix some package auto-installation issues