Added ipcalc package from initscripts

This commit is contained in:
Nikos Mavrogiannopoulos 2015-05-18 14:52:21 +02:00
parent bc3200f6b6
commit 273df598b5
3 changed files with 52 additions and 0 deletions

1
.gitignore vendored
View File

@ -0,0 +1 @@
/0.1.0.tar.gz

50
ipcalc.spec Normal file
View File

@ -0,0 +1,50 @@
Name: ipcalc
Version: 0.1.0
Release: 1%{?dist}
Summary: IP network address calculator
# This is an updated version of ipcalc originally found
# in Fedora's initscripts at:
# https://fedorahosted.org/releases/i/n/initscripts/
License: GPLv2+
URL: https://github.com/nmav/ipcalc
Source0: https://github.com/nmav/ipcalc/archive/%{version}.tar.gz
BuildRequires: GeoIP-devel
BuildRequires: popt-devel
# Explicitly conflict with older initscript packages that ship ipcalc
Conflicts: initscripts < 9.63
%description
ipcalc provides a simple way to calculate IP information for a host.
The various options specify what information ipcalc should display
on standard out. Multiple options may be specified. An IP address to
operate on must always be specified. Most operations also require a
netmask or a CIDR prefix as well.
%prep
%setup -q
%build
CFLAGS="${CFLAGS:-%optflags}" LIBPATH=%{_libdir} make %{?_smp_mflags}
%install
mkdir -p %{buildroot}%{_bindir}
install -p -m 755 ipcalc %{buildroot}%{_bindir}/
mkdir -p -m 755 %{buildroot}%{_mandir}/man1
install -p -m 644 ipcalc.1 %{buildroot}%{_mandir}/man1
%check
make check
%files
%{_bindir}/ipcalc
%license COPYING
%doc README.md
%{_mandir}/man1/ipcalc.1*
%changelog
* Mon May 18 2015 Nikos Mavrogiannopoulos <nmav@redhat.com> - 0.1.0-1
- First independent release outside initscripts

View File

@ -0,0 +1 @@
7dc1cf323da528331722809e58c613ee 0.1.0.tar.gz