Right now, the only configuration of RPM is available via the
/etc/rpmrc
file. An example one looks like:
require_vendor: 1
require_distribution: 1
require_group: 1
distribution: RHCL 2.0
vendor: Red Hat Software
arch_sensitive: 1
topdir: /usr/src/redhat-2.0
optflags: i386 -O2 -m486
optflags: axp -O2
The require_vendor
line causes RPM to require that it find
a vendor line. This can come from the /etc/rpmrc
or from the
header of the spec file itself. To turn this off, change the number to
0
. The same holds true for the require_distribution
and
require_group
lines.
The next line is the distribution
line. You can define that here
or later in the header of the spec file. When building for a particular
distribution, it's a good idea to make sure this line is correct, even though
it is not required. The vendor
line works much the same way, but
can be anything (ie. Joe's Software and Rock Music Emporium).
The next line is arch_sensitive
. This specifies where the binary
RPMs go and what they are named. Right now, i386 is defined as
a type within RPM. That means if you are building on an Intel machine
and have this value set to true, your RPMs will go in
/usr/src/redhat-2.0/RPMS/i386/
and their name will be something
like foobar-1.0-1.i386.rpm
. If you set this value to 0
,
the RPMs will be placed in /usr/src/redhat-2.0/RPMS/
and will
be named something like foobar-1.0-1.bin.rpm
. This does not
affect the name or placement of the source RPM, however.
RPM also now has support for building packages on multiple architectures.
The rpmrc
file can hold an ``optflags'' variable for building things
that require architecture specific flags when building. See later sections
for how to use this variable.
In addition to the above macros, there are several more. You can use:
topdir
to specify the top level directory for building. In
Red Hat 2.0, this directory is /usr/src/redhat-2.0
.specdir
is the directory under topdir to use for the spec files.
The default for this is SPECS
. builddir
specifies the top level of the build directory. The
default for this is BUILD
.sourcedir
specifies the top level of the source directory. The
default for this is SOURCES
. This is where the pristine tar files,
the patches, and the icons go.rpmdir
sets the directory for the binary RPMs. The default for
this is RPMS
.srcrpmdir
sets the directory for the source RPMs. The default
for this is SRPMS
.docdir
specifies where the documentation should be installed.
By default, this is /usr/doc
.libdir
sets the path for the RPM database. By default, this is
/var/lib/rpm
.timecheck
sets whether or not to do a timecheck by default.Last Modified: 16 March 1996
St. Louis Unix Users Group - Linux SIG