diff --git a/main.c b/main.c index 904f483..6126b71 100644 --- a/main.c +++ b/main.c @@ -283,7 +283,7 @@ pkg_queue_walk(pkg_queue_t *head) { pkg_dependency_t *pkgdep; - pkgdep = parse_deplist(&world, pkgq->package); + pkgdep = pkg_dependency_parse(&world, pkgq->package); world.requires = pkg_dependency_append(world.requires, pkgdep); free(pkgq->package); diff --git a/parse.c b/parse.c index fc7c3a9..2772ce8 100644 --- a/parse.c +++ b/parse.c @@ -44,7 +44,7 @@ parse_fragment_list(pkg_t *pkg, const char *string) } /* - * parse_deplist(pkg, depends) + * pkg_dependency_parse(pkg, depends) * * Add requirements to a .pc file. * Commas are counted as whitespace, as to allow: @@ -126,7 +126,7 @@ pkg_dependency_free(pkg_dependency_t *head) } pkg_dependency_t * -parse_deplist(pkg_t *pkg, const char *depends) +pkg_dependency_parse(pkg_t *pkg, const char *depends) { parse_state_t state = OUTSIDE_MODULE; pkg_dependency_t *deplist = NULL; @@ -368,11 +368,11 @@ parse_file(const char *filename, FILE *f) else if (!strcasecmp(key, "LIBS.private")) pkg->libs_private = parse_fragment_list(pkg, value); else if (!strcasecmp(key, "Requires")) - pkg->requires = parse_deplist(pkg, value); + pkg->requires = pkg_dependency_parse(pkg, value); else if (!strcasecmp(key, "Requires.private")) - pkg->requires_private = parse_deplist(pkg, value); + pkg->requires_private = pkg_dependency_parse(pkg, value); else if (!strcasecmp(key, "Conflicts")) - pkg->conflicts = parse_deplist(pkg, value); + pkg->conflicts = pkg_dependency_parse(pkg, value); break; case '=': pkg->vars = pkg_tuple_add(pkg->vars, key, value); diff --git a/pkg.h b/pkg.h index 8fb15b8..1f26cc4 100644 --- a/pkg.h +++ b/pkg.h @@ -145,7 +145,7 @@ const char *pkg_get_comparator(pkg_dependency_t *pkgdep); /* parse.c */ pkg_t *parse_file(const char *path, FILE *f); -pkg_dependency_t *parse_deplist(pkg_t *pkg, const char *depends); +pkg_dependency_t *pkg_dependency_parse(pkg_t *pkg, const char *depends); pkg_dependency_t *pkg_dependency_append(pkg_dependency_t *head, pkg_dependency_t *tail); void pkg_dependency_free(pkg_dependency_t *head);