]> git.pld-linux.org Git - packages/libmaxminddb.git/blob - libmaxminddb.spec
- release 2 (by relup.sh)
[packages/libmaxminddb.git] / libmaxminddb.spec
1 #
2 # Conditional build:
3 %bcond_without  static_libs     # don't build static libraries
4 %bcond_without  tests           # build without tests
5
6 Summary:        Library for working with MaxMind DB files
7 Name:           libmaxminddb
8 Version:        0.5.3
9 Release:        2
10 License:        LGPL v2.1+
11 Group:          Libraries
12 Source0:        https://github.com/maxmind/libmaxminddb/releases/download/%{version}/%{name}-%{version}.tar.gz
13 # Source0-md5:  4ee5932468c308b7e7a3780f7550d713
14 URL:            http://maxmind.github.io/libmaxminddb/
15 %if %{with tests}
16 BuildRequires:  perl(Test::More) >= 0.88
17 BuildRequires:  perl-IPC-Run3
18 BuildRequires:  perl-Test-Output
19 %endif
20 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21
22 %description
23 The libmaxminddb library provides a C library for reading MaxMind DB
24 files, including the GeoIP2 databases from MaxMind. This is a custom
25 binary format designed to facilitate fast lookups of IP addresses
26 while allowing for great flexibility in the type of data associated
27 with an address.
28
29 %package devel
30 Summary:        Header files for %{name} library
31 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki %{name}
32 Group:          Development/Libraries
33 Requires:       %{name} = %{version}-%{release}
34
35 %description devel
36 Header files for %{name} library.
37
38 %description devel -l pl.UTF-8
39 Pliki nagłówkowe biblioteki %{name}.
40
41 %package static
42 Summary:        Static %{name} library
43 Summary(pl.UTF-8):      Statyczna biblioteka %{name}
44 Group:          Development/Libraries
45 Requires:       %{name}-devel = %{version}-%{release}
46
47 %description static
48 Static %{name} library.
49
50 %description static -l pl.UTF-8
51 Statyczna biblioteka %{name}.
52
53 %prep
54 %setup -q
55
56 %build
57 %configure \
58         %{!?with_static_libs:--disable-static}
59 %{__make}
60 %{?with_tests:%{__make} check}
61
62 %install
63 rm -rf $RPM_BUILD_ROOT
64 %{__make} install \
65         DESTDIR=$RPM_BUILD_ROOT
66
67 %clean
68 rm -rf $RPM_BUILD_ROOT
69
70 %post   -p /sbin/ldconfig
71 %postun -p /sbin/ldconfig
72
73 %files
74 %defattr(644,root,root,755)
75 %attr(755,root,root) %{_bindir}/mmdblookup
76 %attr(755,root,root) %{_libdir}/libmaxminddb.so.*.*.*
77 %attr(755,root,root) %ghost %{_libdir}/libmaxminddb.so.0
78
79 %files devel
80 %defattr(644,root,root,755)
81 %doc doc/libmaxminddb.md
82 %attr(755,root,root) %{_libdir}/%{name}.so
83 %{_includedir}/maxminddb.h
84 %{_includedir}/maxminddb_config.h
85 %{_libdir}/libmaxminddb.la
86 %{_mandir}/man3/MMDB_*.3
87 %{_mandir}/man3/libmaxminddb.3*
88
89 %if %{with static_libs}
90 %files static
91 %defattr(644,root,root,755)
92 %{_libdir}/libmaxminddb.a
93 %endif
This page took 0.061332 seconds and 3 git commands to generate.