safe-install function added: checks if a package is already installed