upgradepkg_select_pkg

SYNOPSIS

upgradepkg_select_pkg var pkg_to_install pkg_to_remove...

DESCRIPTION

Select among the given packages to be removed and store them in var depending on values of REMOVEALL and ASK.

If ASK is 1, then ask the user to confirm for removal of each found package. Otherwise, If REMOVEALL is 2, select the given package which should be only one in number.This is assumed and not verified because error checking must have been done while finding the package. If REMOVEALL is 1 (the default), then select all the packages if they are less than REMOVEPKG_MAXRM.As a special case, if REMOVEALL is 0 (the default), select all the packages.

(This never happens: Otherwise, store the given packages (which should be a single package, error checking is not done again as it should have been done before while finding the packages) in var.).

See the description for upgradepkg_find_pkg too.

RETURN

0 success ERR_META_MAXRM in case the matched packages exceed REMOVEPKG_MAXRM and REMOVEALL is 1