]> git.pld-linux.org Git - packages/libnftnl.git/blob - libnftnl.spec
- updated to 1.0.6
[packages/libnftnl.git] / libnftnl.spec
1 #
2 # Conditional build:
3 %bcond_without  apidocs         # API documentation
4 %bcond_without  static_libs     # static libraries
5 %bcond_without  jansson         # JSON parsing support (via jansson)
6 %bcond_without  mxml            # XML parsing support (via mxml)
7
8 Summary:        Netfilter nf_tables infrastructure library
9 Summary(pl.UTF-8):      Biblioteka infrastruktury nf_tables netfiltra
10 Name:           libnftnl
11 Version:        1.0.6
12 Release:        1
13 License:        GPL v2+
14 Group:          Libraries
15 Source0:        http://www.netfilter.org/projects/libnftnl/files/%{name}-%{version}.tar.bz2
16 # Source0-md5:  6d7f9f161538ca7efd535dcc70caf964
17 URL:            http://www.netfilter.org/projects/libnftnl/
18 BuildRequires:  autoconf >= 2.50
19 BuildRequires:  automake >= 1.6
20 %{?with_apidocs:BuildRequires:  doxygen}
21 %{?with_jansson:BuildRequires:  jansson-devel >= 2.3}
22 BuildRequires:  libmnl-devel >= 1.0.0
23 BuildRequires:  libtool >= 2:2
24 BuildRequires:  linux-libc-headers >= 7:3.14
25 %{?with_mxml:BuildRequires:     mxml-devel >= 2.6}
26 %{?with_jansson:Requires:       jansson >= 2.3}
27 Requires:       libmnl >= 1.0.0
28 %{?with_mxml:Requires:  mxml >= 2.6}
29 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31 %description
32 libnftnl is a userspace library providing a low-level netlink
33 programming interface (API) to the in-kernel nf_tables subsystem. The
34 library libnftnl has been previously known as libnftables. This
35 library is currently used by nftables.
36
37 %description -l pl.UTF-8
38 libnftnl to biblioteka przestrzeni użytkownika udostępniająca
39 niskopoziomowy interfejs programistyczny (API) netlink do podsystemu
40 nf_tables w jądrze. Wcześniej biblioteka nazywała się libnftables.
41 Jest obecnie używana przez narzędzie nftables.
42
43 %package devel
44 Summary:        Header files for libnftnl library
45 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki libnftnl
46 Group:          Development/Libraries
47 Requires:       %{name} = %{version}-%{release}
48 Requires:       libmnl-devel >= 1.0.0
49
50 %description devel
51 Header files for libnftnl library.
52
53 %description devel -l pl.UTF-8
54 Pliki nagłówkowe biblioteki libnftnl.
55
56 %package static
57 Summary:        Static libnftnl library
58 Summary(pl.UTF-8):      Statyczna biblioteka libnftnl
59 Group:          Development/Libraries
60 Requires:       %{name}-devel = %{version}-%{release}
61
62 %description static
63 Static libnftnl library.
64
65 %description static -l pl.UTF-8
66 Statyczna biblioteka libnftnl.
67
68 %package apidocs
69 Summary:        libnftnl API documentation
70 Summary(pl.UTF-8):      Dokumentacja API biblioteki libnftnl
71 Group:          Documentation
72 %if "%{_rpmversion}" >= "5"
73 BuildArch:      noarch
74 %endif
75
76 %description apidocs
77 API and internal documentation for libnftnl library.
78
79 %description apidocs -l pl.UTF-8
80 Dokumentacja API biblioteki libnftnl.
81
82 %prep
83 %setup -q
84
85 %build
86 %{__libtoolize}
87 %{__aclocal} -I m4
88 %{__autoconf}
89 %{__autoheader}
90 %{__automake}
91 %configure \
92         --disable-silent-rules \
93         %{?with_static_libs:--enable-static} \
94         %{?with_jansson:--with-json-parsing} \
95         %{?with_mxml:--with-xml-parsing}
96
97 %{__make}
98
99 %{?with_apidocs:doxygen doxygen.cfg}
100
101 %install
102 rm -rf $RPM_BUILD_ROOT
103
104 %{__make} install \
105         DESTDIR=$RPM_BUILD_ROOT
106
107 # obsoleted by pkg-config
108 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libnftnl.la
109
110 %clean
111 rm -rf $RPM_BUILD_ROOT
112
113 %post   -p /sbin/ldconfig
114 %postun -p /sbin/ldconfig
115
116 %files
117 %defattr(644,root,root,755)
118 %attr(755,root,root) %{_libdir}/libnftnl.so.*.*.*
119 %attr(755,root,root) %ghost %{_libdir}/libnftnl.so.4
120
121 %files devel
122 %defattr(644,root,root,755)
123 %attr(755,root,root) %{_libdir}/libnftnl.so
124 %{_includedir}/libnftnl
125 %{_pkgconfigdir}/libnftnl.pc
126
127 %if %{with static_libs}
128 %files static
129 %defattr(644,root,root,755)
130 %{_libdir}/libnftnl.a
131 %endif
132
133 %if %{with apidocs}
134 %files apidocs
135 %defattr(644,root,root,755)
136 %doc doxygen/html/*
137 %endif
This page took 0.058022 seconds and 3 git commands to generate.