package: Use tbb from buildroot
parent
67705b7eae
commit
efab92a104
|
@ -114,3 +114,4 @@ BR2_PACKAGE_HOST_E2TOOLS=y
|
|||
BR2_PACKAGE_HOST_PYTHON=y
|
||||
BR2_PACKAGE_LIBFUSE=y
|
||||
BR2_PACKAGE_PAHOLE=y
|
||||
BR2_PACKAGE_TBB=y
|
||||
|
|
|
@ -114,3 +114,4 @@ BR2_PACKAGE_HOST_E2TOOLS=y
|
|||
BR2_PACKAGE_HOST_PYTHON=y
|
||||
BR2_PACKAGE_LIBFUSE=y
|
||||
BR2_PACKAGE_PAHOLE=y
|
||||
BR2_PACKAGE_TBB=y
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
menu "System tools"
|
||||
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/conmon/Config.in"
|
||||
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/crio-bin/Config.in"
|
||||
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/tbb/Config.in"
|
||||
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/sysdig/Config.in"
|
||||
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/crun/Config.in"
|
||||
source "$BR2_EXTERNAL_MINIKUBE_PATH/package/cni/Config.in"
|
||||
|
|
|
@ -1,55 +0,0 @@
|
|||
From 42c3faff14917f687aab405d8f571e352ffdf3f5 Mon Sep 17 00:00:00 2001
|
||||
From: Francis Laniel <flaniel@linux.microsoft.com>
|
||||
Date: Wed, 6 Apr 2022 15:58:02 +0100
|
||||
Subject: [PATCH] tbb: Enable cross-compilation.
|
||||
|
||||
This patch replaces hardcoded value for CPLUS and CONLY with $(CXX) and $(CC).
|
||||
So, by defining CC= it is possible to cross compile this library using a
|
||||
cross-compiler.
|
||||
|
||||
This patch was originally written by:
|
||||
Marcin Juszkiewicz <marcin.juszkiewicz@linaro.org>
|
||||
and taken from:
|
||||
https://github.com/intel/luv-yocto/blob/3b0688bc9a5e8d52b6ca461b15fb4abd3eaaf7a8/meta-oe/recipes-support/tbb/tbb/cross-compile.patch
|
||||
|
||||
Signed-off-by: Francis Laniel <flaniel@linux.microsoft.com>
|
||||
---
|
||||
build/linux.clang.inc | 5 +++--
|
||||
build/linux.gcc.inc | 5 +++--
|
||||
2 files changed, 6 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/build/linux.clang.inc b/build/linux.clang.inc
|
||||
index 5a459ef5..a0777db5 100644
|
||||
--- a/build/linux.clang.inc
|
||||
+++ b/build/linux.clang.inc
|
||||
@@ -31,8 +31,9 @@ DYLIB_KEY = -shared
|
||||
EXPORT_KEY = -Wl,--version-script,
|
||||
LIBDL = -ldl
|
||||
|
||||
-CPLUS = clang++
|
||||
-CONLY = clang
|
||||
+CPLUS = $(CXX)
|
||||
+CONLY = $(CC)
|
||||
+CPLUS_FLAGS = $(CXXFLAGS)
|
||||
LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
|
||||
LIBS += -lpthread -lrt
|
||||
LINK_FLAGS = -Wl,-rpath-link=. -rdynamic
|
||||
diff --git a/build/linux.gcc.inc b/build/linux.gcc.inc
|
||||
index 786c4153..30242a82 100644
|
||||
--- a/build/linux.gcc.inc
|
||||
+++ b/build/linux.gcc.inc
|
||||
@@ -32,8 +32,9 @@ DYLIB_KEY = -shared
|
||||
EXPORT_KEY = -Wl,--version-script,
|
||||
LIBDL = -ldl
|
||||
|
||||
-CPLUS = g++
|
||||
-CONLY = gcc
|
||||
+CPLUS = $(CXX)
|
||||
+CONLY = $(CC)
|
||||
+CPLUS_FLAGS = $(CXXFLAGS)
|
||||
LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
|
||||
LIBS += -lpthread -lrt
|
||||
LINK_FLAGS = -Wl,-rpath-link=. -rdynamic
|
||||
--
|
||||
2.25.1
|
||||
|
|
@ -1,16 +0,0 @@
|
|||
config BR2_PACKAGE_TBB
|
||||
bool "tbb"
|
||||
depends on BR2_TOOLCHAIN_USES_GLIBC
|
||||
depends on !BR2_STATIC_LIBS
|
||||
depends on BR2_TOOLCHAIN_HAS_THREADS
|
||||
depends on BR2_INSTALL_LIBSTDCPP
|
||||
help
|
||||
Intel(R) Threading Building Blocks (Intel(R) TBB) lets you
|
||||
easily write parallel C++ programs that take full advantage
|
||||
of multicore performance, that are portable, composable and
|
||||
have future-proof scalability.
|
||||
|
||||
https://www.threadingbuildingblocks.org/
|
||||
|
||||
comment "tbb needs a glibc toolchain w/ dynamic library, threads, C++"
|
||||
depends on !BR2_TOOLCHAIN_USES_GLIBC || BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS || !BR2_INSTALL_LIBSTDCPP
|
|
@ -1,2 +0,0 @@
|
|||
# Locally calculated
|
||||
sha256 b8dbab5aea2b70cf07844f86fa413e549e099aa3205b6a04059ca92ead93a372 tbb-2018_U5.tar.gz
|
|
@ -1,39 +0,0 @@
|
|||
################################################################################
|
||||
#
|
||||
# tbb
|
||||
#
|
||||
################################################################################
|
||||
|
||||
TBB_VERSION = 2018_U5
|
||||
TBB_SITE = $(call github,01org,tbb,$(TBB_VERSION))
|
||||
TBB_INSTALL_STAGING = YES
|
||||
TBB_LICENSE = Apache-2.0
|
||||
TBB_LICENSE_FILES = LICENSE
|
||||
|
||||
TBB_SO_VERSION = 2
|
||||
TBB_LIBS = libtbb libtbbmalloc libtbbmalloc_proxy
|
||||
TBB_BIN_PATH = $(@D)/build/linux_*
|
||||
|
||||
define TBB_BUILD_CMDS
|
||||
$(MAKE) $(TARGET_CONFIGURE_OPTS) arch=$(BR2_ARCH) -C $(@D)
|
||||
endef
|
||||
|
||||
define TBB_INSTALL_LIBS
|
||||
$(foreach lib,$(TBB_LIBS),
|
||||
$(INSTALL) -D -m 0755 $(TBB_BIN_PATH)/$(lib).so.$(TBB_SO_VERSION) \
|
||||
$(1)/usr/lib/$(lib).so.$(TBB_SO_VERSION) ;
|
||||
ln -sf $(lib).so.$(TBB_SO_VERSION) $(1)/usr/lib/$(lib).so
|
||||
)
|
||||
endef
|
||||
|
||||
define TBB_INSTALL_STAGING_CMDS
|
||||
mkdir -p $(STAGING_DIR)/usr/include/
|
||||
cp -a $(@D)/include/* $(STAGING_DIR)/usr/include/
|
||||
$(call TBB_INSTALL_LIBS,$(STAGING_DIR))
|
||||
endef
|
||||
|
||||
define TBB_INSTALL_TARGET_CMDS
|
||||
$(call TBB_INSTALL_LIBS,$(TARGET_DIR))
|
||||
endef
|
||||
|
||||
$(eval $(generic-package))
|
Loading…
Reference in New Issue