#
# spec file for package xtables-geoip
#
# Copyright (c) 2019 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


Name:           xtables-geoip
Version:        20191224
Release:        1.1
Summary:        Geolocation database files for xt_geoip
License:        CC-BY-SA-4.0
Group:          Productivity/Networking/Security
URL:            https://dev.maxmind.com/geoip/geoip2/geolite2/
# Source:       https://geolite.maxmind.com/download/geoip/database/GeoLite2-Country-CSV_%version.zip
Source:         GeoLite2-Country-CSV_%version.zip
Source4:        %name-rpmlintrc
BuildArch:      noarch
BuildRequires:  unzip
BuildRequires:  xtables-addons >= 3.2
#db format changed at that time
Conflicts:      xtables-addons < 1.33

%description
The package contains the GeoIP definition files (which IP addresses
belong to which country) that are needed for Xtables-addons's
xt_geoip module.

This product includes GeoLite data created by MaxMind, available from
http://maxmind.com/.

Author(s):
----------
	The GeoIP data is from MaxMind.com.
Please do not contact them for errors with this package.

%prep
%setup -qn GeoLite2-Country-CSV_%version

%build

%install
b="%buildroot"
mkdir -p "$b/%_datadir/xt_geoip"
%_libexecdir/xtables-addons/xt_geoip_build -D "$b/%_datadir/xt_geoip/" *.csv

%files
%defattr(-,root,root)
%_datadir/xt_geoip/

%changelog
* Fri Dec 27 2019 Arjen de Korte <suse+build@de-korte.org>
- Update database files to 20191224
* Wed Nov 13 2019 Arjen de Korte <suse+build@de-korte.org>
- Update database files to 20191112
* Wed May 22 2019 Jan Engelhardt <jengelh@inai.de>
- Update database files to 20190521
* Mon Feb  4 2019 Jan Engelhardt <jengelh@inai.de>
- Update database files to 20190129
* Fri Sep  7 2018 Jan Engelhardt <jengelh@inai.de>
- Update database files to 20180905
- Switch source to GeoLite2 format
* Tue Sep 27 2016 jengelh@inai.de
- Update database files to 2016.09.07
* Sun May  8 2016 jengelh@inai.de
- Update database files to 2016.05.03
* Thu Nov 12 2015 jengelh@inai.de
- Update database files to 2015.11.03
* Wed Aug 19 2015 jengelh@inai.de
- Update database files to 2015.08
* Fri Jul 24 2015 jengelh@inai.de
- Update database files to 2015.07
* Thu Jun 25 2015 jengelh@inai.de
- Update database files to 2015.06
* Sat Mar 28 2015 jengelh@inai.de
- Update database files to 2015.03
* Tue Dec 16 2014 jengelh@inai.de
- Update database files to 2014.12
* Fri Jun 27 2014 jengelh@inai.de
- Update DB files to 2014.06
* Thu Jan  9 2014 jengelh@inai.de
- Update DB files to 2014.01
- License change to Creative Commons Attribution-ShareAlike 3.0
  Unported License.
* Fri May 10 2013 jengelh@inai.de
- update db files to 2013.05
* Thu Mar  7 2013 jengelh@inai.de
- update db files to 2013.03
* Mon Nov 12 2012 jengelh@inai.de
- update database files to the November 2012 release
* Thu Aug 23 2012 jengelh@inai.de
- update db files to 2012.08
* Mon Jun  4 2012 jengelh@inai.de
- update db files to 2012.06
  * 634 new IPv4 ranges, 463 new IPv6 ranges
* Thu Apr  5 2012 jengelh@medozas.de
- update db files to 2012.04
* Sat Jan 14 2012 jengelh@medozas.de
- update db files to 2012.01
* Wed Jan  4 2012 jengelh@medozas.de
- update db files to 2011.12
- removing LGPL from License: field, it applies only to libGeoIP,
  which is not shipped in any form in xtables-geoip
* Wed Dec 14 2011 coolo@suse.com
- LICENSE is BSD-4-Clause and LGPL-2.1+ is mentioned
* Wed Sep 14 2011 jengelh@medozas.de
- update database files to 2011.09
* Sat Aug 20 2011 jengelh@medozas.de
- update database files to 2011.08; ~3992 new subnets
* Sun Jul 10 2011 jengelh@medozas.de
- update database files to 2011.07; ~1940 new subnets
* Sat Apr  9 2011 jengelh@medozas.de
- update database files to 2011.04; ~4500 new subnets
* Sun Feb 27 2011 jengelh@medozas.de
- Add Conflicts marker for older Xtables-addons that cannot
  interact with this version's files
* Mon Feb 14 2011 jengelh@medozas.de
- update database files to 2011.02
* Wed Feb  2 2011 jengelh@medozas.de
- update database files to 2011.01
- include ranges for new IPv6-capable xt_geoip in
  Xtables-addons 1.33
* Fri Nov  5 2010 jengelh@medozas.de
- update database files to 2010.11
* Sat Oct  9 2010 jengelh@medozas.de
- the database generation script is now packaged within
  xtables-addons; use it
- package missing network-order variants
* Sun Oct  3 2010 jengelh@medozas.de
- update database files to 2010.10
* Thu Jun  3 2010 jengelh@medozas.de
- update database files to 2010.06
* Mon May 17 2010 jengelh@medozas.de
- update database files to 2010.05
* Mon Apr 26 2010 jengelh@medozas.de
- update database files to 2010.04
* Sun Feb  7 2010 jengelh@medozas.de
- update database files to 2010.02
* Thu Jan  7 2010 jengelh@medozas.de
- update database to version 2010.01
- clarify license situation (bnc#568818)
* Thu Dec 31 2009 jengelh@medozas.de
- initial OBS package
* Sat Dec 12 2009 jengelh@medozas.de
- update to DB files from 2009-12