1 .TH "RPMSPEC" "8" "29 October 2010" "Red Hat, Inc"
3 rpmspec \- RPM Spec Tool
5 .SS "QUERYING SPEC FILES:"
8 \fBrpmspec\fR {\fB-q|--query\fR} [\fBselect-options\fR] [\fBquery-options\fR] \fB\fISPEC_FILE\fB\fR\fI ...\fR
10 .SS "PARSING SPEC FILES TO STDOUT:"
13 \fBrpmspec\fR {\fB-P|--parse\fR} \fB\fISPEC_FILE\fB\fR\fI ...\fR
17 \fBrpmspec\fR is a tool for querying a spec file. More specifically for querying hypothetical packages which would be created from the given spec file. So querying a spec file with \fBrpmspec\fR is similar to querying a package built from that spec file. But is is not identical. With \fBrpmspec\fR you can't query all fields which you can query from a built package. E. g. you can't query BUILDTIME with \fBrpmspec\fR for obvious reasons. You also cannot query other fields automatically generated during a build of a package like auto generated dependencies.
28 [\fB--qf,--queryformat \fIQUERYFMT\fB\fR]
29 [\fB--target \fITARGET_PLATFORM\fB\fR]
33 The general form of an rpm spec query command is
36 \fBrpm\fR {\fB-q|--query\fR} [\fBselect-options\fR] [\fBquery-options\fR]
39 You may specify the format that the information should be
40 printed in. To do this, you use the
42 \fB--qf|--queryformat\fR \fB\fIQUERYFMT\fB\fR
44 option, followed by the \fIQUERYFMT\fR format string.
45 See \fBrpm(8)\fR for details.
51 Operate on the all binary package headers generated from spec.
53 Operate only on the binary package headers of packages which would be built from spec. That means ignoring package headers of packages that won't be built from spec i. e. ignoring package headers of packages without file section.
55 Operate on the source package header(s) generated from spec.
59 Get list of binary packages which would be generated from the rpm spec file:
64 rpm-4.11.3-3.fc20.x86_64
65 rpm-libs-4.11.3-3.fc20.x86_64
66 rpm-build-libs-4.11.3-3.fc20.x86_64
70 Get summary infos for single binary packages generated from the rpm spec file:
74 $ rpmspec -q --qf "%{name}: %{summary}\\n" rpm.spec
75 rpm: The RPM package management system
76 rpm-libs: Libraries for manipulating RPM packages
77 rpm-build-libs: Libraries for building and signing RPM packages
81 Get the source package which would be generated from the rpm spec file:
85 $ rpmspec -q --srpm rpm.spec
86 rpm-4.11.3-3.fc20.x86_64
89 Parse the rpm spec file to stdout:
94 Summary: The RPM package management system
110 \fBrpmspec --help\fR - as rpm supports customizing the options via popt aliases
111 it's impossible to guarantee that what's described in the manual matches
115 \fBhttp://www.rpm.org/ <URL:http://www.rpm.org/>
120 Marc Ewing <marc@redhat.com>
121 Jeff Johnson <jbj@redhat.com>
122 Erik Troan <ewt@redhat.com>
123 Panu Matilainen <pmatilai@redhat.com>