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