Note about using "mock" tool to build RPMs
Building sipXecs RPMs for Fedora and CentOS/RHEL requires using the mock tool. This is necessary because sipXecs is made up of many RPMs that depend on each other for compiling.
Although using mock adds a layer of complexity if you build RPMs often, you'll appreciate some of it's advantages:
- You can build for different distributions than the build machine, including building 32 bit RPMs on a 64 bit build machine.
- You can test RPM installation scripts w/o actually installing them on your build machine
- If you follow these instructions, your build machine can also act as a yum repository available on your network. So you can point your test/production systems directly to your build machine to pull in updates.
Step 1 : Setting up build machine
You can use CentOS or Fedora for build machine but the latest 64 bit version of Fedora is recommended. A single build machine will safely compile for all target CentOS and Fedora versions, both 32 and 64 bit.
A build machine of at least CentOS 6 is required to build the sipxecs 4.6 or later versions
You'll want to build as non-root user and you may not even want to give the user sudo permissions. That is up to you. The build process itself does not require root permissions.
You will need a system with a reasonable (50GB) amount of disk space available in
Step 2 : Install preliminary packages
You'll need to be root in install these basic packages.
Step 3 : Get code and initialize
This can take a while as the archive is not small. As of 31 Jan 2012, the repository is 1.5 GB
Step 4 : Setup environment.
We can generate a shell script custom to your machine that will set the machine up for building. It would be a good idea to review the setup.sh script to understand what it does, and to adjust script to your preference by editing it. You should be able to regenerate and rerun setup.sh script anytime you think it's necessary.
Step 5 : Building rpms
You can build any single RPM on many distributions or architectures from this single directory. Remember, just because your machine is running Fedora 30 for the Atari 2600, doesn't mean you cannot build RPMs for any other distribution. In fact the default distribution at the time I write this documentation is CentOS 6 64bit.
Here are some standard targets: