summaryrefslogtreecommitdiff
path: root/librazor
diff options
context:
space:
mode:
authorJames Bowes <jbowes@redhat.com>2008-06-26 18:15:59 -0400
committerJames Bowes <jbowes@redhat.com>2008-06-26 18:15:59 -0400
commit145002da7ffa173c14c6560e6ee26e6487554008 (patch)
treea65181ba16bdf4aaa4b381b971560235e88415c1 /librazor
parentc57370decf4e204cf4e3323e669cc676a2760707 (diff)
get rpm -qpi working fully
Diffstat (limited to 'librazor')
-rw-r--r--librazor/rpm.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/librazor/rpm.c b/librazor/rpm.c
index b8cca09..7eb5b01 100644
--- a/librazor/rpm.c
+++ b/librazor/rpm.c
@@ -781,7 +781,8 @@ razor_rpm_close(struct razor_rpm *rpm)
RAZOR_EXPORT int
razor_importer_add_rpm(struct razor_importer *importer, struct razor_rpm *rpm)
{
- const char *name, *version, *release, *arch, *summary;
+ const char *name, *version, *release, *arch;
+ const char *summary, *description, *url, *license;
const uint32_t *epoch;
char evr[128], buf[16];
@@ -790,7 +791,11 @@ razor_importer_add_rpm(struct razor_importer *importer, struct razor_rpm *rpm)
version = razor_rpm_get_indirect(rpm, RPMTAG_VERSION, NULL);
release = razor_rpm_get_indirect(rpm, RPMTAG_RELEASE, NULL);
arch = razor_rpm_get_indirect(rpm, RPMTAG_ARCH, NULL);
+
summary = razor_rpm_get_indirect(rpm, RPMTAG_SUMMARY, NULL);
+ description = razor_rpm_get_indirect(rpm, RPMTAG_DESCRIPTION, NULL);
+ url = razor_rpm_get_indirect(rpm, RPMTAG_URL, NULL);
+ license = razor_rpm_get_indirect(rpm, RPMTAG_LICENSE, NULL);
if (epoch) {
snprintf(buf, sizeof buf, "%u", ntohl(*epoch));
@@ -800,6 +805,9 @@ razor_importer_add_rpm(struct razor_importer *importer, struct razor_rpm *rpm)
}
razor_importer_begin_package(importer, name, evr, arch);
+ razor_importer_add_details(importer, summary, description, url,
+ license);
+
import_properties(importer, RAZOR_PROPERTY_REQUIRES, rpm,
RPMTAG_REQUIRENAME,
RPMTAG_REQUIREVERSION,