mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
879 B
879 B
Building a CGRateS RPM package for RHEL/Centos/Oracle Linux/Scientific Linux/Fedora
This document provides step-by-step instructions on building a CGRateS .rpm package.
Prerequisites
- Go
- Git
- rpm-build and make packages.
Install the packages using the following command:
sudo dnf install rpm-build make
Build Instructions
- Create a build environment:
- Create necessary directories:
mkdir -p $HOME/cgr_build/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
- Download the source file. Replace
[GIT_COMMIT]with the actual commit hash.
wget -P $HOME/cgr_build/SOURCES https://github.com/cgrates/cgrates/archive/[GIT_COMMIT].tar.gz
- Place
cgrates.specfile into$HOME/cgr_build/SPECSdirectory.
- Build the package:
cd $HOME/cgr_build
rpmbuild -bb --define "_topdir $HOME/cgr_build" SPECS/cgrates.spec