rpm -ivh
rpm -Uvh
rpm -e
Download the source rpm
rpmbuild --rebuild package.src.rpm
http://rpm.rutgers.edu/buildingpackages.html
http://www.linux-mag.com/2004-08/guru_01.html
Create .spec file
Summary: A lightweight DHCP/DNS server
Name: dnsmasq
Version: 2.7
Release: 1
Copyright: GPL
Group: System Environment/Daemons
Source: http://thekelleys.org.uk/dnsmasq/dnsmasq-2.7.tar.gz
Patch0: dnsmasq-patch1.patch
BuildRoot: /var/tmp/%{name}-buildroot
Requires: chkconfig
%description
A lightweight DHCP server, DNS forwarder and DNS server for a local network.
%prep
%tar zxvf
%build
./configure --prefix=/usr/local
%install
rm -rf %{buildroot}
mkdir -p %{buildroot}
make install prefix=%{buildroot}
%post
cat << EOF
You need to configure xxx by doing yyy.
EOF
%clean
rm -rf %{buildroot}
Copy sources to /usr/src/redhat/SOURCES
Then run
rpmbuild -ba sample.spec
rpm -Uvh
rpm -e
Download the source rpm
rpmbuild --rebuild package.src.rpm
http://rpm.rutgers.edu/buildingpackages.html
http://www.linux-mag.com/2004-08/guru_01.html
Create .spec file
Summary: A lightweight DHCP/DNS server
Name: dnsmasq
Version: 2.7
Release: 1
Copyright: GPL
Group: System Environment/Daemons
Source: http://thekelleys.org.uk/dnsmasq/dnsmasq-2.7.tar.gz
Patch0: dnsmasq-patch1.patch
BuildRoot: /var/tmp/%{name}-buildroot
Requires: chkconfig
%description
A lightweight DHCP server, DNS forwarder and DNS server for a local network.
%prep
%tar zxvf
%build
./configure --prefix=/usr/local
%install
rm -rf %{buildroot}
mkdir -p %{buildroot}
make install prefix=%{buildroot}
%post
cat << EOF
You need to configure xxx by doing yyy.
EOF
%clean
rm -rf %{buildroot}
Copy sources to /usr/src/redhat/SOURCES
Then run
rpmbuild -ba sample.spec