From 3e74d041c94782e8e62067d338968a93de601ab1 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sun, 28 Jul 2019 01:53:39 +0200 Subject: [PATCH] Link with Thread Building Blocks, if available. --- capture/build/unix/build.mk | 5 +++++ profiler/build/unix/build.mk | 5 +++++ update/build/unix/build.mk | 5 +++++ 3 files changed, 15 insertions(+) diff --git a/capture/build/unix/build.mk b/capture/build/unix/build.mk index 380601dc..fc0dca4d 100644 --- a/capture/build/unix/build.mk +++ b/capture/build/unix/build.mk @@ -14,6 +14,11 @@ BASE2 := $(shell egrep 'ClCompile.*c"' ../win32/$(PROJECT).vcxproj | sed -e 's/. SRC := $(filter-out $(FILTER),$(BASE)) SRC2 := $(filter-out $(FILTER),$(BASE2)) +TBB := $(shell ld -ltbb -o /dev/null 2>/dev/null; echo $$?) +ifeq ($(TBB),0) + LIBS += -ltbb +endif + OBJDIRBASE := obj/$(BUILD) OBJDIR := $(OBJDIRBASE)/o/o/o diff --git a/profiler/build/unix/build.mk b/profiler/build/unix/build.mk index 78d8d660..e2a26fad 100644 --- a/profiler/build/unix/build.mk +++ b/profiler/build/unix/build.mk @@ -25,6 +25,11 @@ else LIBS += $(shell pkg-config --libs gtk+-2.0) -lGL endif +TBB := $(shell ld -ltbb -o /dev/null 2>/dev/null; echo $$?) +ifeq ($(TBB),0) + LIBS += -ltbb +endif + OBJDIRBASE := obj/$(BUILD) OBJDIR := $(OBJDIRBASE)/o/o/o diff --git a/update/build/unix/build.mk b/update/build/unix/build.mk index b51f18dc..cf8db4ca 100644 --- a/update/build/unix/build.mk +++ b/update/build/unix/build.mk @@ -14,6 +14,11 @@ BASE2 := $(shell egrep 'ClCompile.*c"' ../win32/$(PROJECT).vcxproj | sed -e 's/. SRC := $(filter-out $(FILTER),$(BASE)) SRC2 := $(filter-out $(FILTER),$(BASE2)) +TBB := $(shell ld -ltbb -o /dev/null 2>/dev/null; echo $$?) +ifeq ($(TBB),0) + LIBS += -ltbb +endif + OBJDIRBASE := obj/$(BUILD) OBJDIR := $(OBJDIRBASE)/o/o/o