]> git.pld-linux.org Git - packages/varnish-libvmod-geoip.git/blob - varnish-libvmod-geoip.spec
- varnish 3.0.7 rebuild
[packages/varnish-libvmod-geoip.git] / varnish-libvmod-geoip.spec
1 #
2 # Conditional build:
3 %bcond_without  tests           # build without tests
4
5 %define vmod    geoip
6 Summary:        GeoIP Varnish module by Varnish Software
7 Name:           varnish-libvmod-%{vmod}
8 Version:        0.2
9 Release:        2
10 License:        BSD
11 Group:          Daemons
12 Source0:        https://github.com/varnish/libvmod-geoip/archive/libvmod-%{vmod}-%{version}.tar.gz
13 # Source0-md5:  482204cf88cd5fe4302d14daf07d48ac
14 URL:            https://github.com/varnish/libvmod-geoip
15 BuildRequires:  autoconf >= 2.59
16 BuildRequires:  automake
17 BuildRequires:  libtool
18 BuildRequires:  varnish-source >= 3.0
19 %{?with_tests:BuildRequires:    varnish}
20 %requires_eq_to varnish varnish-source
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %define         vmoddir %(pkg-config --variable=vmoddir varnishapi || echo ERROR)
24
25 %description
26 Varnish GeoIP Lookup Module
27
28 This Varnish module exports functions to look up GeoIP country codes.
29
30 %prep
31 %setup -qc
32 mv libvmod-%{vmod}-*/* .
33
34 %build
35 %{__libtoolize}
36 %{__aclocal} -I m4
37 %{__autoheader}
38 %{__automake}
39 %{__autoconf}
40
41 VARNISHSRC=$(pkg-config --variable=srcdir varnishapi)
42 %configure \
43         VARNISHSRC=$VARNISHSRC \
44         VMODDIR=%{vmoddir} \
45         --disable-static
46
47 %{__make}
48 %{?with_tests:%{__make} check}
49
50 %install
51 rm -rf $RPM_BUILD_ROOT
52 %{__make} install \
53         DESTDIR=$RPM_BUILD_ROOT
54
55 %{__rm} $RPM_BUILD_ROOT%{_libdir}/varnish/vmods/libvmod_%{vmod}.la
56 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/libvmod-%{vmod}
57
58 %clean
59 rm -rf $RPM_BUILD_ROOT
60
61 %files
62 %defattr(644,root,root,755)
63 %doc README.rst
64 %attr(755,root,root) %{vmoddir}/libvmod_%{vmod}.so
65 %{_mandir}/man3/vmod_%{vmod}.3*
This page took 0.100626 seconds and 3 git commands to generate.