Refactor package install to support 5.5/5.6 packages