1/*! \page multiplebuilds Multiple build areas 2 3It is possible to run several RPM builds on the same machine using 4separate RPM databases. On my build machine I have several build 5areas which all run builds at the same time. The builds do not 6interfere with each other. Each build behaves as if it was running on 7its own machine and no build area knows about the RPM database which 8actually configures the machine. 9 10First, setup a "topdir" in a prefix other then where RPM is 11installed. You will need to make the directories. They need to be 12writable by the account which will do the building, typically they 13are owned by the buildmaster account and set to permissions 14755. 15 16\verbatim 17 BUILD RPMS SOURCES SPECS SRPMS 18\endverbatim 19 20Next, you will need to decide where the database files live. I suggest 21putting them in a separate directory under "topdir". I call my 22directory DB and it has the same owner and permissions as the other 23directories. 24 25Each separate build area needs a rpmrc and macro configuration file. This 26will need to specify the new topdir and dbpath. If you will be building 27the same packages in different work areas you will also need to specify a 28tmppath into the topdir. I suggest either making tmppath be the same as 29the BUILD directory or adding another directory called BUILDROOT for it 30in the topdir. 31 32Keeping track of the correct rpmrc for each build area can be 33difficult. To make my life easier I make a small shell script with the 34topdir hard coded inside: 35 36\verbatim 37 #!/bin/sh 38 /bin/rpm --rcfile /topdir/rpmrc "$@" 39 exit $? 40\endverbatim 41 42I call the shell script rpm and it lives in the topdir. Each time I 43wish to use a particular build area I just ensure that the build area 44is first in my path so that when I run "rpm" I get the regular rpm 45binary but I am using the local build areas rpmrc. 46 47*/ 48