summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorDavid M. Syzdek <david.syzdek@acsalaska.net>2008-11-02 23:43:20 (GMT)
committerJunio C Hamano <gitster@pobox.com>2008-11-03 00:41:41 (GMT)
commit158629b2c9baffd0352306bd8dfa0784c981955d (patch)
treeebda7b05cd7c8cc5853ffb82c6fa8dfd363ede92 /Makefile
parent069bb5765c04645313d79a1eb345a4fb8fe7f06c (diff)
downloadgit-158629b2c9baffd0352306bd8dfa0784c981955d.zip
git-158629b2c9baffd0352306bd8dfa0784c981955d.tar.gz
git-158629b2c9baffd0352306bd8dfa0784c981955d.tar.bz2
Make Pthread link flags configurable
FreeBSD 4.x systems use the linker flags `-pthread' instead of the linker flags `-lpthread' when linking against the pthread library. Signed-off-by: David M. Syzdek <david.syzdek@acsalaska.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 3 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 426e1a6..02f68e0 100644
--- a/Makefile
+++ b/Makefile
@@ -229,6 +229,7 @@ INSTALL = install
RPMBUILD = rpmbuild
TCL_PATH = tclsh
TCLTK_PATH = wish
+PTHREAD_LIBS = -lpthread
export TCL_PATH TCLTK_PATH
@@ -695,6 +696,7 @@ ifeq ($(uname_S),FreeBSD)
COMPAT_CFLAGS += -Icompat/regex
COMPAT_OBJS += compat/regex/regex.o
ifeq ($(shell expr "$(uname_R)" : '4\.'),2)
+ PTHREAD_LIBS = -pthread
NO_UINTMAX_T = YesPlease
NO_STRTOUMAX = YesPlease
endif
@@ -1023,7 +1025,7 @@ endif
ifdef THREADED_DELTA_SEARCH
BASIC_CFLAGS += -DTHREADED_DELTA_SEARCH
- EXTLIBS += -lpthread
+ EXTLIBS += $(PTHREAD_LIBS)
LIB_OBJS += thread-utils.o
endif
ifdef DIR_HAS_BSD_GROUP_SEMANTICS