aboutsummaryrefslogtreecommitdiffstats
path: root/URPM.xs
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2014-08-27 16:07:43 +0200
committerThierry Vignaud <thierry.vignaud@gmail.com>2014-09-14 00:12:29 +0200
commita3cc7c69783fb325cc691344473608eb3e72e8b6 (patch)
treebb4257cc10a830cf80afef9b9d02cc547f6b2e92 /URPM.xs
parent3db43b0cf315a4c0c7b78787f637db04045f90ed (diff)
downloadperl-URPM-a3cc7c69783fb325cc691344473608eb3e72e8b6.tar
perl-URPM-a3cc7c69783fb325cc691344473608eb3e72e8b6.tar.gz
perl-URPM-a3cc7c69783fb325cc691344473608eb3e72e8b6.tar.bz2
perl-URPM-a3cc7c69783fb325cc691344473608eb3e72e8b6.tar.xz
perl-URPM-a3cc7c69783fb325cc691344473608eb3e72e8b6.zip
add support for generating recommends in synthesis
aka having @recommends@ lines instead of @suggests@ ones Conflicts: NEWS URPM.xs
Diffstat (limited to 'URPM.xs')
-rw-r--r--URPM.xs5
1 files changed, 3 insertions, 2 deletions
diff --git a/URPM.xs b/URPM.xs
index 46fc2a9..80552fb 100644
--- a/URPM.xs
+++ b/URPM.xs
@@ -2066,10 +2066,11 @@ Pkg_free_header(pkg)
pkg->h = NULL;
void
-Pkg_build_info(pkg, fileno, provides_files=NULL)
+Pkg_build_info(pkg, fileno, provides_files=NULL, recommends=0)
URPM::Package pkg
int fileno
char *provides_files
+ int recommends
CODE:
if (pkg->info) {
char buff[65536*2];
@@ -2099,7 +2100,7 @@ Pkg_build_info(pkg, fileno, provides_files=NULL)
if (size < sizeof(buff)) write_nocheck(fileno, buff, size);
}
if (pkg->suggests && *pkg->suggests) {
- size = snprintf(buff, sizeof(buff), "@suggests@%s\n", pkg->suggests);
+ size = snprintf(buff, sizeof(buff), recommends ? "@recommends@%s\n" : "@suggests@%s\n", pkg->suggests);
if (size < sizeof(buff)) write_nocheck(fileno, buff, size);
}
if (pkg->summary && *pkg->summary) {