]> git.pld-linux.org Git - packages/libmnl.git/blob - libmnl.spec
rpm version for noarch subpackage
[packages/libmnl.git] / libmnl.spec
1 #
2 # Conditional build:
3 %bcond_without  apidocs         # do not build and package API docs
4 %bcond_without  static_libs     # don't build static libraries
5
6 Summary:        A minimalistic user-space library oriented to Netlink developers
7 Summary(pl.UTF-8):      Minimalistyczna biblioteka przestrzeni użytkownika dla programistów Netlinka
8 Name:           libmnl
9 Version:        1.0.5
10 Release:        1
11 License:        LGPL v2.1+
12 Group:          Libraries
13 Source0:        http://www.netfilter.org/projects/libmnl/files/%{name}-%{version}.tar.bz2
14 # Source0-md5:  0bbb70573119ec5d49435114583e7a49
15 URL:            http://www.netfilter.org/projects/libmnl/index.html
16 BuildRequires:  autoconf >= 2.50
17 BuildRequires:  automake >= 1.6
18 %{?with_apidocs:BuildRequires:  doxygen}
19 BuildRequires:  libtool >= 2:2
20 BuildRequires:  rpm-build >= 4.6
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %description
24 libmnl is a minimalistic user-space library oriented to Netlink
25 developers. There are a lot of common tasks in parsing, validating,
26 constructing of both the Netlink header and TLVs that are repetitive
27 and easy to get wrong. This library aims to provide simple helpers
28 that allows you to re-use code and to avoid re-inventing the wheel.
29 The main features of this library are:
30
31 - Small: the shared library requires around 30kB for an x86-based
32   computer.
33 - Simple: this library avoids complexity and elaborated abstractions
34   that tend to hide Netlink details.
35 - Easy to use: the library simplifies the work for Netlink-wise
36   developers. It provides functions to make socket handling, message
37   building, validating, parsing and sequence tracking, easier.
38 - Easy to re-use: you can use the library to build your own
39   abstraction layer on top of this library.
40 - Decoupling: the interdependency of the main bricks that compose the
41   library is reduced, i.e. the library provides many helpers, but the
42   programmer is not forced to use them.
43
44 %description -l pl.UTF-8
45 libmnl to minimalistyczna biblioteka przestrzeni użytkownika
46 przeznaczona dla programistów interfejsu Netlink. Wiele wspólnych
47 zadań, takich jak analiza, sprawdzanie poprawności i tworzenie zarówno
48 nagłówka Netlink, jak i TLV jest powtarzalnych i łatwo w nich o błędy.
49 Ta biblioteka ma na celu dostarczenie prostych funkcji pomocniczych,
50 pozwalających wykorzystywać ten sam kod i zapobiegająca wynajdowaniu
51 koła na nowo. Główne cechy tej biblioteki to:
52  - mały rozmiar: biblioteka współdzielona dla x86 wymaga ok. 30kB
53  - prostota: biblioteka unika złożoności i szczegółowych abstrakcji,
54    które kryją się w szczegółach Netlinka
55  - łatwość użycia: biblioteka upraszcza pracę programistów interfejsu
56    Netlink; dostarcza funkcje ułatwiające obsługę gniazd, tworzenie
57    komunikatów, sprawdzanie poprawności, analizę i śledzenie sekwencji
58  - łatwość ponownego wykorzystania: biblioteki można użyć do stworzenia
59    własnej warstwy abstrakcji poziom wyżej
60  - niezależność: zależności między poszczególnymi elementami biblioteki
61    są ograniczone, tzn. biblioteka udostępnia wiele funkcji pomocniczych,
62    ale programista nie musi używać ich wszystkich.
63
64 %package devel
65 Summary:        Header files for libmnl library
66 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki libmnl
67 Group:          Development/Libraries
68 Requires:       %{name} = %{version}-%{release}
69
70 %description devel
71 Header files for libmnl library.
72
73 %description devel -l pl.UTF-8
74 Pliki nagłówkowe biblioteki libmnl.
75
76 %package static
77 Summary:        Static libmnl library
78 Summary(pl.UTF-8):      Statyczna biblioteka libmnl
79 Group:          Development/Libraries
80 Requires:       %{name}-devel = %{version}-%{release}
81
82 %description static
83 Static libmnl library.
84
85 %description static -l pl.UTF-8
86 Statyczna biblioteka libmnl.
87
88 %package apidocs
89 Summary:        libmnl API documentation
90 Summary(pl.UTF-8):      Dokumentacja API biblioteki libmnl
91 Group:          Documentation
92 BuildArch:      noarch
93
94 %description apidocs
95 API and internal documentation for libmnl library.
96
97 %description apidocs -l pl.UTF-8
98 Dokumentacja API biblioteki libmnl.
99
100 %prep
101 %setup -q
102
103 %build
104 %{__libtoolize}
105 %{__aclocal} -I m4
106 %{__autoconf}
107 %{__autoheader}
108 %{__automake}
109 %configure \
110         --disable-silent-rules \
111         %{?with_static_libs:--enable-static} \
112         %{!?with_apidocs:--without-doxygen}
113 %{__make}
114 %{?with_apidocs:doxygen doxygen.cfg}
115
116 %install
117 rm -rf $RPM_BUILD_ROOT
118
119 %{__make} install \
120         DESTDIR=$RPM_BUILD_ROOT
121
122 %clean
123 rm -rf $RPM_BUILD_ROOT
124
125 %post   -p /sbin/ldconfig
126 %postun -p /sbin/ldconfig
127
128 %files
129 %defattr(644,root,root,755)
130 %doc README
131 %attr(755,root,root) %{_libdir}/libmnl.so.*.*.*
132 %attr(755,root,root) %ghost %{_libdir}/libmnl.so.0
133
134 %files devel
135 %defattr(644,root,root,755)
136 %attr(755,root,root) %{_libdir}/libmnl.so
137 %{_libdir}/libmnl.la
138 %{_includedir}/libmnl
139 %{_pkgconfigdir}/libmnl.pc
140
141 %if %{with static_libs}
142 %files static
143 %defattr(644,root,root,755)
144 %{_libdir}/libmnl.a
145 %endif
146
147 %if %{with apidocs}
148 %files apidocs
149 %defattr(644,root,root,755)
150 %doc doxygen/html/*
151 %endif
This page took 0.080446 seconds and 3 git commands to generate.