]> git.pld-linux.org Git - packages/boost.git/blob - boost.spec
- release 4
[packages/boost.git] / boost.spec
1 #
2 # TODO:
3 #       - think about building MPI.
4 #       - split shared libs from core package into -iostreams/-serialization.
5 #
6 # Conditional build:
7 %bcond_without  python  # without boost-python support
8 #
9 %define         fver    %(echo %{version} | tr . _)
10 Summary:        The Boost C++ Libraries
11 Summary(pl.UTF-8):      Biblioteki C++ "Boost"
12 Name:           boost
13 Version:        1.44.0
14 Release:        4
15 License:        Boost Software License and others
16 Group:          Libraries
17 Source0:        http://downloads.sourceforge.net/boost/%{name}_%{fver}.tar.bz2
18 # Source0-md5:  f02578f5218f217a9f20e9c30e119c6a
19 Patch0:         %{name}-link.patch
20 URL:            http://www.boost.org/
21 BuildRequires:  boost-jam >= 3.1.12
22 BuildRequires:  bzip2-devel
23 BuildRequires:  expat-devel
24 BuildRequires:  libicu-devel
25 BuildRequires:  libstdc++-devel
26 BuildRequires:  perl-base
27 %{?with_python:BuildRequires:   python-devel >= 2.2}
28 BuildRequires:  rpm-pythonprov
29 BuildRequires:  zlib-devel
30 BuildConflicts: gcc = 5:3.3.1
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33 %description
34 The Boost web site provides free peer-reviewed portable C++ source
35 libraries. The emphasis is on libraries which work well with the C++
36 Standard Library. One goal is to establish "existing practice" and
37 provide reference implementations so that the Boost libraries are
38 suitable for eventual standardization. Some of the libraries have
39 already been proposed for inclusion in the C++ Standards Committee's
40 upcoming C++ Standard Library Technical Report.
41
42 %description -l pl.UTF-8
43 Strona http://www.boost.org/ dostarcza darmowe biblioteki C++ wraz z
44 kodem źródłowym. Nacisk położono na biblioteki, które dobrze
45 współpracują ze standardową biblioteką C++. Celem jest ustanowienie
46 "istniejącej praktyki" i dostarczenie implementacji, tak że biblioteki
47 "Boost" nadają się do ewentualnej standaryzacji. Niektóre z bibliotek
48 już zostały zgłoszone do komitetu standaryzacyjnego C++ w nadchodzącym
49 Raporcie Technicznym Biblioteki Standardowej C++.
50
51 %package devel
52 Summary:        Boost C++ development headers
53 Summary(pl.UTF-8):      Pliki nagłówkowe bibliotek C++ Boost
54 Group:          Development/Libraries
55 Requires:       %{name} = %{version}-%{release}
56 Requires:       %{name}-date_time = %{version}-%{release}
57 Requires:       %{name}-filesystem = %{version}-%{release}
58 Requires:       %{name}-graph = %{version}-%{release}
59 Requires:       %{name}-program_options = %{version}-%{release}
60 Requires:       %{name}-regex = %{version}-%{release}
61 Requires:       %{name}-signals = %{version}-%{release}
62 Requires:       %{name}-system = %{version}-%{release}
63 Requires:       %{name}-test = %{version}-%{release}
64 Requires:       %{name}-thread = %{version}-%{release}
65 Requires:       %{name}-wave = %{version}-%{release}
66 Requires:       libstdc++-devel
67 Obsoletes:      boost-any-devel
68 Obsoletes:      boost-array-devel
69 Obsoletes:      boost-asio
70 Obsoletes:      boost-bind-devel
71 Obsoletes:      boost-call_traits-devel
72 Obsoletes:      boost-compatibility-devel
73 Obsoletes:      boost-compose-devel
74 Obsoletes:      boost-compressed_pair-devel
75 Obsoletes:      boost-concept_check-devel
76 Obsoletes:      boost-conversion-devel
77 Obsoletes:      boost-crc-devel
78 Obsoletes:      boost-date_time-devel
79 Obsoletes:      boost-filesystem-devel
80 Obsoletes:      boost-graph-devel
81 Obsoletes:      boost-mem_fn-devel
82 Obsoletes:      boost-mpl-devel
83 Obsoletes:      boost-preprocessor-devel
84 Obsoletes:      boost-program_options-devel
85 Obsoletes:      boost-ref-devel
86 Obsoletes:      boost-regex-devel
87 Obsoletes:      boost-signals-devel
88 Obsoletes:      boost-spirit-devel
89 Obsoletes:      boost-statechart-devel
90 Obsoletes:      boost-static_assert-devel
91 Obsoletes:      boost-test-devel
92 Obsoletes:      boost-thread-devel
93 Obsoletes:      boost-tr1-devel
94 Obsoletes:      boost-type_traits-devel
95 Obsoletes:      boost-typeof-devel
96 Obsoletes:      boost-uBLAS-devel
97 Obsoletes:      boost-utility-devel
98 Obsoletes:      boost-wave-devel
99 Obsoletes:      boost-xpressive-devel
100
101 %description devel
102 Header files for the Boost C++ libraries.
103
104 %description devel -l pl.UTF-8
105 Pliki nagłówkowe bibliotek C++ Boost.
106
107 %package static
108 Summary:        Static version of base Boost C++ libraries
109 Summary(pl.UTF-8):      Statyczne wersje podstawowych bibliotek C++ Boost
110 Group:          Development/Libraries
111 Requires:       %{name}-devel = %{version}-%{release}
112 Obsoletes:      boost-static < 1.33
113
114 %description static
115 Static version of base Boost C++ libraries.
116
117 %description static -l pl.UTF-8
118 Statyczne wersje podstawowych bibliotek C++ Boost.
119
120 %package python
121 Summary:        Boost.Python library
122 Summary(pl.UTF-8):      biblioteka Boost.Python
123 Group:          Libraries
124 %pyrequires_eq  python
125
126 %description python
127 Use the Boost Python Library to quickly and easily export a C++
128 library to Python such that the Python interface is very similar to
129 the C++ interface. It is designed to be minimally intrusive on your
130 C++ design. In most cases, you should not have to alter your C++
131 classes in any way in order to use them with Boost.Python. The system
132 should simply ``reflect'' your C++ classes and functions into Python.
133
134 %description python -l pl.UTF-8
135 Biblioteka Boost Python służy do szybkiego i prostego eksportu
136 biblioteki C++ do Pythona, tak że interfejs Pythona jest bardzo
137 podobny do interfejsu C++. Biblioteka jest zaprojektowana tak, żeby
138 narzucać jak najmniej wymagań dotyczących konstrukcjii C++. W
139 większości przypadków nie trzeba w ogóle zmieniać własnych klas C++,
140 żeby używać ich z Boost.Python. System powinien po prostu ,,odbić''
141 klasy C++ i funkcje do Pythona.
142
143 %package python-devel
144 Summary:        Boost.Python development headers
145 Summary(pl.UTF-8):      Pliki nagłówkowe dla Boost.Python
146 Group:          Development/Libraries
147 Requires:       %{name}-devel = %{version}-%{release}
148 Requires:       %{name}-python = %{version}-%{release}
149
150 %description python-devel
151 Headers for the Boost.Python library.
152
153 %description python-devel -l pl.UTF-8
154 Pliki nagłówkowe dla biblioteki Boost.Python.
155
156 %package python-static
157 Summary:        Static version of Boost.Python library
158 Summary(pl.UTF-8):      Statyczna wersja biblioteki Boost.Python
159 Group:          Development/Libraries
160 Requires:       %{name}-python-devel = %{version}-%{release}
161
162 %description python-static
163 Static version of Boost.Python library.
164
165 %description python-static -l pl.UTF-8
166 Statyczna wersja biblioteki Boost.Python.
167
168 %package date_time
169 Summary:        Date-Time library
170 Summary(pl.UTF-8):      Biblioteka daty-czasu
171 Group:          Libraries
172 Obsoletes:      boost < 1.33
173
174 %description date_time
175 A set of date-time libraries.
176
177 %description date_time -l pl.UTF-8
178 Zbiór bibliotek daty-czasu.
179
180 %package filesystem
181 Summary:        Portable paths, iteration over directories, and other useful filesystem operations
182 Summary(pl.UTF-8):      Przenośne ścieżki, iteracje katalogów i inne użyteczne operacje na systemie plików
183 Group:          Libraries
184 Requires:       %{name}-system = %{version}-%{release}
185 Obsoletes:      boost < 1.33
186
187 %description filesystem
188 The boost::filesystem library provides portable facilities to query
189 and manipulate paths, files, and directories.
190
191 %description filesystem -l pl.UTF-8
192 Przenośna biblioteka boost::filesystem dostarcza ułatwienia w
193 operacjach na ścieżkach, plikach i katalogach.
194
195 %package graph
196 Summary:        General purpose, generic C++ library for graph data structures and graph algorithms
197 Summary(pl.UTF-8):      Biblioteka ogólnego przeznaczenia w C++ dla struktur danych typu grafy oraz algorytmów związanych z grafami
198 Group:          Libraries
199
200 %description graph
201 The boost::graph library provides portable facilities to operate on
202 graph data structures using graph algorithms.
203
204 %description graph -l pl.UTF-8
205 Przenośna biblioteka boost::graph dostarcza ułatwienia w operacjach na
206 strukturach danych typu graf za pomocą algorytmów związanych z
207 grafami.
208
209 %package program_options
210 Summary:        Access to program options, via conventional methods such as command line and config file
211 Summary(pl.UTF-8):      Dostęp do opcji programu za pomocą typowych metod, jak linia poleceń i plik konfiguracyjny
212 Group:          Libraries
213
214 %description program_options
215 The program_options library allows program developers to obtain
216 program options, that is (name, value) pairs from the user, via
217 conventional methods such as command line and config file.
218
219 %description program_options -l pl.UTF-8
220 Biblioteka program_options umożliwia uzyskanie od użytkownika opcji
221 programu, czyli par (nazwa, wartość), za pomocą typowych metod, takich
222 jak linia poleceń, czy plik konfiguracyjny.
223
224 %package regex
225 Summary:        Boost C++ regular expressions library
226 Summary(pl.UTF-8):      Biblioteka wyrażeń regularnych Boost C++
227 Group:          Libraries
228
229 %description regex
230 Shared library for Boost C++ regular expressions.
231
232 %description regex -l pl.UTF-8
233 Biblioteka wyrażeń regularnych dla C++, biblioteki dzielone.
234
235 %package signals
236 Summary:        Signals & slots callback implementation
237 Summary(pl.UTF-8):      Implementacja sygnałów i slotów
238 Group:          Libraries
239 Obsoletes:      boost < 1.33
240
241 %description signals
242 The boost::signals library is an implementation of a signals and slots
243 system.
244
245 %description signals -l pl.UTF-8
246 Biblioteka boost::signals jest implementacją systemu sygnałów i
247 slotów.
248
249 %package system
250 Summary:        Support for getting system specific error codes
251 Summary(pl.UTF-8):      Wsparcie dla pobierania specyficznych dla systemu kodów błędów
252 Group:          Libraries
253
254 %description system
255 The Boost System library provides simple, light-weight error_code
256 objects that encapsulate system-specific error code values, yet also
257 provide access to more abstract and portable error conditions objects.
258
259 %description system -l pl.UTF-8
260 Biblioteka Boost System udostępnia proste, lekkie obiekty error_code
261 obudowujące wartości kodów błędów specyficznych dla systemu, dając
262 jednocześnie dostęp do bardziej abstrakcyjnych i przenośnych obiektów
263 błędów.
264
265 %package test
266 Summary:        Support for program testing and execution monitoring
267 Summary(pl.UTF-8):      Wsparcie dla testowania i monitorowania programu
268 Group:          Libraries
269 Obsoletes:      boost < 1.33
270
271 %description test
272 Support for simple program testing, full unit testing, and for program
273 execution monitoring.
274
275 %description test -l pl.UTF-8
276 Wsparcie dla prostego testowania programu, pełnego testowania i
277 monitorowania wykonania programu.
278
279 %package thread
280 Summary:        Portable C++ threads library
281 Summary(pl.UTF-8):      Przenośna biblioteka wątków C++
282 Group:          Libraries
283 Obsoletes:      boost < 1.33
284
285 %description thread
286 Portable C++ threads library - shared library.
287
288 %description thread -l pl.UTF-8
289 Przenośna biblioteka wątków dla C++ - biblioteka dzielona.
290
291 %package wave
292 Summary:        Boost.Wave - a standard compliant C++ preprocessor library
293 Summary(pl.UTF-8):      Boost.Wave - zgodna ze standardem biblioteka preprocesora C++
294 Group:          Development/Libraries
295
296 %description wave
297 Boost.Wave - a standard compliant C++ preprocessor library.
298
299 %description wave -l pl.UTF-8
300 Boost.Wave - zgodna ze standardem biblioteka preprocesora C++.
301
302 %package doc
303 Summary:        Boost C++ Library documentation
304 Summary(pl.UTF-8):      Dokumentacja dla biblioteki Boost C++
305 Group:          Documentation
306 Requires:       %{name}-devel = %{version}-%{release}
307
308 %description doc
309 Documentation for the Boost C++ Library.
310
311 %description doc -l pl.UTF-8
312 Dokumentacja dla biblioteki Boost C++.
313
314 %prep
315 %setup -q -n %{name}_%{fver}
316 %patch0 -p1
317
318 # - don't know how to pass it through (b)jam -s (no way?)
319 #   due to oversophisticated build flags system.
320 # - pass -fPIC due to <shared-linkable> removal.
321 %{__sed} -i "s/<optimization>speed : -O3/<optimization>speed : ${CXXFLAGS:-%rpmcxxflags} -fPIC/" tools/build/v2/tools/gcc.jam
322
323 # cleanup -g switch to avoid override debuginfocflags.
324 %{__sed} -i 's/<debug-symbols>on : -g/<debug-symbols>on :/' tools/build/v2/tools/gcc.jam
325 # link against shared expat library.
326 %{__sed} -i 's:find-static:find-shared:' libs/graph/build/Jamfile.v2
327
328 cat << EOF > tools/build/v2/user-config.jam
329 using gcc : %(%{__cxx} -dumpversion) : %{__cxx} ;
330 EOF
331
332 %build
333 %if %{with python}
334 PYTHON_VERSION=$(%{__python} -c 'import sys; print sys.version[0:3]')
335 PYTHON_ROOT=%{_prefix}
336 %else
337 PYTHON_ROOT=
338 PYTHON_VERSION=
339 %endif
340 EXPAT_INCLUDE=%{_includedir} \
341 EXPAT_LIBPATH=%{_libdir} \
342 ICU_PATH=%{_prefix} \
343 bjam \
344         -d2 --toolset=gcc \
345         variant=release debug-symbols=on inlining=on link=static,shared threading=multi
346
347 %install
348 rm -rf $RPM_BUILD_ROOT
349 install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir}}
350
351 cp -rf boost $RPM_BUILD_ROOT%{_includedir}
352
353 install -p stage/lib/lib*.a $RPM_BUILD_ROOT%{_libdir}
354 install -p stage/lib/lib*.so.*.*.* $RPM_BUILD_ROOT%{_libdir}
355 cp -a stage/lib/lib*.so $RPM_BUILD_ROOT%{_libdir}
356
357 # documentation
358 install -d $RPM_BUILD_ROOT%{_docdir}/boost-%{version}
359
360 # as the documentation doesn't completely reside in a directory of its
361 # own, we need to find out ourselves... this looks for HTML files and
362 # then collects everything linked from those.  this is certainly quite
363 # unoptimized wrt mkdir calls, but does it really matter?
364 installdocs() {
365 for i in $(find -type f -name '*.htm*'); do
366         # bjam docu is included in the boost-jam RPM
367         if test "`echo $i | sed 's,jam_src,,'`" = "$i"; then
368                 install -d $RPM_BUILD_ROOT%{_docdir}/boost-%{version}/${i%/*}
369                 for LINKED in `%{__perl} - $i $RPM_BUILD_ROOT%{_docdir}/boost-%{version}/$i <<'EOT'
370                         sub rewrite_link
371                         {
372                                 my $link = shift;
373                                 # rewrite links from boost/* to %{_includedir}/boost/* and
374                                 # ignore external links as well as document-internal ones.
375                                 # HTML files are also ignored as they get installed anyway.
376                                 if (!($link =~ s,^(?:../)*boost/,%{_includedir}/boost/,) && !($link =~ m,(?:^[^/]+:|^\#|\.html?(?:$|\#)),))
377                                 {
378                                         (my $file = $link) =~ s/\#.*//;
379                                         print "$file\n";
380                                 }
381                                 $link;
382                         }
383                         open IN, @ARGV[0];
384                         open OUT, ">@ARGV[1]";
385                         my $in_link;
386                         while (<IN>)
387                         {
388                                 $in_link and s/^\s*"([^"> ]*)"/'"' . rewrite_link($1) . '"'/e;
389                                 s/(href|src)="([^"> ]*)"/"$1=\"" . rewrite_link($2) . '"'/eig;
390                                 print OUT;
391                                 $in_link = /href|src=\s*$/;
392                         }
393 EOT`; do
394                         TARGET=${i%/*}/$LINKED
395                         # ignore non-existant linked files
396                         if test -f $TARGET; then
397                                 install -D -m 644 $TARGET $RPM_BUILD_ROOT%{_docdir}/boost-%{version}/$TARGET
398                         fi
399                 done
400         fi
401 done
402 }; installdocs
403
404 %clean
405 rm -rf $RPM_BUILD_ROOT
406
407 %post   -p /sbin/ldconfig
408 %postun -p /sbin/ldconfig
409
410 %post   date_time -p /sbin/ldconfig
411 %postun date_time -p /sbin/ldconfig
412
413 %post   filesystem -p /sbin/ldconfig
414 %postun filesystem -p /sbin/ldconfig
415
416 %post   graph -p /sbin/ldconfig
417 %postun graph -p /sbin/ldconfig
418
419 %post   python -p /sbin/ldconfig
420 %postun python -p /sbin/ldconfig
421
422 %post   program_options -p /sbin/ldconfig
423 %postun program_options -p /sbin/ldconfig
424
425 %post   regex -p /sbin/ldconfig
426 %postun regex -p /sbin/ldconfig
427
428 %post   signals -p /sbin/ldconfig
429 %postun signals -p /sbin/ldconfig
430
431 %post   system -p /sbin/ldconfig
432 %postun system -p /sbin/ldconfig
433
434 %post   test -p /sbin/ldconfig
435 %postun test -p /sbin/ldconfig
436
437 %post   wave -p /sbin/ldconfig
438 %postun wave -p /sbin/ldconfig
439
440 %post   thread -p /sbin/ldconfig
441 %postun thread -p /sbin/ldconfig
442
443 %files
444 %defattr(644,root,root,755)
445 %attr(755,root,root) %{_libdir}/libboost_iostreams.so.*.*.*
446 %attr(755,root,root) %{_libdir}/libboost_math_*.so.*.*.*
447 %attr(755,root,root) %{_libdir}/libboost_random.so.*.*.*
448 %attr(755,root,root) %{_libdir}/libboost_serialization.so.*.*.*
449 %attr(755,root,root) %{_libdir}/libboost_wserialization.so.*.*.*
450
451 %files devel
452 %defattr(644,root,root,755)
453 %attr(755,root,root) %{_libdir}/libboost_date_time.so
454 %attr(755,root,root) %{_libdir}/libboost_filesystem.so
455 %attr(755,root,root) %{_libdir}/libboost_graph.so
456 %attr(755,root,root) %{_libdir}/libboost_iostreams.so
457 %attr(755,root,root) %{_libdir}/libboost_math_*.so
458 %attr(755,root,root) %{_libdir}/libboost_prg_exec_monitor.so
459 %attr(755,root,root) %{_libdir}/libboost_program_options.so
460 %attr(755,root,root) %{_libdir}/libboost_regex.so
461 %attr(755,root,root) %{_libdir}/libboost_random.so
462 %attr(755,root,root) %{_libdir}/libboost_serialization.so
463 %attr(755,root,root) %{_libdir}/libboost_signals.so
464 %attr(755,root,root) %{_libdir}/libboost_system.so
465 %attr(755,root,root) %{_libdir}/libboost_thread.so
466 %attr(755,root,root) %{_libdir}/libboost_unit_test_framework.so
467 %attr(755,root,root) %{_libdir}/libboost_wave.so
468 %attr(755,root,root) %{_libdir}/libboost_wserialization.so
469 %{_includedir}/boost
470 %exclude %{_includedir}/boost/python
471 %exclude %{_includedir}/boost/python.hpp
472
473 %files static
474 %defattr(644,root,root,755)
475 %{_libdir}/libboost_date_time.a
476 %{_libdir}/libboost_filesystem.a
477 %{_libdir}/libboost_graph.a
478 %{_libdir}/libboost_iostreams.a
479 %{_libdir}/libboost_math_*.a
480 %{_libdir}/libboost_prg_exec_monitor.a
481 %{_libdir}/libboost_program_options.a
482 %{_libdir}/libboost_random.a
483 %{_libdir}/libboost_regex.a
484 %{_libdir}/libboost_serialization.a
485 %{_libdir}/libboost_signals.a
486 %{_libdir}/libboost_system.a
487 %{_libdir}/libboost_test_exec_monitor.a
488 %{_libdir}/libboost_thread.a
489 %{_libdir}/libboost_unit_test_framework.a
490 %{_libdir}/libboost_wave.a
491 %{_libdir}/libboost_wserialization.a
492
493 %if %{with python}
494 %files python
495 %defattr(644,root,root,755)
496 %attr(755,root,root) %{_libdir}/libboost_python.so.*.*.*
497
498 %files python-devel
499 %defattr(644,root,root,755)
500 %attr(755,root,root) %{_libdir}/libboost_python.so
501 %{_includedir}/boost/python
502 %{_includedir}/boost/python.hpp
503
504 %files python-static
505 %defattr(644,root,root,755)
506 %{_libdir}/libboost_python.a
507 %endif
508
509 %files date_time
510 %defattr(644,root,root,755)
511 %attr(755,root,root) %{_libdir}/libboost_date_time.so.*.*.*
512
513 %files filesystem
514 %defattr(644,root,root,755)
515 %attr(755,root,root) %{_libdir}/libboost_filesystem.so.*.*.*
516
517 %files graph
518 %defattr(644,root,root,755)
519 %attr(755,root,root) %{_libdir}/libboost_graph.so.*.*.*
520
521 %files program_options
522 %defattr(644,root,root,755)
523 %attr(755,root,root) %{_libdir}/libboost_program_options.so.*.*.*
524
525 %files regex
526 %defattr(644,root,root,755)
527 %attr(755,root,root) %{_libdir}/libboost_regex.so.*.*.*
528
529 %files signals
530 %defattr(644,root,root,755)
531 %attr(755,root,root) %{_libdir}/libboost_signals.so.*.*.*
532
533 %files system
534 %defattr(644,root,root,755)
535 %attr(755,root,root) %{_libdir}/libboost_system.so.*.*.*
536
537 %files test
538 %defattr(644,root,root,755)
539 %attr(755,root,root) %{_libdir}/libboost_prg_exec_monitor.so.*.*.*
540 %attr(755,root,root) %{_libdir}/libboost_unit_test_framework.so.*.*.*
541
542 %files thread
543 %defattr(644,root,root,755)
544 %attr(755,root,root) %{_libdir}/libboost_thread.so.*.*.*
545
546 %files wave
547 %defattr(644,root,root,755)
548 %attr(755,root,root) %{_libdir}/libboost_wave.so.*.*.*
549
550 %files doc
551 %defattr(644,root,root,755)
552 %{_docdir}/%{name}-%{version}
This page took 0.085559 seconds and 4 git commands to generate.