1 #define _POSIX_C_SOURCE 200809L
10 #define DMARK fprintf(stderr, "mark %s %s:%d\n", __FILE__, __func__, __LINE__)
12 int zpm_create_pkgid(struct zpm *zpm, char *pkgstr) {
22 found = zpm_parse_package(pkgstr, package, version, &release);
27 return zpm_create_package(zpm, package, version, release);
30 int zpm_create_package(struct zpm *zpm, char *name, char *ver, int rel) {
31 char *ins = "insert into packages (package, version, release) values (%Q,%Q,%d);";
37 zpm_db_run(zpm, ins, name, ver, rel);
38 return zpm->error ? 0 : 1;