public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2015-09-20 10:15 Justin Lecher
  0 siblings, 0 replies; 10+ messages in thread
From: Justin Lecher @ 2015-09-20 10:15 UTC (permalink / raw
  To: gentoo-commits

commit:     bb6ead9708a9825f32e7ea306d4460fa77aa2eb9
Author:     Justin Lecher <jlec <AT> gentoo <DOT> org>
AuthorDate: Sun Sep 20 10:01:52 2015 +0000
Commit:     Justin Lecher <jlec <AT> gentoo <DOT> org>
CommitDate: Sun Sep 20 10:01:52 2015 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bb6ead97

dev-cpp/tbb: Drop old

Package-Manager: portage-2.2.20.1
Signed-off-by: Justin Lecher <jlec <AT> gentoo.org>

 dev-cpp/tbb/Manifest                         |   1 -
 dev-cpp/tbb/files/tbb-4.1.20121003-ppc.patch |  16 ---
 dev-cpp/tbb/files/tbb-4.3-build.patch        | 185 ---------------------------
 dev-cpp/tbb/tbb-4.1.20121003-r1.ebuild       | 124 ------------------
 dev-cpp/tbb/tbb-4.3.20141023-r1.ebuild       | 132 -------------------
 5 files changed, 458 deletions(-)

diff --git a/dev-cpp/tbb/Manifest b/dev-cpp/tbb/Manifest
index 6bb73c5..b19a8e5 100644
--- a/dev-cpp/tbb/Manifest
+++ b/dev-cpp/tbb/Manifest
@@ -1,3 +1,2 @@
-DIST tbb41_20121003oss_src.tgz 2250789 SHA256 5383727b9582a54cf4c4adbf22186b70e8eba276fcd3be81d746a937c5b47afc SHA512 fada6e32a09be2a151746caf3a15729c9ec6043b17e2f0aeb1bd903542310cdc6fe9ad85017ff5b2cfb16ae955c81c8b39ad8cf97f871bfcbd19d4948ef1d821 WHIRLPOOL 6c2a094e1dc6efed7189903bf8a6bbb8688ab1b15134c9f3c09fd5ed6a72315140505f5df410c89b65cd160a896222d71e01b3bfcbcd933281fb18a69eaf33f1
 DIST tbb43_20141023oss_src.tgz 2777177 SHA256 247a8d22d6850caa37d376aaeaf8bfcb06525ec5561fb6f6ed09cdad2c1f6414 SHA512 0718e7bf5f0b9525da9eb45beedc1c3832ccd813d72b10a7ed7c6a281d342325d04c65f797c29e2551d4f2bd470e57c81f38db0d6bd983f7871a90f2b5fe5020 WHIRLPOOL 7a6bc75e9404cbfc9f1e1bc53ff195e63c605aae1cc2883147d69bdd394694d21f916fa6d1c2708ff397a01c620fdb38966d0da5085df6d23dcba235de18c6a8
 DIST tbb43_20150611oss_src.tgz 2757631 SHA256 221f85fe64e11c9638e43b3c57d5750c26683905fc90827c0bcfefdb286e79c9 SHA512 83d5d827706b774ef5cd6df8082e5d7f48683388684423bb40565dfc25892fc2e57c382f719b78087d83e51edb3f7f7215f33d8b5039b55c32788d80efa6e0b8 WHIRLPOOL 8e98162b2307c759fb26923d76ab784dea81e166c8bf5323869d234da59641c333e5ae30b4a224bccbf20d4f5f6b75c658589f519a165ea3ad7658322f148c72

diff --git a/dev-cpp/tbb/files/tbb-4.1.20121003-ppc.patch b/dev-cpp/tbb/files/tbb-4.1.20121003-ppc.patch
deleted file mode 100644
index c50e051..0000000
--- a/dev-cpp/tbb/files/tbb-4.1.20121003-ppc.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-diff -up tbb40_20120408oss/include/tbb/tbb_machine.h\~ tbb40_20120408oss/include/tbb/tbb_machine.h
---- tbb40_20120408oss/include/tbb/tbb_machine.h~	2012-04-20 09:21:57.000000000 +0200
-+++ tbb40_20120408oss/include/tbb/tbb_machine.h	2012-08-28 13:20:42.150456167 +0200
-@@ -373,8 +373,8 @@ void spin_wait_until_eq( const volatile
- //  - The operation assumes that the architecture consistently uses either little-endian or big-endian:
- //      it does not support mixed-endian or page-specific bi-endian architectures.
- // This function is the only use of __TBB_BIG_ENDIAN.
--#if (__TBB_BIG_ENDIAN!=-1)
--    #if ( __TBB_USE_GENERIC_PART_WORD_CAS)
-+#if ( __TBB_USE_GENERIC_PART_WORD_CAS)
-+    #if (__TBB_BIG_ENDIAN==-1)
-         #error generic implementation of part-word CAS was explicitly disabled for this configuration
-     #endif
- template<typename T>
-
-Diff finished.  Tue Aug 28 13:20:58 2012

diff --git a/dev-cpp/tbb/files/tbb-4.3-build.patch b/dev-cpp/tbb/files/tbb-4.3-build.patch
deleted file mode 100644
index a9119ef..0000000
--- a/dev-cpp/tbb/files/tbb-4.3-build.patch
+++ /dev/null
@@ -1,185 +0,0 @@
---- a/build/linux.gcc.inc	2014-10-31 09:08:38.000000000 -0400
-+++ b/build/linux.gcc.inc	2015-06-08 19:22:49.855807841 -0400
-@@ -32,12 +32,12 @@
- EXPORT_KEY = -Wl,--version-script,
- LIBDL = -ldl
- 
--CPLUS = g++
--CONLY = gcc
-+CPLUS := $(CXX)
-+CONLY := $(CC)
- LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
- LIBS += -lpthread -lrt
- LINK_FLAGS = -Wl,-rpath-link=. -rdynamic
--C_FLAGS = $(CPLUS_FLAGS)
-+C_FLAGS := $(CPLUS_FLAGS)
- # gcc 4.4 and higher support -std=c++0x
- ifneq (,$(shell gcc -dumpversion | egrep  "^(4\.[4-9]|[5-9])"))
-     CPP11_FLAGS = -std=c++0x -D_TBB_CPP0X
-@@ -54,7 +54,7 @@
- endif
- 
- ifeq ($(cfg), release)
--        CPLUS_FLAGS = $(ITT_NOTIFY) -g -O2 -DUSE_PTHREAD
-+        CPLUS_FLAGS = $(ITT_NOTIFY) -g -DUSE_PTHREAD
- endif
- ifeq ($(cfg), debug)
-         CPLUS_FLAGS = -DTBB_USE_DEBUG $(ITT_NOTIFY) -g -O0 -DUSE_PTHREAD
-@@ -74,24 +74,12 @@
- 
- ifeq (intel64,$(arch))
-     ITT_NOTIFY = -DDO_ITT_NOTIFY
--    CPLUS_FLAGS += -m64 $(RTM_KEY)
--    LIB_LINK_FLAGS += -m64
-+    CPLUS_FLAGS += $(RTM_KEY)
- endif
- 
- ifeq (ia32,$(arch))
-     ITT_NOTIFY = -DDO_ITT_NOTIFY
--    CPLUS_FLAGS += -m32 -march=pentium4 $(RTM_KEY)
--    LIB_LINK_FLAGS += -m32
--endif
--
--ifeq (ppc64,$(arch))
--    CPLUS_FLAGS += -m64
--    LIB_LINK_FLAGS += -m64
--endif
--
--ifeq (ppc32,$(arch))
--    CPLUS_FLAGS += -m32
--    LIB_LINK_FLAGS += -m32
-+    CPLUS_FLAGS += $(RTM_KEY)
- endif
- 
- ifeq (bg,$(arch))
-@@ -99,12 +87,6 @@
-     CONLY = mpicc
- endif
- 
--# for some gcc versions on Solaris, -m64 may imply V9, but perhaps not everywhere (TODO: verify)
--ifeq (sparc,$(arch))
--    CPLUS_FLAGS    += -mcpu=v9 -m64
--    LIB_LINK_FLAGS += -mcpu=v9 -m64
--endif
--
- # automatically generate "IT" instructions when compiling for Thumb ISA
- ifeq (armv7,$(arch))
-     CPLUS_FLAGS    += -Wa,-mimplicit-it=thumb
-@@ -113,13 +95,7 @@
- #------------------------------------------------------------------------------
- # Setting assembler data.
- #------------------------------------------------------------------------------
--ASM = as
--ifeq (intel64,$(arch))
--    ASM_FLAGS += --64
--endif
--ifeq (ia32,$(arch))
--    ASM_FLAGS += --32
--endif
-+ASM := $(AS)
- ifeq ($(cfg),debug)
-     ASM_FLAGS += -g
- endif
---- a/build/FreeBSD.gcc.inc	2014-10-31 09:08:37.000000000 -0400
-+++ b/build/FreeBSD.gcc.inc	2015-06-08 19:24:51.385810060 -0400
-@@ -27,14 +27,14 @@
- WARNING_KEY = -Wall
- DYLIB_KEY = -shared
- 
--CPLUS = g++ 
--CONLY = gcc
-+CPLUS = $(CXX)
-+CONLY = $(CC)
- LIB_LINK_FLAGS = -shared
- LIBS = -lpthread 
- C_FLAGS = $(CPLUS_FLAGS)
- 
- ifeq ($(cfg), release)
--        CPLUS_FLAGS = -g -O2 -DUSE_PTHREAD
-+        CPLUS_FLAGS = -g -DUSE_PTHREAD
- endif
- ifeq ($(cfg), debug)
-         CPLUS_FLAGS = -DTBB_USE_DEBUG -g -O0 -DUSE_PTHREAD
-@@ -51,22 +51,12 @@
-     CPLUS_FLAGS += $(PIC_KEY)
- endif 
- 
--ifeq (intel64,$(arch))
--    CPLUS_FLAGS += -m64
--    LIB_LINK_FLAGS += -m64
--endif 
--
--ifeq (ia32,$(arch))
--    CPLUS_FLAGS += -m32
--    LIB_LINK_FLAGS += -m32
--endif 
--
- #------------------------------------------------------------------------------
- # Setting assembler data.
- #------------------------------------------------------------------------------
- ASSEMBLY_SOURCE=$(arch)-gas
- ifeq (ia64,$(arch))
--    ASM=as
-+    ASM=$(AS)
-     TBB_ASM.OBJ = atomic_support.o lock_byte.o log2.o pause.o
-     MALLOC_ASM.OBJ = atomic_support.o lock_byte.o pause.o
- endif 
---- a/build/linux.clang.inc	2014-10-31 09:08:37.000000000 -0400
-+++ b/build/linux.clang.inc	2015-06-08 20:24:29.785875376 -0400
-@@ -31,15 +31,15 @@
- EXPORT_KEY = -Wl,--version-script,
- LIBDL = -ldl
- 
--CPLUS = clang++
--CONLY = clang
-+CPLUS := $(CXX)
-+CONLY := $(CC)
- LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
- LIBS += -lpthread -lrt
- LINK_FLAGS = -Wl,-rpath-link=.
- C_FLAGS = $(CPLUS_FLAGS)
- 
- ifeq ($(cfg), release)
--        CPLUS_FLAGS = $(ITT_NOTIFY) -g -O2 -DUSE_PTHREAD
-+        CPLUS_FLAGS = $(ITT_NOTIFY) -g -DUSE_PTHREAD
- endif
- ifeq ($(cfg), debug)
-         CPLUS_FLAGS = -DTBB_USE_DEBUG $(ITT_NOTIFY) -g -O0 -DUSE_PTHREAD
-@@ -61,24 +61,10 @@
- 
- ifeq (intel64,$(arch))
-     ITT_NOTIFY = -DDO_ITT_NOTIFY
--    CPLUS_FLAGS += -m64
--    LIB_LINK_FLAGS += -m64
- endif
- 
- ifeq (ia32,$(arch))
-     ITT_NOTIFY = -DDO_ITT_NOTIFY
--    CPLUS_FLAGS += -m32 -march=pentium4
--    LIB_LINK_FLAGS += -m32
--endif
--
--ifeq (ppc64,$(arch))
--    CPLUS_FLAGS += -m64
--    LIB_LINK_FLAGS += -m64
--endif
--
--ifeq (ppc32,$(arch))
--    CPLUS_FLAGS += -m32
--    LIB_LINK_FLAGS += -m32
- endif
- 
- ifeq (bg,$(arch))
-@@ -90,12 +76,6 @@
- # Setting assembler data.
- #------------------------------------------------------------------------------
- ASM = as
--ifeq (intel64,$(arch))
--    ASM_FLAGS += --64
--endif
--ifeq (ia32,$(arch))
--    ASM_FLAGS += --32
--endif
- ifeq ($(cfg),debug)
-     ASM_FLAGS += -g
- endif

diff --git a/dev-cpp/tbb/tbb-4.1.20121003-r1.ebuild b/dev-cpp/tbb/tbb-4.1.20121003-r1.ebuild
deleted file mode 100644
index ee584e6..0000000
--- a/dev-cpp/tbb/tbb-4.1.20121003-r1.ebuild
+++ /dev/null
@@ -1,124 +0,0 @@
-# Copyright 1999-2014 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=4
-inherit eutils flag-o-matic multilib versionator toolchain-funcs
-
-PV1="$(get_version_component_range 1)"
-PV2="$(get_version_component_range 2)"
-PV3="$(get_version_component_range 3)"
-MYP="${PN}${PV1}${PV2}_${PV3}oss"
-
-DESCRIPTION="High level abstract threading library"
-HOMEPAGE="http://www.threadingbuildingblocks.org/"
-SRC_URI="http://threadingbuildingblocks.org/sites/default/files/software_releases/source/${MYP}_src.tgz"
-LICENSE="GPL-2-with-exceptions"
-
-SLOT="0"
-KEYWORDS="amd64 ppc x86 ~amd64-linux ~x86-linux"
-IUSE="debug doc examples"
-
-DEPEND=""
-RDEPEND="${DEPEND}"
-S="${WORKDIR}/${MYP}"
-
-src_prepare() {
-	epatch \
-		"${FILESDIR}"/${PN}-4.0.297-underlinking.patch \
-		"${FILESDIR}"/${PN}-4.1.20121003-ppc.patch
-	# use fully qualified gcc compilers. do not force march/mcpu
-	# not tested with icc
-	# order in sed expressions is important
-	sed -i \
-		-e "s/g++/$(tc-getCXX)/g" \
-		-e "s/gcc/$(tc-getCC)/g" \
-		-e 's/-m\(arch\|cpu\)=*[[:space:]]//g' \
-		-e 's/-\(m\|-\)\(64\|32\)//g' \
-		-e 's/-O2/$(CXXFLAGS)/g' \
-		-e "/^ASM/s/as/$(tc-getAS)/g" \
-		build/*.gcc.inc || die
-
-	# force 64bit where applicable, 32bit where applicable...
-	# built-in detection is based on running kernel, which messes up
-	# e.g. in a x86 chroot on amd64 kernel. Bug 462130
-	# see build/linux.inc for values
-	use amd64 && export arch=x86_64
-	use amd64-linux && export arch=x86_64
-	use x86 && export arch=ia32
-	use x86-linux && export arch=ia32
-	# no idea what to do with ppc but so far it seems to work
-
-	find include -name \*.html -delete || die
-
-	# pc files are for debian and fedora compatibility
-	# some deps use them
-	cat <<-EOF > ${PN}.pc.template
-		prefix=${EPREFIX}/usr
-		libdir=\${prefix}/$(get_libdir)
-		includedir=\${prefix}/include
-		Name: ${PN}
-		Description: ${DESCRIPTION}
-		Version: ${PV}
-		URL: ${HOMEPAGE}
-		Cflags: -I\${includedir}
-	EOF
-	cp ${PN}.pc.template ${PN}.pc
-	cat <<-EOF >> ${PN}.pc
-		Libs: -L\${libdir} -ltbb
-		Libs.private: -lm -lrt
-	EOF
-	cp ${PN}.pc.template ${PN}malloc.pc
-	cat <<-EOF >> ${PN}malloc.pc
-		Libs: -L\${libdir} -ltbbmalloc
-		Libs.private: -lm -lrt
-	EOF
-	cp ${PN}.pc.template ${PN}malloc_proxy.pc
-	cat <<-EOF >> ${PN}malloc_proxy.pc
-		Libs: -L\${libdir} -ltbbmalloc_proxy
-		Libs.private: -lrt
-		Requires: tbbmalloc
-	EOF
-	use debug || sed -i -e '/_debug/d' Makefile
-}
-
-src_compile() {
-	if [[ $(tc-getCXX) == *g++* ]]; then
-		comp="gcc"
-	elif [[ $(tc-getCXX) == *ic*c ]]; then
-		comp="icc"
-	else
-		die "compiler $(tc-getCXX) not supported by build system"
-	fi
-	emake compiler=${comp} tbb tbbmalloc
-}
-
-src_test() {
-	append-cxxflags -fabi-version=4
-	# avoid oversubscribing with -j1
-	emake -j1 compiler=${comp} test
-}
-
-src_install(){
-	local l
-	for l in $(find build -name lib\*.so.\*); do
-		dolib.so ${l}
-		local bl=$(basename ${l})
-		dosym ${bl} /usr/$(get_libdir)/${bl%.*}
-	done
-	insinto /usr
-	doins -r include
-
-	insinto /usr/$(get_libdir)/pkgconfig
-	doins *.pc
-
-	dodoc README CHANGES doc/Release_Notes.txt
-	use doc && dohtml -r doc/html/*
-
-	if use examples ; then
-		insinto /usr/share/doc/${PF}/examples/build
-		doins build/*.inc
-		insinto /usr/share/doc/${PF}/examples
-		doins -r examples
-	fi
-}

diff --git a/dev-cpp/tbb/tbb-4.3.20141023-r1.ebuild b/dev-cpp/tbb/tbb-4.3.20141023-r1.ebuild
deleted file mode 100644
index 7d569b5..0000000
--- a/dev-cpp/tbb/tbb-4.3.20141023-r1.ebuild
+++ /dev/null
@@ -1,132 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-inherit eutils flag-o-matic multilib-minimal toolchain-funcs versionator
-
-PV1="$(get_version_component_range 1)"
-PV2="$(get_version_component_range 2)"
-PV3="$(get_version_component_range 3)"
-MYP="${PN}${PV1}${PV2}_${PV3}oss"
-
-DESCRIPTION="High level abstract threading library"
-HOMEPAGE="http://www.threadingbuildingblocks.org/"
-SRC_URI="http://threadingbuildingblocks.org/sites/default/files/software_releases/source/${MYP}_src.tgz"
-LICENSE="GPL-2-with-exceptions"
-SLOT="0"
-KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86 ~amd64-fbsd ~amd64-linux ~x86-linux"
-IUSE="debug doc examples"
-
-DEPEND=""
-RDEPEND="${DEPEND}"
-S="${WORKDIR}/${MYP}"
-
-src_prepare() {
-	epatch \
-		"${FILESDIR}"/${PN}-4.0.297-underlinking.patch \
-		"${FILESDIR}"/${PN}-4.3-build.patch
-
-	find include -name \*.html -delete || die
-
-	# Give it a soname on FreeBSD
-	echo 'LIB_LINK_FLAGS += -Wl,-soname=$(BUILDING_LIBRARY)' >>	build/FreeBSD.gcc.inc
-	# Set proper versionning on FreeBSD
-	sed -i -e '/.DLL =/s/$/.1/' build/FreeBSD.inc || die
-
-	use debug || sed -i -e '/_debug/d' Makefile
-}
-
-multilib_src_configure() {
-	# pc files are for debian and fedora compatibility
-	# some deps use them
-	cat <<-EOF > ${PN}.pc.template
-		prefix=${EPREFIX}/usr
-		libdir=\${prefix}/$(get_libdir)
-		includedir=\${prefix}/include
-		Name: ${PN}
-		Description: ${DESCRIPTION}
-		Version: ${PV}
-		URL: ${HOMEPAGE}
-		Cflags: -I\${includedir}
-	EOF
-	cp ${PN}.pc.template ${PN}.pc || die
-	cat <<-EOF >> ${PN}.pc
-		Libs: -L\${libdir} -ltbb
-		Libs.private: -lm -lrt
-	EOF
-	cp ${PN}.pc.template ${PN}malloc.pc || die
-	cat <<-EOF >> ${PN}malloc.pc
-		Libs: -L\${libdir} -ltbbmalloc
-		Libs.private: -lm -lrt
-	EOF
-	cp ${PN}.pc.template ${PN}malloc_proxy.pc || die
-	cat <<-EOF >> ${PN}malloc_proxy.pc
-		Libs: -L\${libdir} -ltbbmalloc_proxy
-		Libs.private: -lrt
-		Requires: tbbmalloc
-	EOF
-}
-
-local_src_compile() {
-	cd "${S}"
-
-	local comp arch
-
-	case ${MULTILIB_ABI_FLAG} in
-		abi_x86_64) arch=x86_64 ;;
-		abi_x86_32) arch=ia32 ;;
-	esac
-
-	case "$(tc-getCXX)" in
-		*g++*) comp="gcc" ;;
-		*ic*c) comp="icc" ;;
-		*clang*) comp="clang" ;;
-		*) die "compiler $(tc-getCXX) not supported by build system" ;;
-	esac
-
-	CXX="$(tc-getCXX)" \
-	CC="$(tc-getCC)" \
-	AS="$(tc-getAS)" \
-	arch=${arch} \
-	CPLUS_FLAGS="${CXXFLAGS}" \
-	emake compiler=${comp} work_dir="${BUILD_DIR}" tbb_root="${S}" $@
-}
-
-multilib_src_compile() {
-	local_src_compile tbb tbbmalloc
-}
-
-multilib_src_test() {
-	CXXFLAGS="${CXXFLAGS} -fabi-version=4" \
-	local_src_compile -j1 test
-}
-
-multilib_src_install() {
-	cd "${BUILD_DIR}_release" || die
-	local l
-	for l in $(find . -name lib\*.so.\*); do
-		dolib.so ${l}
-		local bl=$(basename ${l})
-		dosym ${bl} /usr/$(get_libdir)/${bl%.*}
-	done
-
-	cd "${BUILD_DIR}" || die
-	insinto /usr/$(get_libdir)/pkgconfig
-	doins *.pc
-}
-
-multilib_src_install_all() {
-	doheader -r include/*
-
-	dodoc README CHANGES doc/Release_Notes.txt
-	use doc && dohtml -r doc/html/*
-
-	if use examples ; then
-		insinto /usr/share/doc/${PF}/examples/build
-		doins build/*.inc
-		insinto /usr/share/doc/${PF}/examples
-		doins -r examples
-	fi
-}


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2017-02-01 21:38 Matthias Maier
  0 siblings, 0 replies; 10+ messages in thread
From: Matthias Maier @ 2017-02-01 21:38 UTC (permalink / raw
  To: gentoo-commits

commit:     215c304cb21e7400fd4fea5bb2eb82654e063d83
Author:     Matthias Maier <tamiko <AT> gentoo <DOT> org>
AuthorDate: Wed Feb  1 21:37:30 2017 +0000
Commit:     Matthias Maier <tamiko <AT> gentoo <DOT> org>
CommitDate: Wed Feb  1 21:38:11 2017 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=215c304c

dev-cpp/tbb: version bump to 2017.20161128

Package-Manager: Portage-2.3.3, Repoman-2.3.1

 dev-cpp/tbb/Manifest                               |   1 +
 dev-cpp/tbb/files/tbb-2017.20161128-build.patch    | 193 +++++++++++++++++++++
 .../tbb/files/tbb-2017.20161128-underlinking.patch |  15 ++
 dev-cpp/tbb/tbb-2017.20161128.ebuild               | 145 ++++++++++++++++
 4 files changed, 354 insertions(+)

diff --git a/dev-cpp/tbb/Manifest b/dev-cpp/tbb/Manifest
index 2f8b59e..71f464d 100644
--- a/dev-cpp/tbb/Manifest
+++ b/dev-cpp/tbb/Manifest
@@ -1 +1,2 @@
+DIST tbb2017_20161128oss_src.tgz 2965854 SHA256 c009166233c8ea0e34530a1c5f870b79314316d19e6876b37a7e7c854080a540 SHA512 3c48ce196d2d3557e86cea7ede9dea456bbaeb29dbed34210f99c6f380406403a6056ccfa3d5befe6b29c4f8a9ee58ca6da545249cf4ec4ec85b463e04e4518c WHIRLPOOL d1ce8d07ac002c617afa7c0aa1d5cad41928a6eefd064a744b4efdd0192dd310ad8cb32b949858a7c2c44211477deffc05dbd65e8101184d4cae26744143b922
 DIST tbb43_20150611oss_src.tgz 2757631 SHA256 221f85fe64e11c9638e43b3c57d5750c26683905fc90827c0bcfefdb286e79c9 SHA512 83d5d827706b774ef5cd6df8082e5d7f48683388684423bb40565dfc25892fc2e57c382f719b78087d83e51edb3f7f7215f33d8b5039b55c32788d80efa6e0b8 WHIRLPOOL 8e98162b2307c759fb26923d76ab784dea81e166c8bf5323869d234da59641c333e5ae30b4a224bccbf20d4f5f6b75c658589f519a165ea3ad7658322f148c72

diff --git a/dev-cpp/tbb/files/tbb-2017.20161128-build.patch b/dev-cpp/tbb/files/tbb-2017.20161128-build.patch
new file mode 100644
index 00000000..0806d6a
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2017.20161128-build.patch
@@ -0,0 +1,193 @@
+diff --git a/build/FreeBSD.gcc.inc b/build/FreeBSD.gcc.inc
+index e93f8f4..2b43c51 100644
+--- a/build/FreeBSD.gcc.inc
++++ b/build/FreeBSD.gcc.inc
+@@ -28,8 +28,8 @@ WARNING_KEY = -Wall
+ DYLIB_KEY = -shared
+ WARNING_SUPPRESS = -Wno-parentheses
+ 
+-CPLUS = g++ 
+-CONLY = gcc
++CPLUS = $(CXX)
++CONLY = $(CC)
+ LIB_LINK_FLAGS = -shared
+ LIBS = -lpthread 
+ C_FLAGS = $(CPLUS_FLAGS)
+@@ -42,7 +42,7 @@ ifneq (,$(shell gcc -dumpversion | egrep  "^([6-9])"))
+ endif
+ 
+ ifeq ($(cfg), release)
+-        CPLUS_FLAGS = -g -O2 -DUSE_PTHREAD
++        CPLUS_FLAGS = -g -DUSE_PTHREAD
+ endif
+ ifeq ($(cfg), debug)
+         CPLUS_FLAGS = -DTBB_USE_DEBUG -g -O0 -DUSE_PTHREAD
+@@ -59,22 +59,12 @@ ifeq (ia64,$(arch))
+     CPLUS_FLAGS += $(PIC_KEY)
+ endif 
+ 
+-ifeq (intel64,$(arch))
+-    CPLUS_FLAGS += -m64
+-    LIB_LINK_FLAGS += -m64
+-endif 
+-
+-ifeq (ia32,$(arch))
+-    CPLUS_FLAGS += -m32
+-    LIB_LINK_FLAGS += -m32
+-endif 
+-
+ #------------------------------------------------------------------------------
+ # Setting assembler data.
+ #------------------------------------------------------------------------------
+ ASSEMBLY_SOURCE=$(arch)-gas
+ ifeq (ia64,$(arch))
+-    ASM=as
++    ASM=$(AS)
+     TBB_ASM.OBJ = atomic_support.o lock_byte.o log2.o pause.o
+     MALLOC_ASM.OBJ = atomic_support.o lock_byte.o pause.o
+ endif 
+diff --git a/build/linux.clang.inc b/build/linux.clang.inc
+index 237caae..8d6914e 100644
+--- a/build/linux.clang.inc
++++ b/build/linux.clang.inc
+@@ -31,15 +31,15 @@ DYLIB_KEY = -shared
+ EXPORT_KEY = -Wl,--version-script,
+ LIBDL = -ldl
+ 
+-CPLUS = clang++
+-CONLY = clang
++CPLUS := $(CXX)
++CONLY := $(CC)
+ LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
+ LIBS += -lpthread -lrt
+ LINK_FLAGS = -Wl,-rpath-link=. -rdynamic
+ C_FLAGS = $(CPLUS_FLAGS)
+ 
+ ifeq ($(cfg), release)
+-        CPLUS_FLAGS = $(ITT_NOTIFY) -g -O2 -DUSE_PTHREAD
++        CPLUS_FLAGS = $(ITT_NOTIFY) -g -DUSE_PTHREAD
+ endif
+ ifeq ($(cfg), debug)
+         CPLUS_FLAGS = -DTBB_USE_DEBUG $(ITT_NOTIFY) -g -O0 -DUSE_PTHREAD
+@@ -60,24 +60,10 @@ MALLOC_ASM.OBJ=
+ 
+ ifeq (intel64,$(arch))
+     ITT_NOTIFY = -DDO_ITT_NOTIFY
+-    CPLUS_FLAGS += -m64
+-    LIB_LINK_FLAGS += -m64
+ endif
+ 
+ ifeq (ia32,$(arch))
+     ITT_NOTIFY = -DDO_ITT_NOTIFY
+-    CPLUS_FLAGS += -m32 -march=pentium4
+-    LIB_LINK_FLAGS += -m32
+-endif
+-
+-ifeq (ppc64,$(arch))
+-    CPLUS_FLAGS += -m64
+-    LIB_LINK_FLAGS += -m64
+-endif
+-
+-ifeq (ppc32,$(arch))
+-    CPLUS_FLAGS += -m32
+-    LIB_LINK_FLAGS += -m32
+ endif
+ 
+ ifeq (bg,$(arch))
+@@ -89,12 +75,6 @@ endif
+ # Setting assembler data.
+ #------------------------------------------------------------------------------
+ ASM = as
+-ifeq (intel64,$(arch))
+-    ASM_FLAGS += --64
+-endif
+-ifeq (ia32,$(arch))
+-    ASM_FLAGS += --32
+-endif
+ ifeq ($(cfg),debug)
+     ASM_FLAGS += -g
+ endif
+diff --git a/build/linux.gcc.inc b/build/linux.gcc.inc
+index b7ed0c5..a8e8f85 100644
+--- a/build/linux.gcc.inc
++++ b/build/linux.gcc.inc
+@@ -32,12 +32,12 @@ DYLIB_KEY = -shared
+ EXPORT_KEY = -Wl,--version-script,
+ LIBDL = -ldl
+ 
+-CPLUS = g++
+-CONLY = gcc
++CPLUS := $(CXX)
++CONLY := $(CC)
+ LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
+ LIBS += -lpthread -lrt
+ LINK_FLAGS = -Wl,-rpath-link=. -rdynamic
+-C_FLAGS = $(CPLUS_FLAGS)
++C_FLAGS := $(CPLUS_FLAGS)
+ 
+ # gcc 4.2 and higher support OpenMP
+ ifneq (,$(shell gcc -dumpversion | egrep  "^(4\.[2-9]|[5-9])"))
+@@ -68,7 +68,7 @@ ifneq (,$(shell gcc -dumpversion | egrep  "^([6-9])"))
+ endif
+ 
+ ifeq ($(cfg), release)
+-        CPLUS_FLAGS = $(ITT_NOTIFY) -g -O2 -DUSE_PTHREAD
++        CPLUS_FLAGS = $(ITT_NOTIFY) -g -DUSE_PTHREAD
+ endif
+ ifeq ($(cfg), debug)
+         CPLUS_FLAGS = -DTBB_USE_DEBUG $(ITT_NOTIFY) -g -O0 -DUSE_PTHREAD
+@@ -84,24 +84,12 @@ endif
+ 
+ ifeq (intel64,$(arch))
+     ITT_NOTIFY = -DDO_ITT_NOTIFY
+-    CPLUS_FLAGS += -m64 $(RTM_KEY)
+-    LIB_LINK_FLAGS += -m64
++    CPLUS_FLAGS += $(RTM_KEY)
+ endif
+ 
+ ifeq (ia32,$(arch))
+     ITT_NOTIFY = -DDO_ITT_NOTIFY
+-    CPLUS_FLAGS += -m32 -march=pentium4 $(RTM_KEY)
+-    LIB_LINK_FLAGS += -m32
+-endif
+-
+-ifeq (ppc64,$(arch))
+-    CPLUS_FLAGS += -m64
+-    LIB_LINK_FLAGS += -m64
+-endif
+-
+-ifeq (ppc32,$(arch))
+-    CPLUS_FLAGS += -m32
+-    LIB_LINK_FLAGS += -m32
++    CPLUS_FLAGS += $(RTM_KEY)
+ endif
+ 
+ ifeq (bg,$(arch))
+@@ -109,12 +97,6 @@ ifeq (bg,$(arch))
+     CONLY = $(firstword $(notdir $(shell which powerpc{64,32,}-bg{z..a}-linux-gcc 2>/dev/null)))
+ endif
+ 
+-# for some gcc versions on Solaris, -m64 may imply V9, but perhaps not everywhere (TODO: verify)
+-ifeq (sparc,$(arch))
+-    CPLUS_FLAGS    += -mcpu=v9 -m64
+-    LIB_LINK_FLAGS += -mcpu=v9 -m64
+-endif
+-
+ # automatically generate "IT" instructions when compiling for Thumb ISA
+ ifeq (armv7,$(arch))
+     CPLUS_FLAGS    += -Wa,-mimplicit-it=thumb
+@@ -123,13 +105,7 @@ endif
+ #------------------------------------------------------------------------------
+ # Setting assembler data.
+ #------------------------------------------------------------------------------
+-ASM = as
+-ifeq (intel64,$(arch))
+-    ASM_FLAGS += --64
+-endif
+-ifeq (ia32,$(arch))
+-    ASM_FLAGS += --32
+-endif
++ASM := $(AS)
+ ifeq ($(cfg),debug)
+     ASM_FLAGS += -g
+ endif

diff --git a/dev-cpp/tbb/files/tbb-2017.20161128-underlinking.patch b/dev-cpp/tbb/files/tbb-2017.20161128-underlinking.patch
new file mode 100644
index 00000000..5935017
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2017.20161128-underlinking.patch
@@ -0,0 +1,15 @@
+https://bugs.gentoo.org/show_bug.cgi?id=418447
+
+--- a/build/Makefile.test
++++ b/build/Makefile.test
+@@ -44,8 +44,8 @@
+     USE_PROXY_FLAG = $(DEFINE_KEY)HARNESS_USE_PROXY
+     CPLUS_FLAGS += $(USE_PROXY_FLAG)
+     LINK_TBB.LIB = $(PROXY.LIB)
+-    LIBS += $(LIBDL)
+-endif
++endif
++LIBS += $(LIBDL)
+ 
+ TEST_SUFFIXES=secondary compiler_builtins pic
+ include $(tbb_root)/build/common_rules.inc

diff --git a/dev-cpp/tbb/tbb-2017.20161128.ebuild b/dev-cpp/tbb/tbb-2017.20161128.ebuild
new file mode 100644
index 00000000..27d8e4b
--- /dev/null
+++ b/dev-cpp/tbb/tbb-2017.20161128.ebuild
@@ -0,0 +1,145 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit eutils flag-o-matic multilib-minimal toolchain-funcs versionator
+
+PV1="$(get_version_component_range 1)"
+PV2="$(get_version_component_range 2)"
+MYP="${PN}${PV1}_${PV2}oss"
+
+DESCRIPTION="High level abstract threading library"
+HOMEPAGE="http://www.threadingbuildingblocks.org/"
+SRC_URI="http://threadingbuildingblocks.org/sites/default/files/software_releases/source/${MYP}_src.tgz"
+LICENSE="GPL-2-with-exceptions"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ppc ~ppc64 ~x86 ~amd64-fbsd ~amd64-linux ~x86-linux"
+IUSE="debug doc examples"
+
+DEPEND=""
+RDEPEND="${DEPEND}"
+S="${WORKDIR}/${MYP}"
+
+PATCHES=(
+	"${FILESDIR}"/${P}-underlinking.patch
+	"${FILESDIR}"/${P}-build.patch
+)
+
+src_prepare() {
+	default
+
+	find include -name \*.html -delete || die
+
+	# Give it a soname on FreeBSD
+	echo 'LIB_LINK_FLAGS += -Wl,-soname=$(BUILDING_LIBRARY)' >>	build/FreeBSD.gcc.inc
+	# Set proper versionning on FreeBSD
+	sed -i -e '/.DLL =/s/$/.1/' build/FreeBSD.inc || die
+
+	use debug || sed -i -e '/_debug/d' Makefile
+}
+
+multilib_src_configure() {
+	# pc files are for debian and fedora compatibility
+	# some deps use them
+	cat <<-EOF > ${PN}.pc.template
+		prefix=${EPREFIX}/usr
+		libdir=\${prefix}/$(get_libdir)
+		includedir=\${prefix}/include
+		Name: ${PN}
+		Description: ${DESCRIPTION}
+		Version: ${PV}
+		URL: ${HOMEPAGE}
+		Cflags: -I\${includedir}
+	EOF
+	cp ${PN}.pc.template ${PN}.pc || die
+	cat <<-EOF >> ${PN}.pc
+		Libs: -L\${libdir} -ltbb
+		Libs.private: -lm -lrt
+	EOF
+	cp ${PN}.pc.template ${PN}malloc.pc || die
+	cat <<-EOF >> ${PN}malloc.pc
+		Libs: -L\${libdir} -ltbbmalloc
+		Libs.private: -lm -lrt
+	EOF
+	cp ${PN}.pc.template ${PN}malloc_proxy.pc || die
+	cat <<-EOF >> ${PN}malloc_proxy.pc
+		Libs: -L\${libdir} -ltbbmalloc_proxy
+		Libs.private: -lrt
+		Requires: tbbmalloc
+	EOF
+}
+
+local_src_compile() {
+	cd "${S}"
+
+	local comp arch
+
+	case ${MULTILIB_ABI_FLAG} in
+		abi_x86_64) arch=x86_64 ;;
+		abi_x86_32) arch=ia32 ;;
+		abi_ppc_64) arch=ppc64 ;;
+		abi_ppc_32) arch=ppc32 ;;
+	esac
+
+	case "$(tc-getCXX)" in
+		*g++*) comp="gcc" ;;
+		*ic*c) comp="icc" ;;
+		*clang*) comp="clang" ;;
+		*) die "compiler $(tc-getCXX) not supported by build system" ;;
+	esac
+
+	CXX="$(tc-getCXX)" \
+	CC="$(tc-getCC)" \
+	AS="$(tc-getAS)" \
+	arch=${arch} \
+	CPLUS_FLAGS="${CXXFLAGS}" \
+	emake compiler=${comp} work_dir="${BUILD_DIR}" tbb_root="${S}" $@
+}
+
+multilib_src_compile() {
+	local_src_compile tbb tbbmalloc
+}
+
+multilib_src_test() {
+	CXXFLAGS="${CXXFLAGS} -fabi-version=4" \
+	local_src_compile -j1 test
+}
+
+multilib_src_install() {
+	local bt
+	local buildtypes
+	if use debug ; then
+		buildtypes="release debug"
+	else
+		buildtypes="release"
+	fi
+	for bt in ${buildtypes}; do
+		cd "${BUILD_DIR}_${bt}" || die
+		local l
+		for l in $(find . -name lib\*.so.\*); do
+			dolib.so ${l}
+			local bl=$(basename ${l})
+			dosym ${bl} /usr/$(get_libdir)/${bl%.*}
+		done
+	done
+
+	cd "${BUILD_DIR}" || die
+	insinto /usr/$(get_libdir)/pkgconfig
+	doins *.pc
+}
+
+multilib_src_install_all() {
+	doheader -r include/*
+
+	dodoc README CHANGES doc/Release_Notes.txt
+	use doc && dohtml -r doc/html/*
+
+	if use examples ; then
+		insinto /usr/share/doc/${PF}/examples/build
+		doins build/*.inc
+		insinto /usr/share/doc/${PF}/examples
+		doins -r examples
+	fi
+}


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2020-03-18 17:04 Guilherme Amadio
  0 siblings, 0 replies; 10+ messages in thread
From: Guilherme Amadio @ 2020-03-18 17:04 UTC (permalink / raw
  To: gentoo-commits

commit:     88dd71d503544ff3d11c6653ff23b7a938430ac7
Author:     Guilherme Amadio <amadio <AT> gentoo <DOT> org>
AuthorDate: Wed Mar 18 17:02:57 2020 +0000
Commit:     Guilherme Amadio <amadio <AT> gentoo <DOT> org>
CommitDate: Wed Mar 18 17:03:21 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=88dd71d5

dev-cpp/tbb: version bump to 2020.1

Package-Manager: Portage-2.3.94, Repoman-2.3.21
Signed-off-by: Guilherme Amadio <amadio <AT> gentoo.org>

 dev-cpp/tbb/Manifest                              |   1 +
 dev-cpp/tbb/files/tbb-2020.1-makefile-debug.patch |  62 +++++++++
 dev-cpp/tbb/tbb-2020.1.ebuild                     | 151 ++++++++++++++++++++++
 3 files changed, 214 insertions(+)

diff --git a/dev-cpp/tbb/Manifest b/dev-cpp/tbb/Manifest
index 3123910d2a1..2b389097681 100644
--- a/dev-cpp/tbb/Manifest
+++ b/dev-cpp/tbb/Manifest
@@ -1,3 +1,4 @@
 DIST tbb-2018.20180312.tar.gz 2911740 BLAKE2B 5c6dab4a892f3b61ed0b02ea36dc41bebd5b33a22bcc3d5f2960f21e134f2eb9bccf1466193a573489e12638c0bb0bccc2da83f699968ffd62417f2d0f093289 SHA512 7ac74e714122e25f7704630d3d52992dbea54d1e761b5e487251a771f401aa864f78b8ddf11d78f38758088df387abb6987f6a2db562c86cbb28ba8f33a25680
 DIST tbb-2019.8.tar.gz 2580540 BLAKE2B 1cddb0c8ade6f6363811b7f9b323a2bb7739a18114acd56e1b4a13f33904ddff8cb6aec9b4b0add995cd307ff7815f0b55ce33fa64b7dd92c0062fbaa13d0833 SHA512 924a8dde011452a2c46c5152942a9835e76fe5610e08b69eb0e985de3fb46bdb49f0f628d10fa7704428f6e61ec63f7002da5399d47da6ee6004fa236d346dc8
+DIST tbb-2020.1.tar.gz 2639115 BLAKE2B 058438351738eeab01c230ec10ff0a1dde77e5cc4fd77f292c31ee0320f41d079c8f90fc06f4640ffa375d5f0c0b5fbed13ac5a64a9cb9f1737cb66bc80442ea SHA512 79810c27c84bd3b3432bef471fa1c782f1f162a0d1038e88c03a77499cc7aeaa10d57317729fd23472e2d0f358395955f7570e8c679685a552a833eb45cf5f1d
 DIST tbb2017_20161128oss_src.tgz 2965854 BLAKE2B 8c5aed6d8477297922767803617346feebb712d1f4b2df6d71a86f039b5563afc666454985e68a528a812aaad40b5fd0562bb91d357c45156fec46e5389ec542 SHA512 3c48ce196d2d3557e86cea7ede9dea456bbaeb29dbed34210f99c6f380406403a6056ccfa3d5befe6b29c4f8a9ee58ca6da545249cf4ec4ec85b463e04e4518c

diff --git a/dev-cpp/tbb/files/tbb-2020.1-makefile-debug.patch b/dev-cpp/tbb/files/tbb-2020.1-makefile-debug.patch
new file mode 100644
index 00000000000..b4313b375f5
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2020.1-makefile-debug.patch
@@ -0,0 +1,62 @@
+--- a/Makefile	2020-01-21 12:26:46.000000000 +0100
++++ b/Makefile	2020-03-18 16:21:37.589262099 +0100
+@@ -26,29 +26,29 @@
+ all: tbb tbbmalloc tbbproxy test examples
+ 
+ tbb: mkdir
+-	$(MAKE) -C "$(work_dir)_release"  -r -f $(tbb_root)/build/Makefile.tbb cfg=release
++	$(MAKE) -C "$(work_dir)_$(cfg)"  -r -f $(tbb_root)/build/Makefile.tbb cfg=$(cfg)
+ 
+ tbbmalloc: mkdir
+-	$(MAKE) -C "$(work_dir)_release"  -r -f $(tbb_root)/build/Makefile.tbbmalloc cfg=release malloc
++	$(MAKE) -C "$(work_dir)_$(cfg)"  -r -f $(tbb_root)/build/Makefile.tbbmalloc cfg=$(cfg) malloc
+ 
+ tbbproxy: mkdir
+-	$(MAKE) -C "$(work_dir)_release"  -r -f $(tbb_root)/build/Makefile.tbbproxy cfg=release tbbproxy
++	$(MAKE) -C "$(work_dir)_$(cfg)"  -r -f $(tbb_root)/build/Makefile.tbbproxy cfg=$(cfg) tbbproxy
+ 
+ tbbbind: mkdir
+-	$(MAKE) -C "$(work_dir)_release"  -r -f $(tbb_root)/build/Makefile.tbbbind cfg=release tbbbind
++	$(MAKE) -C "$(work_dir)_$(cfg)"  -r -f $(tbb_root)/build/Makefile.tbbbind cfg=$(cfg) tbbbind
+ 
+ test: tbb tbbmalloc $(if $(use_proxy),tbbproxy)
+-	-$(MAKE) -C "$(work_dir)_release"  -r -f $(tbb_root)/build/Makefile.tbbmalloc cfg=release malloc_test
+-	-$(MAKE) -C "$(work_dir)_release"  -r -f $(tbb_root)/build/Makefile.test cfg=release
++	-$(MAKE) -C "$(work_dir)_$(cfg)"  -r -f $(tbb_root)/build/Makefile.tbbmalloc cfg=$(cfg) malloc_test
++	-$(MAKE) -C "$(work_dir)_$(cfg)"  -r -f $(tbb_root)/build/Makefile.test cfg=$(cfg)
+ 
+ rml: mkdir
+-	$(MAKE) -C "$(work_dir)_release"  -r -f $(tbb_root)/build/Makefile.rml cfg=release
++	$(MAKE) -C "$(work_dir)_$(cfg)"  -r -f $(tbb_root)/build/Makefile.rml cfg=$(cfg)
+ 
+ examples: tbb tbbmalloc
+-	$(MAKE) -C examples -r -f Makefile tbb_root=.. release test
++	$(MAKE) -C examples -r -f Makefile tbb_root=.. $(cfg) test
+ 
+ python: tbb
+-	$(MAKE) -C "$(work_dir)_release" -rf $(tbb_root)/python/Makefile install
++	$(MAKE) -C "$(work_dir)_$(cfg)" -rf $(tbb_root)/python/Makefile install
+ 
+ doxygen:
+ 	doxygen Doxyfile
+@@ -56,16 +56,16 @@
+ .PHONY: clean clean_examples mkdir info
+ 
+ clean: clean_examples
+-	$(shell $(RM) $(work_dir)_release$(SLASH)*.* >$(NUL) 2>$(NUL))
+-	$(shell $(RD) $(work_dir)_release >$(NUL) 2>$(NUL))
++	$(shell $(RM) $(work_dir)_$(cfg)$(SLASH)*.* >$(NUL) 2>$(NUL))
++	$(shell $(RD) $(work_dir)_$(cfg) >$(NUL) 2>$(NUL))
+ 	@echo clean done
+ 
+ clean_examples:
+ 	$(shell $(MAKE) -s -i -r -C examples -f Makefile tbb_root=.. clean >$(NUL) 2>$(NUL))
+ 
+ mkdir:
+-	$(shell $(MD) "$(work_dir)_release" >$(NUL) 2>$(NUL))
+-	@echo Created the $(work_dir)_release directory
++	$(shell $(MD) "$(work_dir)_$(cfg)" >$(NUL) 2>$(NUL))
++	@echo Created the $(work_dir)_$(cfg) directory
+ 
+ info:
+ 	@echo OS: $(tbb_os)

diff --git a/dev-cpp/tbb/tbb-2020.1.ebuild b/dev-cpp/tbb/tbb-2020.1.ebuild
new file mode 100644
index 00000000000..4ed58041f01
--- /dev/null
+++ b/dev-cpp/tbb/tbb-2020.1.ebuild
@@ -0,0 +1,151 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit eutils flag-o-matic multilib-minimal multilib toolchain-funcs
+
+PV1="$(ver_cut 1)"
+PV2="$(ver_cut 2)"
+MY_PV="${PV1}_U${PV2}"
+
+DESCRIPTION="High level abstract threading library"
+HOMEPAGE="https://www.threadingbuildingblocks.org"
+SRC_URI="https://github.com/intel/${PN}/archive/${MY_PV}.tar.gz -> ${P}.tar.gz"
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux"
+IUSE="debug examples"
+
+DEPEND=""
+RDEPEND="${DEPEND}"
+S="${WORKDIR}/oneTBB-${MY_PV}"
+
+DOCS=( CHANGES README README.md doc/Release_Notes.txt )
+
+PATCHES=( "${FILESDIR}"/${P}-makefile-debug.patch )
+
+src_prepare() {
+	default
+
+	find include -name \*.html -delete || die
+
+	# Give it a soname on FreeBSD
+	echo 'LIB_LINK_FLAGS += -Wl,-soname=$(BUILDING_LIBRARY)' >>	build/FreeBSD.gcc.inc
+	# Set proper versionning on FreeBSD
+	sed -i -e '/.DLL =/s/$/.1/' build/FreeBSD.inc || die
+
+	use debug || sed -i -e '/_debug/d' Makefile
+}
+
+multilib_src_configure() {
+	# pc files are for debian and fedora compatibility
+	# some deps use them
+	cat <<-EOF > ${PN}.pc.template
+		prefix=${EPREFIX}/usr
+		libdir=\${prefix}/$(get_libdir)
+		includedir=\${prefix}/include
+		Name: ${PN}
+		Description: ${DESCRIPTION}
+		Version: ${PV}
+		URL: ${HOMEPAGE}
+		Cflags: -I\${includedir}
+	EOF
+	cp ${PN}.pc.template ${PN}.pc || die
+	cat <<-EOF >> ${PN}.pc
+		Libs: -L\${libdir} -ltbb
+		Libs.private: -lm -lrt
+	EOF
+	cp ${PN}.pc.template ${PN}malloc.pc || die
+	cat <<-EOF >> ${PN}malloc.pc
+		Libs: -L\${libdir} -ltbbmalloc
+		Libs.private: -lm -lrt
+	EOF
+	cp ${PN}.pc.template ${PN}malloc_proxy.pc || die
+	cat <<-EOF >> ${PN}malloc_proxy.pc
+		Libs: -L\${libdir} -ltbbmalloc_proxy
+		Libs.private: -lrt
+		Requires: tbbmalloc
+	EOF
+}
+
+local_src_compile() {
+	cd "${S}"
+
+	local comp arch
+	local bt buildtypes
+
+	case ${MULTILIB_ABI_FLAG} in
+		abi_x86_64) arch=x86_64 ;;
+		abi_x86_32) arch=ia32 ;;
+#		abi_ppc_64) arch=ppc64 ;;
+#		abi_ppc_32) arch=ppc32 ;;
+	esac
+
+	case "$(tc-getCXX)" in
+		*clang*) comp="clang" ;;
+		*g++*) comp="gcc" ;;
+		*ic*c) comp="icc" ;;
+		*) die "compiler $(tc-getCXX) not supported by build system" ;;
+	esac
+
+	if use debug ; then
+		buildtypes="release debug"
+	else
+		buildtypes="release"
+	fi
+
+	for bt in ${buildtypes}; do
+		CXX="$(tc-getCXX)" \
+		CC="$(tc-getCC)" \
+		AS="$(tc-getAS)" \
+		arch=${arch} \
+		CPLUS_FLAGS="${CXXFLAGS}" \
+		emake compiler=${comp} work_dir="${BUILD_DIR}" tbb_root="${S}" cfg=${bt} $@
+	done
+}
+
+multilib_src_compile() {
+	local_src_compile tbb tbbmalloc
+}
+
+multilib_src_test() {
+	local_src_compile test
+}
+
+multilib_src_install() {
+	local bt
+	local buildtypes
+	if use debug ; then
+		buildtypes="release debug"
+	else
+		buildtypes="release"
+	fi
+	for bt in ${buildtypes}; do
+		cd "${BUILD_DIR}_${bt}" || die
+		local l
+		for l in $(find . -name lib\*$(get_libname \*)); do
+			dolib.so ${l}
+			local bl=$(basename ${l})
+			dosym ${bl} /usr/$(get_libdir)/${bl%%.*}$(get_libname)
+		done
+	done
+
+	cd "${BUILD_DIR}" || die
+	insinto /usr/$(get_libdir)/pkgconfig
+	doins *.pc
+}
+
+multilib_src_install_all() {
+	doheader -r include/*
+
+	einstalldocs
+
+	if use examples ; then
+		insinto /usr/share/doc/${PF}/examples/build
+		doins build/*.inc
+		insinto /usr/share/doc/${PF}/examples
+		doins -r examples
+		docompress -x "/usr/share/doc/${PF}/examples"
+	fi
+}


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2022-01-16  6:45 Sam James
  0 siblings, 0 replies; 10+ messages in thread
From: Sam James @ 2022-01-16  6:45 UTC (permalink / raw
  To: gentoo-commits

commit:     f3cd6cd18b7f54edfedbd0015b28ce20b4bbcba6
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sun Jan 16 06:45:33 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sun Jan 16 06:45:33 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f3cd6cd1

dev-cpp/tbb: fix build on musl

Closes: https://bugs.gentoo.org/830698
Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-cpp/tbb/files/tbb-2021.5.0-musl-deepbind.patch | 25 ++++++++++++++++++++++
 dev-cpp/tbb/tbb-2021.5.0.ebuild                    |  1 +
 2 files changed, 26 insertions(+)

diff --git a/dev-cpp/tbb/files/tbb-2021.5.0-musl-deepbind.patch b/dev-cpp/tbb/files/tbb-2021.5.0-musl-deepbind.patch
new file mode 100644
index 000000000000..014a3863f452
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2021.5.0-musl-deepbind.patch
@@ -0,0 +1,25 @@
+https://github.com/oneapi-src/oneTBB/commit/883c2e5245c39624b3b5d6d56d5b203cf09eac38
+https://bugs.gentoo.org/830698
+
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 15 Dec 2021 08:08:07 -0800
+Subject: [PATCH] Musl/linux can not use RTLD_DEEPBIND (#684)
+
+Exclude non-glibc linux systems along with android
+Fixes
+src/tbb/dynamic_link.cpp:417:29: error: use
+ of undeclared identifier 'RTLD_DEEPBIND'                                                                                    |             flags = flags | RTLD_DEEPBIND;
+|                             ^
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+--- a/src/tbb/dynamic_link.cpp
++++ b/src/tbb/dynamic_link.cpp
+@@ -413,7 +413,7 @@ namespace r1 {
+         int flags = RTLD_NOW;
+         if (local_binding) {
+             flags = flags | RTLD_LOCAL;
+-#if __linux__ && !__ANDROID__ && !__TBB_USE_SANITIZERS
++#if (__linux__ && __GLIBC__) && !__TBB_USE_SANITIZERS
+             flags = flags | RTLD_DEEPBIND;
+ #endif
+         } else {

diff --git a/dev-cpp/tbb/tbb-2021.5.0.ebuild b/dev-cpp/tbb/tbb-2021.5.0.ebuild
index 0a18fece5fd1..2ab975036c65 100644
--- a/dev-cpp/tbb/tbb-2021.5.0.ebuild
+++ b/dev-cpp/tbb/tbb-2021.5.0.ebuild
@@ -25,6 +25,7 @@ BDEPEND="virtual/pkgconfig"
 PATCHES=(
 	# should be in.. 2022?
 	"${FILESDIR}"/${PN}-2021.4.0-lto.patch
+	"${FILESDIR}"/${PN}-2021.5.0-musl-deepbind.patch
 )
 
 src_configure() {


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2022-01-20 12:36 Sam James
  0 siblings, 0 replies; 10+ messages in thread
From: Sam James @ 2022-01-20 12:36 UTC (permalink / raw
  To: gentoo-commits

commit:     675d894c36bfd854d8f7624912d34e9dd6ca7177
Author:     Alex Fan <alex.fan.q <AT> gmail <DOT> com>
AuthorDate: Thu Jan 20 05:02:17 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Jan 20 12:30:58 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=675d894c

dev-cpp/tbb: fix undefined __TBB_machine_fetchadd4

Closes: https://bugs.gentoo.org/827883
Signed-off-by: Alex Fan <alex.fan.q <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/23878
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...bb-2021.4.0-missing-TBB_machine_fetchadd4.patch | 23 ++++++++++++++++++++++
 dev-cpp/tbb/tbb-2021.4.0.ebuild                    |  2 ++
 dev-cpp/tbb/tbb-2021.5.0.ebuild                    |  2 ++
 3 files changed, 27 insertions(+)

diff --git a/dev-cpp/tbb/files/tbb-2021.4.0-missing-TBB_machine_fetchadd4.patch b/dev-cpp/tbb/files/tbb-2021.4.0-missing-TBB_machine_fetchadd4.patch
new file mode 100644
index 000000000000..091cad5821e7
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2021.4.0-missing-TBB_machine_fetchadd4.patch
@@ -0,0 +1,23 @@
+https://github.com/oneapi-src/oneTBB/issues/186
+https://github.com/oneapi-src/oneTBB/pull/550
+https://bugs.gentoo.org/827883
+
+From: Felix Yan <felixonmars@archlinux.org>
+Date: Thu, 7 Oct 2021 14:16:16 +0800
+Subject: [PATCH] Define ITT_ARCH_IA64 when undefiend (#550)
+
+Upstream-Status: Merged in commit later than 2021.5.0
+
+--- a/src/tbb/tools_api/ittnotify_config.h
++++ b/src/tbb/tools_api/ittnotify_config.h
+@@ -147,6 +147,10 @@
+ #  define ITT_ARCH_IA32E 2
+ #endif /* ITT_ARCH_IA32E */
+ 
++#ifndef ITT_ARCH_IA64
++#  define ITT_ARCH_IA64 3
++#endif /* ITT_ARCH_IA64 */
++
+ #ifndef ITT_ARCH_ARM
+ #  define ITT_ARCH_ARM  4
+ #endif /* ITT_ARCH_ARM */

diff --git a/dev-cpp/tbb/tbb-2021.4.0.ebuild b/dev-cpp/tbb/tbb-2021.4.0.ebuild
index 930bcd958708..ff94b74527c2 100644
--- a/dev-cpp/tbb/tbb-2021.4.0.ebuild
+++ b/dev-cpp/tbb/tbb-2021.4.0.ebuild
@@ -24,6 +24,8 @@ BDEPEND="virtual/pkgconfig"
 
 PATCHES=(
 	"${FILESDIR}"/${P}-lto.patch
+	# bug 827883
+	"${FILESDIR}"/${P}-missing-TBB_machine_fetchadd4.patch
 )
 
 src_configure() {

diff --git a/dev-cpp/tbb/tbb-2021.5.0.ebuild b/dev-cpp/tbb/tbb-2021.5.0.ebuild
index 1fa9bfc11894..6b2ff50c7c4a 100644
--- a/dev-cpp/tbb/tbb-2021.5.0.ebuild
+++ b/dev-cpp/tbb/tbb-2021.5.0.ebuild
@@ -26,6 +26,8 @@ PATCHES=(
 	# should be in.. 2022?
 	"${FILESDIR}"/${PN}-2021.4.0-lto.patch
 	"${FILESDIR}"/${PN}-2021.5.0-musl-deepbind.patch
+	# bug 827883
+	"${FILESDIR}"/${PN}-2021.4.0-missing-TBB_machine_fetchadd4.patch
 	# need to verify this is in master
 	"${FILESDIR}"/${PN}-2021.5.0-musl-mallinfo.patch
 )


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2022-02-07  4:01 Sam James
  0 siblings, 0 replies; 10+ messages in thread
From: Sam James @ 2022-02-07  4:01 UTC (permalink / raw
  To: gentoo-commits

commit:     d4d7c559ae6598261d115f4db6b955d50c4a184c
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Feb  7 04:00:01 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Feb  7 04:01:01 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d4d7c559

dev-cpp/tbb: fix underlinking on musl

Avoid *context APIs.

In theory, may not be needed (shouldn't be) given we've fixed our packaging
of libucontext, but let's do this anyway as the fix is upstream, and it
avoids possible otehr issues.

Bug: https://github.com/rui314/mold/issues/281
Closes: https://bugs.gentoo.org/832700
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../tbb/files/tbb-2021.5.0-musl-setcontext.patch   | 30 ++++++++++++++++++++++
 ...{tbb-2021.5.0.ebuild => tbb-2021.5.0-r1.ebuild} |  2 ++
 2 files changed, 32 insertions(+)

diff --git a/dev-cpp/tbb/files/tbb-2021.5.0-musl-setcontext.patch b/dev-cpp/tbb/files/tbb-2021.5.0-musl-setcontext.patch
new file mode 100644
index 000000000000..111bbf123d9a
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2021.5.0-musl-setcontext.patch
@@ -0,0 +1,30 @@
+https://bugs.gentoo.org/832700
+https://github.com/oneapi-src/oneTBB/commit/6a15b64093c51ddc00bdf4a6b49d4bbec1574a12
+
+From: Rui Ueyama <rui314@gmail.com>
+Date: Fri, 4 Feb 2022 19:32:11 +0900
+Subject: [PATCH] Make tbb compile with musl libc (#748)
+
+TBB resumable tasks are implemented using getcontext() and setcontext()
+on Unix-like systems. These functions are deprecated in the recent
+versions of POSIX and may not exist. musl libc does not provide these
+functions.
+
+There's unfortunately no way to detect musl (musl intentionally do not
+define macros like `__MUSL__`), so __TBB_RESUMABLE_TASKS is defined if
+`__GLIBC__`. glibc-compatible libc's such as uClibc defines `__GLIBC__`,
+so it should work as a catch-all condition.
+
+Signed-off-by: Rui Ueyama <ruiu@cs.stanford.edu>
+--- a/include/oneapi/tbb/detail/_config.h
++++ b/include/oneapi/tbb/detail/_config.h
+@@ -268,7 +268,7 @@
+     #define __TBB_CPP20_COMPARISONS_PRESENT __TBB_CPP20_PRESENT
+ #endif
+ 
+-#define __TBB_RESUMABLE_TASKS                           (!__TBB_WIN8UI_SUPPORT && !__ANDROID__ && !__QNXNTO__)
++#define __TBB_RESUMABLE_TASKS                           (!__TBB_WIN8UI_SUPPORT && !__ANDROID__ && !__QNXNTO__ && (!__linux__ || __GLIBC__))
+ 
+ /* This macro marks incomplete code or comments describing ideas which are considered for the future.
+  * See also for plain comment with TODO and FIXME marks for small improvement opportunities.
+

diff --git a/dev-cpp/tbb/tbb-2021.5.0.ebuild b/dev-cpp/tbb/tbb-2021.5.0-r1.ebuild
similarity index 93%
rename from dev-cpp/tbb/tbb-2021.5.0.ebuild
rename to dev-cpp/tbb/tbb-2021.5.0-r1.ebuild
index 6b2ff50c7c4a..22d714102105 100644
--- a/dev-cpp/tbb/tbb-2021.5.0.ebuild
+++ b/dev-cpp/tbb/tbb-2021.5.0-r1.ebuild
@@ -30,6 +30,8 @@ PATCHES=(
 	"${FILESDIR}"/${PN}-2021.4.0-missing-TBB_machine_fetchadd4.patch
 	# need to verify this is in master
 	"${FILESDIR}"/${PN}-2021.5.0-musl-mallinfo.patch
+	# musl again, should be in.. 2022?
+	"${FILESDIR}"/${PN}-2021.5.0-musl-setcontext.patch
 )
 
 src_configure() {


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2022-04-28  1:26 Sam James
  0 siblings, 0 replies; 10+ messages in thread
From: Sam James @ 2022-04-28  1:26 UTC (permalink / raw
  To: gentoo-commits

commit:     5ace694ca2a1bd0f49996845f9122569fd9b6c18
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Thu Apr 28 01:23:52 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Apr 28 01:23:52 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5ace694c

dev-cpp/tbb: add flag stripping patch

Otherwise breaks with e.g. -Werror=format-security in *FLAGS.

Bug: https://github.com/oneapi-src/oneTBB/pull/716
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../tbb/files/tbb-2021.5.0-flags-stripping.patch   | 27 ++++++++++++++++++++++
 dev-cpp/tbb/tbb-2021.5.0-r1.ebuild                 |  2 ++
 2 files changed, 29 insertions(+)

diff --git a/dev-cpp/tbb/files/tbb-2021.5.0-flags-stripping.patch b/dev-cpp/tbb/files/tbb-2021.5.0-flags-stripping.patch
new file mode 100644
index 000000000000..4252ea446423
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2021.5.0-flags-stripping.patch
@@ -0,0 +1,27 @@
+https://github.com/oneapi-src/oneTBB/pull/716
+
+From 9595b9699ae6863d1e0cf770a89728eafcaf8845 Mon Sep 17 00:00:00 2001
+From: Christoph Erhardt <github@sicherha.de>
+Date: Wed, 5 Jan 2022 15:13:32 +0100
+Subject: [PATCH] Fix overeager stripping of compile flag
+
+The existing regex strips all occurrences of the given string from
+`${CMAKE_CXX_FLAGS}`, regardless of whether it is just a substring of a
+flag. For instance, `-Werror=format-security` gets truncated to
+`=format-security`.
+
+The new regex makes sure that only whole words get replaced.
+
+Signed-off-by: Christoph Erhardt <github@sicherha.de>
+--- a/cmake/utils.cmake
++++ b/cmake/utils.cmake
+@@ -18,7 +18,7 @@ macro(tbb_remove_compile_flag flag)
+     set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY COMPILE_OPTIONS ${_tbb_compile_options})
+     unset(_tbb_compile_options)
+     if (CMAKE_CXX_FLAGS)
+-        string(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
++        string(REGEX REPLACE "(^|[ \t\r\n]+)${flag}($|[ \t\r\n]+)" " " CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
+     endif()
+ endmacro()
+ 
+

diff --git a/dev-cpp/tbb/tbb-2021.5.0-r1.ebuild b/dev-cpp/tbb/tbb-2021.5.0-r1.ebuild
index aa3f0e7c26e2..8c4c5a5883a4 100644
--- a/dev-cpp/tbb/tbb-2021.5.0-r1.ebuild
+++ b/dev-cpp/tbb/tbb-2021.5.0-r1.ebuild
@@ -32,6 +32,8 @@ PATCHES=(
 	"${FILESDIR}"/${PN}-2021.5.0-musl-mallinfo.patch
 	# musl again, should be in.. 2022?
 	"${FILESDIR}"/${PN}-2021.5.0-musl-setcontext.patch
+
+	"${FILESDIR}"/${PN}-2021.5.0-flags-stripping.patch
 )
 
 src_configure() {


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2022-11-19  3:19 Sam James
  0 siblings, 0 replies; 10+ messages in thread
From: Sam James @ 2022-11-19  3:19 UTC (permalink / raw
  To: gentoo-commits

commit:     ae4a95da4cdb44ac97adfc4c48d89317c315b5d1
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sat Nov 19 02:27:29 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Nov 19 03:19:13 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ae4a95da

dev-cpp/tbb: backport pthread EAGAIN patch for mold

Closes: https://bugs.gentoo.org/881161
Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../tbb/files/tbb-2021.7.0-pthread-eagain.patch    | 135 +++++++++++++++++++++
 dev-cpp/tbb/tbb-2021.7.0-r1.ebuild                 |  41 +++++++
 2 files changed, 176 insertions(+)

diff --git a/dev-cpp/tbb/files/tbb-2021.7.0-pthread-eagain.patch b/dev-cpp/tbb/files/tbb-2021.7.0-pthread-eagain.patch
new file mode 100644
index 000000000000..6c0912ec96b7
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2021.7.0-pthread-eagain.patch
@@ -0,0 +1,135 @@
+https://bugs.gentoo.org/881161
+https://github.com/rui314/mold/issues/410
+https://github.com/oneapi-src/oneTBB/commit/ceacd2207edfb72a8fc235213265afe68ce74ad0
+https://github.com/oneapi-src/oneTBB/commit/137c1a88b690acf3525e0f279720ac489ce66481
+
+From ceacd2207edfb72a8fc235213265afe68ce74ad0 Mon Sep 17 00:00:00 2001
+From: Ilya Isaev <ilya.isaev@intel.com>
+Date: Wed, 26 Oct 2022 13:13:51 +0200
+Subject: [PATCH] Rework test_eh_thread to avoid sporadic failures (#946)
+
+Signed-off-by: Isaev, Ilya <ilya.isaev@intel.com>
+--- a/test/tbb/test_eh_thread.cpp
++++ b/test/tbb/test_eh_thread.cpp
+@@ -54,15 +54,16 @@ void limitThreads(size_t limit)
+     CHECK_MESSAGE(0 == ret, "setrlimit has returned an error");
+ }
+ 
+-static bool g_exception_caught = false;
+-static std::mutex m;
+-static std::condition_variable cv;
+-static std::atomic<bool> stop{ false };
++size_t getThreadLimit() {
++    rlimit rlim;
++
++    int ret = getrlimit(RLIMIT_NPROC, &rlim);
++    CHECK_MESSAGE(0 == ret, "getrlimit has returned an error");
++    return rlim.rlim_cur;
++}
+ 
+ static void* thread_routine(void*)
+ {
+-    std::unique_lock<std::mutex> lock(m);
+-    cv.wait(lock, [] { return stop == true; });
+     return nullptr;
+ }
+ 
+@@ -94,32 +95,17 @@ TEST_CASE("Too many threads") {
+     }
+ 
+     // Some systems set really big limit (e.g. >45К) for the number of processes/threads
+-    limitThreads(1024);
+-
+-    std::thread /* isolate test */ ([] {
+-        std::vector<Thread> threads;
+-        stop = false;
+-        auto finalize = [&] {
+-            stop = true;
+-            cv.notify_all();
+-            for (auto& t : threads) {
+-                t.join();
+-            }
+-        };
+-
+-        for (int i = 0;; ++i) {
++    limitThreads(1);
++    if (getThreadLimit() == 1) {
++        for (int attempt = 0; attempt < 5; ++attempt) {
+             Thread thread;
+-            if (!thread.isValid()) {
+-                break;
+-            }
+-            threads.push_back(thread);
+-            if (i == 1024) {
+-                WARN_MESSAGE(false, "setrlimit seems having no effect");
+-                finalize();
++            if (thread.isValid()) {
++                WARN_MESSAGE(false, "We were able to create a thread. setrlimit seems having no effect");
++                thread.join();
+                 return;
+             }
+         }
+-        g_exception_caught = false;
++        bool g_exception_caught = false;
+         try {
+             // Initialize the library to create worker threads
+             tbb::parallel_for(0, 2, [](int) {});
+@@ -132,9 +118,10 @@ TEST_CASE("Too many threads") {
+         }
+         // Do not CHECK to avoid memory allocation (we can be out of memory)
+         if (!g_exception_caught) {
+-            FAIL("No exception was caught");
++            FAIL("No exception was thrown on library initialization");
+         }
+-        finalize();
+-    }).join();
++    } else {
++        WARN_MESSAGE(false, "setrlimit seems having no effect");
++    }
+ }
+ #endif
+
+From 137c1a88b690acf3525e0f279720ac489ce66481 Mon Sep 17 00:00:00 2001
+From: Rui Ueyama <ruiu@cs.stanford.edu>
+Date: Wed, 26 Oct 2022 04:54:20 -0700
+Subject: [PATCH] Retry if pthread_create fails with EAGAIN (#824)
+
+Signed-off-by: Rui Ueyama <ruiu@cs.stanford.edu>
+--- a/src/tbb/rml_thread_monitor.h
++++ b/src/tbb/rml_thread_monitor.h
+@@ -31,6 +31,7 @@
+ #include <pthread.h>
+ #include <cstring>
+ #include <cstdlib>
++#include <time.h>
+ #else
+ #error Unsupported platform
+ #endif
+@@ -191,8 +192,25 @@ inline thread_monitor::handle_type thread_monitor::launch( void* (*thread_routin
+     check(pthread_attr_init( &s ), "pthread_attr_init has failed");
+     if( stack_size>0 )
+         check(pthread_attr_setstacksize( &s, stack_size ), "pthread_attr_setstack_size has failed" );
++
++    // pthread_create(2) can spuriously fail with EAGAIN. We retry
++    // max_num_tries times with progressively longer wait times.
+     pthread_t handle;
+-    check( pthread_create( &handle, &s, thread_routine, arg ), "pthread_create has failed" );
++    const int max_num_tries = 20;
++    int error = EAGAIN;
++
++    for (int i = 0; i < max_num_tries && error == EAGAIN; i++) {
++      if (i != 0) {
++        // Wait i milliseconds
++        struct timespec ts = {0, i * 1000 * 1000};
++        nanosleep(&ts, NULL);
++      }
++      error = pthread_create(&handle, &s, thread_routine, arg);
++    }
++
++    if (error)
++      handle_perror(error, "pthread_create has failed");
++
+     check( pthread_attr_destroy( &s ), "pthread_attr_destroy has failed" );
+     return handle;
+ }
+

diff --git a/dev-cpp/tbb/tbb-2021.7.0-r1.ebuild b/dev-cpp/tbb/tbb-2021.7.0-r1.ebuild
new file mode 100644
index 000000000000..d88f920769a0
--- /dev/null
+++ b/dev-cpp/tbb/tbb-2021.7.0-r1.ebuild
@@ -0,0 +1,41 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake-multilib flag-o-matic
+
+DESCRIPTION="High level abstract threading library"
+HOMEPAGE="https://www.threadingbuildingblocks.org"
+SRC_URI="https://github.com/oneapi-src/oneTBB/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/oneTBB-${PV}"
+
+LICENSE="Apache-2.0"
+# https://github.com/oneapi-src/oneTBB/blob/master/CMakeLists.txt#L53
+# libtbb<SONAME>-libtbbmalloc<SONAME>-libtbbbind<SONAME>
+SLOT="0/12.5-2.5-3.5"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="!kernel_Darwin? ( sys-apps/hwloc:= )"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-2021.7.0-pthread-eagain.patch
+)
+
+src_configure() {
+	# bug #872287
+	filter-flags -D_GLIBCXX_ASSERTIONS
+	append-cppflags -U_GLIBCXX_ASSERTIONS
+
+	local mycmakeargs=(
+		-DTBB_TEST=$(usex test)
+		-DTBB_ENABLE_IPO=OFF
+		-DTBB_STRICT=OFF
+	)
+
+	cmake-multilib_src_configure
+}


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2023-04-28  0:47 Sam James
  0 siblings, 0 replies; 10+ messages in thread
From: Sam James @ 2023-04-28  0:47 UTC (permalink / raw
  To: gentoo-commits

commit:     a9037e17ac83d5013b3393c7b703809a99574bc4
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 28 00:46:53 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Apr 28 00:46:53 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a9037e17

dev-cpp/tbb: fix build w/ gcc 13

Closes: https://bugs.gentoo.org/899746
Signed-off-by: Sam James <sam <AT> gentoo.org>

 dev-cpp/tbb/files/tbb-2020.3-gcc13.patch | 35 ++++++++++++++++++++++++++++++++
 dev-cpp/tbb/tbb-2020.3.ebuild            |  7 +++++--
 2 files changed, 40 insertions(+), 2 deletions(-)

diff --git a/dev-cpp/tbb/files/tbb-2020.3-gcc13.patch b/dev-cpp/tbb/files/tbb-2020.3-gcc13.patch
new file mode 100644
index 000000000000..1c0803048ca7
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2020.3-gcc13.patch
@@ -0,0 +1,35 @@
+https://bugs.gentoo.org/899746
+https://github.com/oneapi-src/oneTBB/pull/833
+
+From c18342ba667d1f33f5e9a773aa86b091a9694b97 Mon Sep 17 00:00:00 2001
+From: Sergei Trofimovich <slyich@gmail.com>
+Date: Fri, 20 May 2022 07:50:00 +0100
+Subject: [PATCH] tbb_2020: fix build on gcc-13
+
+On gcc-13 build started failing due to 'task' identifier collision as:
+
+    ../../include/tbb/task.h:300:20: error: declaration of 'tbb::task& tbb::internal::task_prefix::task()' changes meaning of 'task' [-fpermissive]
+      300 |         tbb::task& task() {return *reinterpret_cast<tbb::task*>(this+1);}
+          |                    ^~~~
+    ../../include/tbb/task.h:252:9: note: used here to mean 'class tbb::task'
+      252 |         task* next_offloaded;
+          |         ^~~~
+    ../../include/tbb/task.h:43:7: note: declared here
+       43 | class task;
+          |       ^~~~
+
+The change adds explicit qualifier to class name to avoid ambiguity with method name.
+
+Signed-off-by: Sergei Trofimovich <slyich@gmail.com>
+--- a/include/tbb/task.h
++++ b/include/tbb/task.h
+@@ -249,7 +249,7 @@ namespace internal {
+ #if __TBB_TASK_PRIORITY
+         //! Pointer to the next offloaded lower priority task.
+         /** Used to maintain a list of offloaded tasks inside the scheduler. **/
+-        task* next_offloaded;
++        tbb::task* next_offloaded;
+ #endif
+ 
+ #if __TBB_PREVIEW_RESUMABLE_TASKS
+

diff --git a/dev-cpp/tbb/tbb-2020.3.ebuild b/dev-cpp/tbb/tbb-2020.3.ebuild
index f784dbdaec54..9e6f7e2e6797 100644
--- a/dev-cpp/tbb/tbb-2020.3.ebuild
+++ b/dev-cpp/tbb/tbb-2020.3.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
@@ -23,7 +23,10 @@ S="${WORKDIR}/oneTBB-${MY_PV}"
 
 DOCS=( CHANGES README README.md doc/Release_Notes.txt )
 
-PATCHES=( "${FILESDIR}"/${PN}-2020.1-makefile-debug.patch )
+PATCHES=(
+	"${FILESDIR}"/${PN}-2020.1-makefile-debug.patch
+	"${FILESDIR}"/${PN}-2020.3-gcc13.patch
+)
 
 src_prepare() {
 	default


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/
@ 2024-07-14 22:39 James Le Cuirot
  0 siblings, 0 replies; 10+ messages in thread
From: James Le Cuirot @ 2024-07-14 22:39 UTC (permalink / raw
  To: gentoo-commits

commit:     52cd9426fc2dc5bd354e77b75bd29ad82c5b77d3
Author:     James Le Cuirot <chewi <AT> gentoo <DOT> org>
AuthorDate: Sun Jul 14 22:38:02 2024 +0000
Commit:     James Le Cuirot <chewi <AT> gentoo <DOT> org>
CommitDate: Sun Jul 14 22:38:02 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=52cd9426

dev-cpp/tbb: Fix 2021.13.0 tests on non-x86 32-bit arches with patch

Thanks to John Paul Adrian Glaubitz for the patch. It has been submitted but not
yet accepted upstream.

Closes: https://bugs.gentoo.org/911759
Signed-off-by: James Le Cuirot <chewi <AT> gentoo.org>

 dev-cpp/tbb/files/tbb-2021.13.0-test-atomics.patch | 38 ++++++++++++++++++++++
 dev-cpp/tbb/tbb-2021.13.0.ebuild                   |  1 +
 2 files changed, 39 insertions(+)

diff --git a/dev-cpp/tbb/files/tbb-2021.13.0-test-atomics.patch b/dev-cpp/tbb/files/tbb-2021.13.0-test-atomics.patch
new file mode 100644
index 000000000000..7cc8216153d0
--- /dev/null
+++ b/dev-cpp/tbb/files/tbb-2021.13.0-test-atomics.patch
@@ -0,0 +1,38 @@
+From c828ae47b8f4bea7736d2f9d05460e2b529c9d7d Mon Sep 17 00:00:00 2001
+From: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
+Date: Fri, 9 Dec 2022 12:36:11 +0100
+Subject: [PATCH] Add cmake check for libatomic requirement when building with
+ gcc (#980)
+
+Signed-off-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
+---
+ cmake/compilers/GNU.cmake | 16 ++++++++++++++++
+ 1 file changed, 16 insertions(+)
+
+diff --git a/cmake/compilers/GNU.cmake b/cmake/compilers/GNU.cmake
+index cd76acfe1e..59f4e6934f 100644
+--- a/cmake/compilers/GNU.cmake
++++ b/cmake/compilers/GNU.cmake
+@@ -44,6 +44,22 @@ if (NOT MINGW)
+     set(TBB_COMMON_LINK_LIBS dl)
+ endif()
+ 
++# Check whether code with full atomics can be built without libatomic
++# see: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81358
++include(CheckCXXSourceCompiles)
++check_cxx_source_compiles("#include <atomic>
++int main() {
++  std::atomic<uint8_t> w1;
++  std::atomic<uint16_t> w2;
++  std::atomic<uint32_t> w4;
++  std::atomic<uint64_t> w8;
++  return ++w1 + ++w2 + ++w4 + ++w8;
++}" TBB_BUILDS_WITHOUT_LIBATOMIC)
++
++if(NOT TBB_BUILDS_WITHOUT_LIBATOMIC)
++   set(TBB_COMMON_LINK_LIBS ${TBB_COMMON_LINK_LIBS} atomic)
++endif()
++
+ # Ignore -Werror set through add_compile_options() or added to CMAKE_CXX_FLAGS if TBB_STRICT is disabled.
+ if (NOT TBB_STRICT AND COMMAND tbb_remove_compile_flag)
+     tbb_remove_compile_flag(-Werror)

diff --git a/dev-cpp/tbb/tbb-2021.13.0.ebuild b/dev-cpp/tbb/tbb-2021.13.0.ebuild
index 3ac69c080835..ac958e5973a4 100644
--- a/dev-cpp/tbb/tbb-2021.13.0.ebuild
+++ b/dev-cpp/tbb/tbb-2021.13.0.ebuild
@@ -24,6 +24,7 @@ BDEPEND="virtual/pkgconfig"
 
 PATCHES=(
 	"${FILESDIR}"/${PN}-2021.8.0-gcc-13.patch
+	"${FILESDIR}"/${PN}-2021.13.0-test-atomics.patch
 )
 
 src_prepare() {


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2024-07-14 22:39 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-01-16  6:45 [gentoo-commits] repo/gentoo:master commit in: dev-cpp/tbb/, dev-cpp/tbb/files/ Sam James
  -- strict thread matches above, loose matches on Subject: below --
2024-07-14 22:39 James Le Cuirot
2023-04-28  0:47 Sam James
2022-11-19  3:19 Sam James
2022-04-28  1:26 Sam James
2022-02-07  4:01 Sam James
2022-01-20 12:36 Sam James
2020-03-18 17:04 Guilherme Amadio
2017-02-01 21:38 Matthias Maier
2015-09-20 10:15 Justin Lecher

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox