Justin Haygood wrote:
Hello. I'm investigating adding a zypp backend to packagekit, and during my investigation, I noticed that some packages zypp handles has EULA prompts.
While discussing with Richard Hughes, we discussed how to handle this, and due to the backend design, there was 2 methods:
1. Showing the EULA before the package is queued (preferable) 2. Showing the EULA after the package is installed
So basically.. the question for this list is:
1. Is the EULA for the package (such as flash-player, etc..) available before the package is installed, and available via the libzypp API?
Yes, the EULA that needs confirmation is available from the moment you read the metadata (e.g. by ResStore resstore = RepoManager::createFromCache().resolvables()), through the Resolvable::licenseToConfirm() method. If there's no license to confirm, the string returned will be empty, otherwise it contains the text of the license agreement. Although its far from being a good example, you can find an inspiration in zypper's implementation here: http://svn.opensuse.org/svn/zypp/trunk/zypper/src/zypper-misc.cc (look for confirm_licenses() function) You can find an example in YaST code, too, maybe someone else can point you to it. Regards, Jano Jan Kupec YaST Team -- To unsubscribe, e-mail: zypp-devel+unsubscribe@opensuse.org For additional commands, e-mail: zypp-devel+help@opensuse.org