fix the version requirement
pkgmap entry now stores pkginsts associated, so we don't need to have it as argument
we always remove the deepest path first
package manager internal paths must be relative to root_path
make device optional for Package::Manager::get_package method

When the package is local, the device can be omitted so that the
package manager will automatically pick the /var/sadm/pkg directory.
As a result, we revert the order of options to make device the last.
remove a shared directory when the package removed was the last owner
added first tests: similarity test with solaris native tools