4 %define sourcebasename tbb%{major}%{minor}_%{micro}oss
5 Summary: The Threading Building Blocks library abstracts low-level threading details
6 Summary(pl.UTF-8): Threading Building Blocks - biblioteka abstrahująca niskopoziomowe szczegóły obsługi wątków
8 Version: %{major}.%{minor}.%{micro}
10 License: GPL v2 with runtime exception
11 Group: Development/Tools
12 Source0: http://threadingbuildingblocks.org/sites/default/files/software_releases/source/%{sourcebasename}_src.tgz
13 # Source0-md5: ed4af7ccfa122f16cf9920b241633a3a
14 Source1: http://www.threadingbuildingblocks.org/uploads/81/91/Latest%20Open%20Source%20Documentation/Design_Patterns.pdf
15 # Source1-md5: 46062fef922d39abfd464bc06e02cdd8
16 Source2: http://www.threadingbuildingblocks.org/uploads/81/91/Latest%20Open%20Source%20Documentation/Getting_Started.pdf
17 # Source2-md5: b8f94104c47f9667e537b98bd940494a
18 Source3: http://www.threadingbuildingblocks.org/uploads/81/91/Latest%20Open%20Source%20Documentation/Reference.pdf
19 # Source3-md5: 1481cbd378f4964691046d0ba570b374
20 Source4: http://www.threadingbuildingblocks.org/uploads/81/91/Latest%20Open%20Source%20Documentation/Tutorial.pdf
21 # Source4-md5: 5bbdd1050c5dac5c1b782a6a98db0c46
22 Source5: %{name}.pc.in
23 Source6: %{name}malloc.pc.in
24 Source7: %{name}malloc_proxy.pc.in
25 Patch1: %{name}-cxxflags.patch
27 URL: http://www.threadingbuildingblocks.org/
28 BuildRequires: libstdc++-devel
29 BuildRequires: pkgconfig
30 BuildRequires: sed >= 4.0
31 # We need "arch" binary:
32 BuildRequires: util-linux
33 ExclusiveArch: %{ix86} %{x8664} %{arm} ia64 ppc ppc64
34 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
37 Threading Building Blocks (TBB) is a C++ runtime library that
38 abstracts the low-level threading details necessary for optimal
39 multi-core performance. It uses common C++ templates and coding style
40 to eliminate tedious threading implementation work.
42 TBB requires fewer lines of code to achieve parallelism than other
43 threading models. The applications you write are portable across
44 supported platforms. Since the library is also inherently scalable, no
45 code maintenance is required as more processor cores become available.
47 %description -l pl.UTF-8
48 Threading Building Blocks (TBB) to biblioteka uruchomieniowa C++
49 abstrahująca niskopoziomowe szczegóły obsługi wątków potrzebne dla
50 optymalnej wydajności na procesorach wielordzeniowych. Wykorzystuje
51 szablony C++ w celu wyeliminowania nudnej pracy nad wielowątkowością.
53 TBB wymaga mniej linii kodu do osiągnięcia równoległości niż inne
54 modele wątkowania. Aplikacje są przenośne między obsługiwanymi
55 platformami. Biblioteka jest skalowalna, więc nie jest wymagane
56 modyfikowanie kodu wraz z dostępnością większej liczby rdzeni
60 Summary: The Threading Building Blocks C++ headers
61 Summary(pl.UTF-8): Pliki nagłówkowe C++ bibliotek Threading Building Blocks
62 Group: Development/Libraries
63 Requires: %{name} = %{version}-%{release}
66 Header files and shared object symlinks for the Threading Building
67 Blocks (TBB) C++ libraries.
69 %description devel -l pl.UTF-8
70 Pliki nagłówkowe i dowiązania symboliczne dla bibliotek C++ Threading
74 Summary: The Threading Building Blocks documentation
75 Summary(pl.UTF-8): Dokumentacja bibliotek Threading Building Blocks
79 PDF documentation for the user of the Threading Building Block (TBB)
82 %description doc -l pl.UTF-8
83 Dokumentacja w formacie PDF dla użytkowników biblioteki C++ Threading
84 Building Blocks (TBB).
87 %setup -q -n %{sourcebasename}
91 cp -p %{SOURCE1} %{SOURCE2} %{SOURCE3} %{SOURCE4} .
93 cp -p %{SOURCE5} %{SOURCE6} %{SOURCE7} .
95 sed -i -e 's/-march=pentium4//' build/linux.gcc.inc
100 CXXFLAGS="%{rpmcxxflags}" \
104 rm -rf $RPM_BUILD_ROOT
105 install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir},%{_pkgconfigdir}}
108 for file in tbb tbbmalloc tbbmalloc_proxy; do
109 install lib${file}.so.2 $RPM_BUILD_ROOT%{_libdir}/lib${file}.so.2.%{version}
110 ln -s lib${file}.so.2.%{version} $RPM_BUILD_ROOT%{_libdir}/lib${file}.so
111 ln -s lib${file}.so.2.%{version} $RPM_BUILD_ROOT%{_libdir}/lib${file}.so.2
116 find tbb -type f -name '*.h' -exec \
117 install -p -D -m 644 {} $RPM_BUILD_ROOT%{_includedir}/{} ';'
120 for pc in tbb.pc tbbmalloc.pc tbbmalloc_proxy.pc; do
123 [ ! -f $RPM_BUILD_ROOT%{_pkgconfigdir}/$pc ] || exit 1
125 s,@prefix@,%{_prefix},;
126 s,@libdir@,%{_libdir},;
127 s,@includedir@,%{_includedir}/tbb,;
128 s,@version@,%{version},
129 ' $in > $RPM_BUILD_ROOT%{_pkgconfigdir}/$pc
133 rm -rf $RPM_BUILD_ROOT
135 %post -p /sbin/ldconfig
136 %postun -p /sbin/ldconfig
139 %defattr(644,root,root,755)
140 %doc CHANGES COPYING doc/Release_Notes.txt
141 %attr(755,root,root) %{_libdir}/libtbb.so.*.*.*
142 %attr(755,root,root) %ghost %{_libdir}/libtbb.so.2
143 %attr(755,root,root) %{_libdir}/libtbbmalloc.so.*.*.*
144 %attr(755,root,root) %ghost %{_libdir}/libtbbmalloc.so.2
145 %attr(755,root,root) %{_libdir}/libtbbmalloc_proxy.so.*.*.*
146 %attr(755,root,root) %ghost %{_libdir}/libtbbmalloc_proxy.so.2
149 %defattr(644,root,root,755)
150 %attr(755,root,root) %{_libdir}/libtbb.so
151 %attr(755,root,root) %{_libdir}/libtbbmalloc.so
152 %attr(755,root,root) %{_libdir}/libtbbmalloc_proxy.so
154 %{_pkgconfigdir}/tbb.pc
155 %{_pkgconfigdir}/tbbmalloc.pc
156 %{_pkgconfigdir}/tbbmalloc_proxy.pc
159 %defattr(644,root,root,755)