summaryrefslogtreecommitdiff
path: root/lib/poptQV.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/poptQV.c')
-rw-r--r--lib/poptQV.c36
1 files changed, 32 insertions, 4 deletions
diff --git a/lib/poptQV.c b/lib/poptQV.c
index 3db17b0ab..e3ea2d7bc 100644
--- a/lib/poptQV.c
+++ b/lib/poptQV.c
@@ -21,6 +21,10 @@ struct rpmQVKArguments_s rpmQVKArgs;
#define POPT_QUERYBYPKGID -1007
#define POPT_QUERYBYHDRID -1008
#define POPT_QUERYBYTID -1010
+#define POPT_WHATRECOMMENDS -1011
+#define POPT_WHATSUGGESTS -1012
+#define POPT_WHATSUPPLEMENTS -1013
+#define POPT_WHATENHANCES -1014
/* ========== Query/Verify/Signature source args */
static void rpmQVSourceArgCallback( poptContext con,
@@ -45,6 +49,10 @@ static void rpmQVSourceArgCallback( poptContext con,
case 'p': qva->qva_source |= RPMQV_RPM; break;
case POPT_WHATPROVIDES: qva->qva_source |= RPMQV_WHATPROVIDES; break;
case POPT_WHATREQUIRES: qva->qva_source |= RPMQV_WHATREQUIRES; break;
+ case POPT_WHATRECOMMENDS: qva->qva_source |= RPMQV_WHATRECOMMENDS; break;
+ case POPT_WHATSUGGESTS: qva->qva_source |= RPMQV_WHATSUGGESTS; break;
+ case POPT_WHATSUPPLEMENTS: qva->qva_source |= RPMQV_WHATSUPPLEMENTS; break;
+ case POPT_WHATENHANCES: qva->qva_source |= RPMQV_WHATENHANCES; break;
case POPT_TRIGGEREDBY: qva->qva_source |= RPMQV_TRIGGEREDBY; break;
case POPT_QUERYBYPKGID: qva->qva_source |= RPMQV_PKGID; break;
case POPT_QUERYBYHDRID: qva->qva_source |= RPMQV_HDRID; break;
@@ -93,6 +101,14 @@ struct poptOption rpmQVSourcePoptTable[] = {
N_("query/verify the package(s) which require a dependency"), "CAPABILITY" },
{ "whatprovides", '\0', 0, 0, POPT_WHATPROVIDES,
N_("query/verify the package(s) which provide a dependency"), "CAPABILITY" },
+ { "whatrecommends", '\0', 0, 0, POPT_WHATRECOMMENDS,
+ N_("query/verify the package(s) which recommends a dependency"), "CAPABILITY" },
+ { "whatsuggests", '\0', 0, 0, POPT_WHATSUGGESTS,
+ N_("query/verify the package(s) which suggests a dependency"), "CAPABILITY" },
+ { "whatsupplements", '\0', 0, 0, POPT_WHATSUPPLEMENTS,
+ N_("query/verify the package(s) which supplements a dependency"), "CAPABILITY" },
+ { "whatenhances", '\0', 0, 0, POPT_WHATENHANCES,
+ N_("query/verify the package(s) which enhances a dependency"), "CAPABILITY" },
{ "noglob", '\0', POPT_BIT_SET|POPT_ARGFLAG_DOC_HIDDEN, &giFlags, RPMGI_NOGLOB,
N_("do not glob arguments"), NULL},
@@ -115,6 +131,7 @@ static void queryArgCallback(poptContext con,
case 'c': qva->qva_flags |= QUERY_FOR_CONFIG | QUERY_FOR_LIST; break;
case 'd': qva->qva_flags |= QUERY_FOR_DOCS | QUERY_FOR_LIST; break;
case 'L': qva->qva_flags |= QUERY_FOR_LICENSE | QUERY_FOR_LIST; break;
+ case 'A': qva->qva_flags |= QUERY_FOR_ARTIFACT | QUERY_FOR_LIST; break;
case 'l': qva->qva_flags |= QUERY_FOR_LIST; break;
case 's': qva->qva_flags |= QUERY_FOR_STATE | QUERY_FOR_LIST;
break;
@@ -144,6 +161,10 @@ static void queryArgCallback(poptContext con,
qva->qva_flags |= VERIFY_CONTEXTS;
break;
+ case RPMCLI_POPT_NOCAPS:
+ qva->qva_flags |= VERIFY_CAPS;
+ break;
+
#ifdef NOTYET
case RPMCLI_POPT_FORCE:
ia->probFilter |=
@@ -174,6 +195,8 @@ struct poptOption rpmQueryPoptTable[] = {
N_("list all documentation files"), NULL },
{ "licensefiles", 'L', 0, 0, 'L',
N_("list all license files"), NULL },
+ { "artifactfiles", 'A', 0, 0, 'A',
+ N_("list all artifact files"), NULL },
{ "dump", '\0', 0, 0, POPT_DUMP,
N_("dump basic file information"), NULL },
{ NULL, 'i', POPT_ARGFLAG_DOC_HIDDEN, 0, 'i',
@@ -182,9 +205,15 @@ struct poptOption rpmQueryPoptTable[] = {
N_("list files in package"), NULL },
/* Duplicate file attr flags from packages into command line options. */
- { "noghost", '\0', POPT_BIT_CLR|POPT_ARGFLAG_DOC_HIDDEN,
+ { "noghost", '\0', POPT_BIT_SET|POPT_ARGFLAG_DOC_HIDDEN,
&rpmQVKArgs.qva_fflags, RPMFILE_GHOST,
N_("skip %%ghost files"), NULL },
+ { "noconfig", '\0', POPT_BIT_SET|POPT_ARGFLAG_DOC_HIDDEN,
+ &rpmQVKArgs.qva_fflags, RPMFILE_CONFIG,
+ N_("skip %%config files"), NULL },
+ { "noartifact", '\0', POPT_BIT_SET|POPT_ARGFLAG_DOC_HIDDEN,
+ &rpmQVKArgs.qva_fflags, RPMFILE_ARTIFACT,
+ N_("skip %%artifact files"), NULL },
{ "qf", '\0', POPT_ARG_STRING | POPT_ARGFLAG_DOC_HIDDEN, 0,
POPT_QUERYFORMAT, NULL, NULL },
@@ -228,12 +257,11 @@ struct poptOption rpmVerifyPoptTable[] = {
{ "nordev", '\0', POPT_BIT_SET|POPT_ARGFLAG_DOC_HIDDEN,
&rpmQVKArgs.qva_flags, VERIFY_RDEV,
N_("don't verify mode of files"), NULL },
- { "nocaps", '\0', POPT_BIT_SET|POPT_ARGFLAG_DOC_HIDDEN,
- &rpmQVKArgs.qva_flags, VERIFY_CAPS,
- N_("don't verify capabilities of files"), NULL },
{ "nocontexts", '\0', POPT_ARGFLAG_DOC_HIDDEN, NULL, RPMCLI_POPT_NOCONTEXTS,
N_("don't verify file security contexts"), NULL },
+ { "nocaps", '\0', POPT_ARGFLAG_DOC_HIDDEN, NULL, RPMCLI_POPT_NOCAPS,
+ N_("don't verify capabilities of files"), NULL },
{ "nofiles", '\0', POPT_BIT_SET, &rpmQVKArgs.qva_flags, VERIFY_FILES,
N_("don't verify files in package"), NULL},
{ "nodeps", '\0', 0, NULL, RPMCLI_POPT_NODEPS,