[PATCH] libtracefs: allow pthread inclusion overrideable in Makefile

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



clang fails if you attempt to inclued -lpthread in the linking phase for
certain versions of clang (newer seems to be happier with it).  This
should allow for -lpthread to be overridden on the builds where it's
causing problems

Signed-off-by: John 'Warthog9' Hawley (VMware) <warthog9@xxxxxxxxxxxxxx>
---
 Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index aa659b4..1d25c14 100644
--- a/Makefile
+++ b/Makefile
@@ -132,7 +132,8 @@ LIBTRACEFS_SHARED_VERSION = $(bdir)/libtracefs.so.$(TFS_VERSION)
 PKG_CONFIG_SOURCE_FILE = libtracefs.pc
 PKG_CONFIG_FILE := $(addprefix $(obj)/,$(PKG_CONFIG_SOURCE_FILE))
 
-LIBS = $(LIBTRACEEVENT_LIBS) -lpthread
+LPTHREAD ?= -lpthread
+LIBS = $(LIBTRACEEVENT_LIBS) $(LPTHREAD)
 
 export LIBS
 export LIBTRACEFS_STATIC LIBTRACEFS_SHARED
-- 
2.37.2




[Index of Archives]     [Linux USB Development]     [Linux USB Development]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux