+ int rv;
+ if (opt.init) {
+ rv = zpm_parse_package(pkgstr, package, version, &release);
+ if (rv != 3) {
+ die("incomplete package string '%s'\n", pkgstr);
+ } else {
+ rv = zpm_create_package(&zpm, package, version, release);
+ pkgid = zpm_findpkg(&zpm, pkgstr, NULL);
+ if (!rv) {
+ die("unable to create package %s\n", pkgstr);
+ }
+ }
+ } else {
+ die("package %s not found\n", pkgstr);
+ }