From b78023cd51960434249d3c13b9a986edbaf1b881 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Jun 25 2015 13:39:37 +0000 Subject: import tbb-4.1-9.20130314.aa7a --- diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..eb652ef --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/tbb41_20130314oss_src.tgz diff --git a/.tbb.metadata b/.tbb.metadata new file mode 100644 index 0000000..c2ba8f4 --- /dev/null +++ b/.tbb.metadata @@ -0,0 +1 @@ +e2bf74c1e492b06faf3ecdf2321e64ca698c0921 SOURCES/tbb41_20130314oss_src.tgz diff --git a/README.md b/README.md deleted file mode 100644 index 0e7897f..0000000 --- a/README.md +++ /dev/null @@ -1,5 +0,0 @@ -The master branch has no content - -Look at the c7 branch if you are working with CentOS-7, or the c4/c5/c6 branch for CentOS-4, 5 or 6 - -If you find this file in a distro specific branch, it means that no content has been checked in yet diff --git a/SOURCES/tbb-3.0-cxxflags.patch b/SOURCES/tbb-3.0-cxxflags.patch new file mode 100644 index 0000000..71dc4af --- /dev/null +++ b/SOURCES/tbb-3.0-cxxflags.patch @@ -0,0 +1,18 @@ +diff -up tbb30_20110419oss/build/linux.gcc.inc\~ tbb30_20110419oss/build/linux.gcc.inc +--- tbb30_20110419oss/build/linux.gcc.inc~ 2011-04-19 13:48:58.000000000 +0200 ++++ tbb30_20110419oss/build/linux.gcc.inc 2011-07-26 14:02:48.482006056 +0200 +@@ -59,10 +59,10 @@ ifneq (,$(shell gcc -dumpversion | egrep + endif + + ifeq ($(cfg), release) +- CPLUS_FLAGS = $(ITT_NOTIFY) -g -O2 -DUSE_PTHREAD ++ CPLUS_FLAGS = $(CXXFLAGS) $(ITT_NOTIFY) -g -O2 -DUSE_PTHREAD + endif + ifeq ($(cfg), debug) +- CPLUS_FLAGS = -DTBB_USE_DEBUG $(ITT_NOTIFY) -g -O0 -DUSE_PTHREAD ++ CPLUS_FLAGS = $(CXXFLAGS) -DTBB_USE_DEBUG $(ITT_NOTIFY) -g -O0 -DUSE_PTHREAD + endif + + ifneq (00,$(lambdas)$(cpp0x)) + +Diff finished. Tue Feb 26 13:00:13 2013 diff --git a/SOURCES/tbb-4.0-mfence.patch b/SOURCES/tbb-4.0-mfence.patch new file mode 100644 index 0000000..a463bc9 --- /dev/null +++ b/SOURCES/tbb-4.0-mfence.patch @@ -0,0 +1,21 @@ +diff -up tbb40_20110809oss/include/tbb/machine/linux_ia32.h\~ tbb40_20110809oss/include/tbb/machine/linux_ia32.h +--- tbb40_20110809oss/include/tbb/machine/linux_ia32.h~ 2011-08-24 15:51:56.000000000 +0200 ++++ tbb40_20110809oss/include/tbb/machine/linux_ia32.h 2011-10-18 15:04:01.994271994 +0200 +@@ -42,7 +42,14 @@ + #define __TBB_control_consistency_helper() __TBB_compiler_fence() + #define __TBB_acquire_consistency_helper() __TBB_compiler_fence() + #define __TBB_release_consistency_helper() __TBB_compiler_fence() +-#define __TBB_full_memory_fence() __asm__ __volatile__("mfence": : :"memory") ++#define __TBB_full_memory_fence() __TBB_full_memory_fence_imp() ++inline void __TBB_full_memory_fence_imp() { ++ int tmp; ++ __asm__ __volatile__("xchg %0,%0" ++ : "=r"(tmp) ++ : "r"(tmp) ++ : "memory"); ++} + + #if __TBB_ICC_ASM_VOLATILE_BROKEN + #define __TBB_VOLATILE + +Diff finished. Tue Oct 18 15:04:09 2011 diff --git a/SOURCES/tbb.pc b/SOURCES/tbb.pc new file mode 100644 index 0000000..1f4bd26 --- /dev/null +++ b/SOURCES/tbb.pc @@ -0,0 +1,5 @@ +Name: Threading Building Blocks +Description: The Threading Building Blocks library abstracts low-level threading details +URL: http://www.threadingbuildingblocks.org/ +Version: _FEDORA_VERSION +Libs: -ltbb diff --git a/SOURCES/tbbmalloc.pc b/SOURCES/tbbmalloc.pc new file mode 100644 index 0000000..d5a4b1c --- /dev/null +++ b/SOURCES/tbbmalloc.pc @@ -0,0 +1,5 @@ +Name: Threading Building Blocks Scalable Allocator +Description: Implementation of Scalable Memory Allocator of Threading Building Blocks +URL: http://www.threadingbuildingblocks.org/ +Version: _FEDORA_VERSION +Libs: -ltbbmalloc diff --git a/SOURCES/tbbmalloc_proxy.pc b/SOURCES/tbbmalloc_proxy.pc new file mode 100644 index 0000000..bbfcd48 --- /dev/null +++ b/SOURCES/tbbmalloc_proxy.pc @@ -0,0 +1,5 @@ +Name: Threading Building Blocks Scallable Malloc Proxy +Description: Implementation of proxy that redirects memory allocation calls to TBB Scalable Memory Allocator +URL: http://www.threadingbuildingblocks.org/ +Version: _FEDORA_VERSION +Libs: -ltbbmalloc_proxy -ltbbmalloc diff --git a/SPECS/tbb.spec b/SPECS/tbb.spec new file mode 100644 index 0000000..a1c0da4 --- /dev/null +++ b/SPECS/tbb.spec @@ -0,0 +1,232 @@ +%define releasedate 20130314 +%define major 4 +%define minor 1 +%define update 3 +%define dotver %{major}.%{minor} +%define sourcebasename tbb%{major}%{minor}_%{releasedate}oss + +%define sourcefilename %{sourcebasename}_src.tgz + +Summary: The Threading Building Blocks library abstracts low-level threading details +Name: tbb +Version: %{dotver} +Release: 9.%{releasedate}%{?dist} +License: GPLv2 with exceptions +Group: Development/Tools +URL: http://threadingbuildingblocks.org/ +Source0: http://threadingbuildingblocks.org/sites/default/files/software_releases/source/tbb41_20130314oss_src.tgz + +# These two are downstream sources. +Source6: tbb.pc +Source7: tbbmalloc.pc +Source8: tbbmalloc_proxy.pc + +# Propagate CXXFLAGS variable into flags used when compiling C++. +# This so that RPM_OPT_FLAGS are respected. +Patch1: tbb-3.0-cxxflags.patch + +# Replace mfence with xchg (for 32-bit builds only) so that TBB +# compiles and works supported hardware. mfence was added with SSE2, +# which we still don't assume. +Patch2: tbb-4.0-mfence.patch + +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +BuildRequires: libstdc++-devel +ExcludeArch: s390 s390x + +%description +Threading Building Blocks (TBB) is a C++ runtime library that +abstracts the low-level threading details necessary for optimal +multi-core performance. It uses common C++ templates and coding style +to eliminate tedious threading implementation work. + +TBB requires fewer lines of code to achieve parallelism than other +threading models. The applications you write are portable across +platforms. Since the library is also inherently scalable, no code +maintenance is required as more processor cores become available. + + +%package devel +Summary: The Threading Building Blocks C++ headers and shared development libraries +Group: Development/Libraries +Requires: %{name}%{?_isa} = %{version}-%{release} + +%description devel +Header files and shared object symlinks for the Threading Building +Blocks (TBB) C++ libraries. + + +%package doc +Summary: The Threading Building Blocks documentation +Group: Documentation + +%description doc +PDF documentation for the user of the Threading Building Block (TBB) +C++ library. + + +%prep +%setup -q -n %{sourcebasename} +%patch1 -p1 +%patch2 -p1 + +%build +make %{?_smp_mflags} CXXFLAGS="$RPM_OPT_FLAGS" tbb_build_prefix=obj +for file in %{SOURCE6} %{SOURCE7} %{SOURCE8}; do + sed 's/_FEDORA_VERSION/%{major}.%{minor}.%{update}/' ${file} \ + > $(basename ${file}) +done + +%install +rm -rf $RPM_BUILD_ROOT +mkdir -p $RPM_BUILD_ROOT/%{_libdir} +mkdir -p $RPM_BUILD_ROOT/%{_includedir} + +pushd build/obj_release + for file in libtbb{,malloc{,_proxy}}; do + install -p -D -m 755 ${file}.so.2 $RPM_BUILD_ROOT/%{_libdir} + ln -s $file.so.2 $RPM_BUILD_ROOT/%{_libdir}/$file.so + done +popd + +pushd include + find tbb -type f ! -name \*.htm\* -exec \ + install -p -D -m 644 {} $RPM_BUILD_ROOT/%{_includedir}/{} \ + \; +popd + +for file in %{SOURCE6} %{SOURCE7} %{SOURCE8}; do + install -p -D -m 644 $(basename ${file}) \ + $RPM_BUILD_ROOT/%{_libdir}/pkgconfig/$(basename ${file}) +done + +%post -p /sbin/ldconfig + +%postun -p /sbin/ldconfig + +%clean +rm -rf ${RPM_BUILD_ROOT} + +%files +%defattr(-,root,root,-) +%doc COPYING doc/Release_Notes.txt +%{_libdir}/*.so.2 + +%files devel +%defattr(-,root,root,-) +%doc CHANGES +%{_includedir}/tbb +%{_libdir}/*.so +%{_libdir}/pkgconfig/*.pc + +%files doc +%defattr(-,root,root,-) +%doc doc/Release_Notes.txt +%doc doc/html + +%changelog +* Sat Aug 16 2014 Petr Machata - 4.1-9.20130314 +- Add ExcludeArch: s390{,x} + +* Sat Aug 16 2014 Petr Machata - 4.1-8.20130314 +- Bump for rebuild + +* Fri Jul 25 2014 Petr Machata - 4.1-7.20130314 +- Bump for rebuild + +* Wed Jan 22 2014 Petr Machata - 4.1-6.20130314 +- Drop ExclusiveArch altogether. TBB has a fallback code that works + irrespective of the architecture. + +* Fri Dec 27 2013 Daniel Mach - 4.1-5.20130314 +- Mass rebuild 2013-12-27 + +* Thu Oct 3 2013 Petr Machata - 4.1-4.20130314 +- Fix %%install to also install include files that are not named *.h + +* Tue May 28 2013 Petr Machata - 4.1-3.20130314 +- Enable ARM arches + +* Wed May 22 2013 Petr Machata - 4.1-2.20130314 +- Fix mfence patch. Since the __TBB_full_memory_fence macro was + function-call-like, it stole () intended for function invocation. + +* Wed May 22 2013 Petr Machata - 4.1-1.20130314 +- Rebase to 4.1 update 3 + +* Fri Feb 15 2013 Fedora Release Engineering - 4.0-7.20120408 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Tue Aug 28 2012 Petr Machata - 4.0-6.20120408 +- Fix build on PowerPC + +* Sat Jul 21 2012 Fedora Release Engineering - 4.0-5.20120408 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Thu Jun 7 2012 Petr Machata - 4.0-4.20120408 +- Rebase to 4.0 update 4 +- Refresh Getting_Started.pdf, Reference.pdf, Tutorial.pdf +- Provide pkg-config files +- Resolves: #825402 + +* Thu Apr 05 2012 Karsten Hopp 4.0-3.20110809 +- tbb builds now on PPC(64) + +* Sat Jan 14 2012 Fedora Release Engineering - 4.0-2.20110809 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Tue Oct 18 2011 Petr Machata - 4.0-1.20110809 +- Rebase to 4.0 + - Port the mfence patch + - Refresh the documentation bundle + +* Tue Jul 26 2011 Petr Machata - 3.0-1.20110419 +- Rebase to 3.0-r6 + - Port both patches + - Package Design_Patterns.pdf + - Thanks to Richard Shaw for initial rebase patch +- Resolves: #723043 + +* Wed Feb 09 2011 Fedora Release Engineering - 2.2-3.20090809 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Thu Jun 10 2010 Petr Machata - 2.2-2.20090809 +- Replace mfence instruction with xchg to make it run on ia32-class + machines without SSE2. +- Resolves: #600654 + +* Tue Nov 3 2009 Petr Machata - 2.2-1.20090809 +- New upstream 2.2 +- Resolves: #521571 + +* Sun Jul 26 2009 Fedora Release Engineering - 2.1-3.20080605 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Wed Feb 25 2009 Fedora Release Engineering - 2.1-2.20080605 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Fri Jun 13 2008 Petr Machata - 2.1-1.20080605 +- New upstream 2.1 + - Drop soname patch, parallel make patch, and GCC 4.3 patch + +* Wed Feb 13 2008 Petr Machata - 2.0-4.20070927 +- Review fixes + - Use updated URL + - More timestamp preservation +- Initial import into Fedora CVS + +* Mon Feb 11 2008 Petr Machata - 2.0-3.20070927 +- Review fixes + - Preserve timestamp of installed files + - Fix soname not to contain "debug" + +* Tue Feb 5 2008 Petr Machata - 2.0-2.20070927 +- Review fixes + - GCC 4.3 patchset + - Add BR util-linux net-tools + - Add full URL to Source0 + - Build in debug mode to work around problems with GCC 4.3 + +* Mon Dec 17 2007 Petr Machata - 2.0-1.20070927 +- Initial package. +- Using SONAME patch from Debian.