| rpm
    4.10.0
    | 
#include "system.h"#include <rpm/rpmcli.h>#include <rpm/rpmbuild.h>#include <rpm/rpmlog.h>#include <rpm/rpmts.h>#include "cliutils.h"#include "debug.h"
Go to the source code of this file.
| Enumerations | |
| enum | modes { MODE_BUILD = (1 << 4), MODE_REBUILD = (1 << 5), MODE_RECOMPILE = (1 << 8), MODE_TARBUILD = (1 << 11), MODE_INITDB = (1 << 0), MODE_REBUILDDB = (1 << 1), MODE_VERIFYDB = (1 << 2), MODE_CHECKSIG = (1 << 0), MODE_IMPORTKEY = (1 << 1), MODE_DELKEY = (1 << 2), MODE_LISTKEY = (1 << 3), MODE_QUERY = (1 << 0), MODE_VERIFY = (1 << 3), MODE_ADDSIGN = (1 << 0), MODE_RESIGN = (1 << 1), MODE_DELSIGN = (1 << 2), MODE_UNKNOWN = 0, MODE_QUERY = (1 << 0), MODE_PARSE = (1 << 1) } | 
| Functions | |
| int | main (int argc, char *argv[]) | 
| Variables | |
| const char * | program_name | 
| static int | mode = MODE_UNKNOWN | 
| static int | source = RPMQV_SPECRPMS | 
| const char * | target = NULL | 
| char * | queryformat = NULL | 
| static struct poptOption | specOptsTable [] | 
| static struct poptOption | optionsTable [] | 
| enum modes | 
| int main | ( | int | argc, | 
| char * | argv[] | ||
| ) | 
Definition at line 55 of file rpmspec.c.
References rpmQVKArgs, rpmcliInit(), rpmcliPipeOutput, initPipe(), rpmFreeMacros(), rpmFreeRpmrc(), rpmReadConfigFiles(), rpmcliRcfile, rpmtsCreate(), MODE_QUERY, argerror(), _, rpmQVKArguments_s::qva_queryFormat, queryformat, rpmQVKArguments_s::qva_source, source, rpmQVKArguments_s::qva_specQuery, rpmspecQuery(), rpmcliQuery(), MODE_PARSE, rpmSpecParse(), rpmSpecGetSection(), RPMBUILD_NONE, rpmSpecFree(), MODE_UNKNOWN, rpmIsVerbose, printUsage(), rpmtsFree(), finishPipe(), rpmcliFini(), and RETVAL.
| struct poptOption optionsTable[]  [static] | 
 {
    { NULL, '\0', POPT_ARG_INCLUDE_TABLE, specOptsTable, 0,
         "Spec options:" , NULL },
    { NULL, '\0', POPT_ARG_INCLUDE_TABLE, rpmcliAllPoptTable, 0,
         "Common options for all rpm modes and executables:" , NULL },
   POPT_AUTOALIAS
   POPT_AUTOHELP
   POPT_TABLEEND
}
| const char* program_name | 
| char* queryformat = NULL | 
| struct poptOption specOptsTable[]  [static] | 
 {
    { "parse", 'P', POPT_ARG_VAL, &mode, MODE_PARSE,
         "parse spec file(s) to stdout" , NULL },
    { "query", 'q', POPT_ARG_VAL, &mode, MODE_QUERY,
         "query spec file(s)" , NULL },
    { "rpms", 0, POPT_ARG_VAL, &source, RPMQV_SPECRPMS,
         "operate on binary rpms generated by spec (default)" , NULL },
    { "srpm", 0, POPT_ARG_VAL, &source, RPMQV_SPECSRPM,
         "operate on source rpm generated by spec" , NULL },
    { "target", 0, POPT_ARG_STRING, &target, 0,
         "override target platform" , NULL },
    { "queryformat", 0, POPT_ARG_STRING, &queryformat, 0,
         "use the following query format" , "QUERYFORMAT" },
    { "qf", 0, (POPT_ARG_STRING | POPT_ARGFLAG_DOC_HIDDEN), &queryformat, 0,
        NULL, NULL },
    POPT_TABLEEND
}
 1.7.5
 1.7.5