[ipv6calc/f22] new release 0.98.0
pbiering
pbiering at fedoraproject.org
Sat Feb 21 14:27:17 UTC 2015
commit 5b9e1cbc9db22a65c95a9793c420093b651efac4
Author: Peter Bieringer <pb at bieringer.de>
Date: Sat Feb 21 15:27:12 2015 +0100
new release 0.98.0
.gitignore | 1 +
ipv6calc.spec | 196 +++++++++++++++++++++++++++++++++++++++++++++++++---------
sources | 3 +-
3 files changed, 168 insertions(+), 32 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index c56dcb7..0736347 100644
--- a/.gitignore
+++ b/.gitignore
@@ -15,3 +15,4 @@ ipv6calc-0.73.0.tar.gz
/ipv6calc-0.97.2.tar.gz
/ipv6calc-0.97.3.tar.gz
/ipv6calc-0.97.4.tar.gz
+/ipv6calc-0.98.0.tar.gz
diff --git a/ipv6calc.spec b/ipv6calc.spec
index b475617..5a1decf 100644
--- a/ipv6calc.spec
+++ b/ipv6calc.spec
@@ -1,21 +1,59 @@
-#define headtag .head.20140802.084646
+#define headtag .rc4.head.20150221.115120
Summary: IPv6 address format change and calculation utility
Name: ipv6calc
-Version: 0.97.4%{?headtag}
-Release: 7%{?dist}
+Version: 0.98.0%{?headtag}
+Release: 8%{?dist}
Group: Applications/Text
URL: http://www.deepspace6.net/projects/%{name}.html
License: GPLv2
Source: ftp://ftp.bieringer.de/pub/linux/IPv6/ipv6calc/%{name}-%{version}.tar.gz
BuildRequires: openssl-devel
-BuildRequires: %{_bindir}/iconv
BuildRequires: perl(Digest::MD5), perl(Digest::SHA1), perl(URI::Escape)
BuildRequires: perl(strict), perl(warnings)
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+
+# database support (deselectable)
+%if "%{?_without_ip2location:0}%{?!_without_ip2location:1}" == "1"
+%define enable_ip2location 1
+%endif
+
+%if "%{?_without_geoip:0}%{?!_without_geoip:1}" == "1"
+%define enable_geoip 1
+%endif
+
+%if "%{?_without_dbip:0}%{?!_without_dbip:1}" == "1"
+%define enable_dbip 1
+%endif
+
+%if "%{?_without_external:0}%{?!_without_external:1}" == "1"
+%define enable_external 1
+%endif
+
+%if "%{?_without_shared:0}%{?!_without_shared:1}" == "1"
+%define enable_shared 1
+%endif
+
+
+# database locations
+%define ip2location_db %{_datadir}/IP2Location
+%define geoip_db %{_datadir}/GeoIP
+%define dbip_db %{_datadir}/DBIP
+%define external_db %{_datadir}/%{name}/db
+
+
+# Berkeley DB selector
+%define require_db4 %(echo "%{dist}" | egrep -q '^\.el(5|6)$' && echo 1 || echo 0)
+%if %{require_db4}
+BuildRequires: db4-devel
+%else
+BuildRequires: libdb-devel
+%endif
+
+
%description
ipv6calc is a small utility which formats and calculates IPv4/IPv6 addresses
in different ways.
@@ -34,87 +72,185 @@ Also this package contains additional programs
- ipv6logstats: create statistics from list of IPv4/IPv6 addresses
(examples included for use with gnu-plot)
+Support for following databases
+ - IP2Location %{?enable_ip2location:ENABLED}%{?!enable_ip2location:DISABLED}
+ default directory for downloaded db files: %{ip2location_db}
+ (requires also external library on system)
+
+ - GeoIP %{?enable_geoip:ENABLED}%{?!enable_geoip:DISABLED}
+ default directory for downloaded db files: %{geoip_db}
+ (requires also external library on system)
+
+ - db-ip.com %{?enable_dbip:ENABLED}%{?!enable_dbip:DISABLED}
+ (once generated database files are found on system)
+ default directory for generated db files: %{dbip_db}
+
+ - External %{?enable_external:ENABLED}%{?!enable_external:DISABLED}
+ default directory for generated db files: %{external_db}
+
+Built %{?enable_shared:WITH}%{?!enable_shared:WITHOUT} shared-library
+
+Available rpmbuild rebuild options:
+ --without ip2location
+ --without geoip
+ --without dbip
+ --without external
+ --without shared
+
%package ipv6calcweb
-Summary: IP address information web utility
-Group: Applications/Internet
-Requires: ipv6calc httpd
-Requires: perl(URI) perl(Digest::SHA1) perl(Digest::MD5)
-BuildRequires: perl(URI) perl(Digest::SHA1) perl(Digest::MD5)
+Summary: IP address information web utility
+Group: Applications/Internet
+Requires: ipv6calc httpd
+Requires: perl(URI) perl(Digest::SHA1) perl(Digest::MD5) perl(HTML::Entities)
+BuildRequires: perl(URI) perl(Digest::SHA1) perl(Digest::MD5) perl(HTML::Entities)
%description ipv6calcweb
ipv6calcweb contains a CGI program and a configuration file for
displaying information of IP addresses on a web page using ipv6calc.
+Check/addjust %{_sysconfdir}/httpd/conf.d/ipv6calcweb.conf
+Default restricts access to localhost
+
%prep
%setup -q
-%configure --enable-ip2location --with-ip2location-dynamic --with-ip2location-headers-fallback --enable-geoip --with-geoip-dynamic --with-geoip-headers-fallback
+%configure \
+ %{?enable_ip2location:--enable-ip2location} \
+ %{?enable_ip2location:--with-ip2location-dynamic --with-ip2location-headers-fallback} \
+ --with-ip2location-db=%{ip2location_db} \
+ %{?enable_geoip:--enable-geoip} \
+ %{?enable_geoip:--with-geoip-dynamic --with-geoip-headers-fallback} \
+ --with-geoip-db=%{geoip_db} \
+ %{?enable_dbip:--enable-dbip} \
+ --with-dbip-db=%{dbip_db} \
+ %{?enable_external:--enable-external} \
+ --with-external-db=%{external_db} \
+ %{?enable_shared:--enable-shared}
%build
+make clean
make %{?_smp_mflags} COPTS="$RPM_OPT_FLAGS"
-
+
+
%install
rm -rf %{buildroot}
make install DESTDIR=%{buildroot}
-# Copy examples and helper files together
-mkdir -p redhat/{ipv6logconv,ipv6logstats/examples-{data,gri}}
-chmod 644 examples/analog/run_analog.sh
-cp -p examples/analog/run_analog.sh redhat/ipv6logconv
-chmod 644 ipv6logstats/{collect_ipv6logstats.pl,example_ipv6logstats.sh}
-cp -pf examples/analog/{analog-,ipv6calc.tab}* redhat/ipv6logconv
-cp -pf ipv6logstats/{README,collect_,example_}* redhat/ipv6logstats
-cp -pf ipv6logstats/examples-data/*.txt redhat/ipv6logstats/examples-data
-cp -pf ipv6logstats/examples-gri/*.gri redhat/ipv6logstats/examples-gri
+## Install examples and helper files
+install -d -p %{buildroot}%{_docdir}/%{name}-%{version}/
# tools
install -d %{buildroot}%{_datadir}/%{name}/tools
-for tool in GeoIP-update.sh IP2Location-update.sh; do
- install -m 755 tools/$tool %{buildroot}%{_datadir}/%{name}/tools
+cat <<END | while read tool; do install -m 755 tools/$tool %{buildroot}%{_datadir}/%{name}/tools; done
+GeoIP-update.sh
+IP2Location-update.sh
+DBIP-update.sh
+DBIP-generate-db.pl
+ipv6calc-create-registry-list-ipv4.pl
+ipv6calc-create-registry-list-ipv6.pl
+ipv6calc-db-update.sh
+ipv6calc-registries-check-run-create.sh
+ipv6calc-update-registries.sh
+END
+
+## examples
+install -d %{buildroot}%{_datadir}/%{name}/examples/
+
+# ipv6logconv
+install -d %{buildroot}%{_datadir}/%{name}/examples/ipv6logconv
+for file in examples/analog/*.{cfg,txt,tab,sh}; do
+ install $file %{buildroot}%{_datadir}/%{name}/examples/ipv6logconv/
+done
+
+# ipv6loganon
+install -d %{buildroot}%{_datadir}/%{name}/examples/ipv6loganon
+for file in ipv6loganon/README; do
+ install $file %{buildroot}%{_datadir}/%{name}/examples/ipv6loganon/
+done
+
+# ipv6logstats
+install -d %{buildroot}%{_datadir}/%{name}/examples/ipv6logstats
+for file in ipv6logstats/README ipv6logstats/example_* ipv6logstats/collect_ipv6logstats.pl; do
+ install $file %{buildroot}%{_datadir}/%{name}/examples/ipv6logstats/
done
-# ipv6calcweb
-mkdir -p redhat-ipv6calcweb
-cp -pf ipv6calcweb/USAGE redhat-ipv6calcweb
+# db directory
+install -d %{buildroot}%{external_db}
+
+
+# ipv6calcweb
install -d %{buildroot}%{_sysconfdir}/httpd/conf.d
install -d %{buildroot}%{_localstatedir}/www/cgi-bin
-install -m 644 ipv6calcweb/ipv6calcweb.conf %{buildroot}%{_sysconfdir}/httpd/conf.d
+install ipv6calcweb/ipv6calcweb.conf %{buildroot}%{_sysconfdir}/httpd/conf.d
install -m 555 ipv6calcweb/ipv6calcweb.cgi %{buildroot}%{_localstatedir}/www/cgi-bin
%clean
rm -rf %{buildroot}
+
%check
%ifnarch ppc64
make test
%endif
+
%files
-%doc ChangeLog README CREDITS TODO COPYING LICENSE USAGE doc/ipv6calc.* redhat/*
+%doc ChangeLog README CREDITS TODO COPYING LICENSE USAGE doc/ipv6calc.{lyx,sgml,html,xml}
+
+# binaries
%{_bindir}/%{name}
%{_bindir}/ipv6logconv
%{_bindir}/ipv6logstats
%{_bindir}/ipv6loganon
+
+# man pages
%{_mandir}/man8/*
+
+# tools
%{_datadir}/%{name}/tools/*
+# examples
+%{_datadir}/%{name}/examples/*
+
+# shared library
+%{?enable_shared:%{_libdir}/*}
+
+# database directory
+%{external_db}
+
%files ipv6calcweb
-%defattr(-,root,root)
+%doc ipv6calcweb/README ipv6calcweb/USAGE
-%doc redhat-ipv6calcweb/*
-%{_localstatedir}/www/cgi-bin/ipv6calcweb.cgi
+%attr(555,-,-) %{_localstatedir}/www/cgi-bin/ipv6calcweb.cgi
%config(noreplace) %{_sysconfdir}/httpd/conf.d/ipv6calcweb.conf
+
%changelog
+* Fri Feb 20 2015 Peter Bieringer <pb at bieringer.de> - 0.98.0-8
+- new release 0.98.0
+
+* Wed Feb 18 2015 Peter Bieringer <pb at bieringer.de>
+- add support for conditional builds
+
+* Sat Oct 25 2014 Peter Bieringer <pb at bieringer.de>
+- add /usr/share/ipv6calc/db directory
+
+* Sat Oct 11 2014 Peter Bieringer <pb at bieringer.de>
+- add additional requirements for ipv6calc-ipv6calcweb
+- enable db-ip.com & external database support
+
* Thu Aug 28 2014 Jitka Plesnikova <jplesnik at redhat.com> - 0.97.4-7
- Perl 5.20 rebuild
+* Tue Aug 19 2014 Peter Bieringer <pb at bieringer.de> - 0.97.4-7
+- new package for EPEL6/EPEL7
+
* Sun Aug 17 2014 Peter Bieringer <pb at bieringer.de>
- add missing requirement for ipv6calc-ipv6calcweb
diff --git a/sources b/sources
index 0577f9b..3d7b0a3 100644
--- a/sources
+++ b/sources
@@ -1,2 +1 @@
-1fc9c1a14802638f21e59408faa721a6 ipv6calc-0.97.3.tar.gz
-a7414ca72f66eb6d515b58c687705d55 ipv6calc-0.97.4.tar.gz
+a85961d0c166caffbd293aaf04943d53 ipv6calc-0.98.0.tar.gz
More information about the scm-commits
mailing list