summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShawn Pearce <spearce@spearce.org>2006-02-28 14:03:48 (GMT)
committerJunio C Hamano <junkio@cox.net>2006-02-28 19:02:13 (GMT)
commite3601e8bb76e46745d4919c3f30b1dddae040eb2 (patch)
treefda2b0c067934649485625c5be364d135975a6ca
parentd82343b93860348215db0c7267bc051e5f80aefa (diff)
downloadgit-e3601e8bb76e46745d4919c3f30b1dddae040eb2.zip
git-e3601e8bb76e46745d4919c3f30b1dddae040eb2.tar.gz
git-e3601e8bb76e46745d4919c3f30b1dddae040eb2.tar.bz2
Darwin: Ignore missing /sw/lib
When on Darwin platforms don't include Fink or DarwinPorts into the link path unless the related library directory is actually present. The linker on MacOS 10.4 complains if it is given a directory which does not exist. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
-rw-r--r--Makefile12
1 files changed, 8 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index 6c59cee..19578fc 100644
--- a/Makefile
+++ b/Makefile
@@ -223,11 +223,15 @@ ifeq ($(uname_S),Darwin)
NEEDS_SSL_WITH_CRYPTO = YesPlease
NEEDS_LIBICONV = YesPlease
## fink
- ALL_CFLAGS += -I/sw/include
- ALL_LDFLAGS += -L/sw/lib
+ ifeq ($(shell test -d /sw/lib && echo y),y)
+ ALL_CFLAGS += -I/sw/include
+ ALL_LDFLAGS += -L/sw/lib
+ endif
## darwinports
- ALL_CFLAGS += -I/opt/local/include
- ALL_LDFLAGS += -L/opt/local/lib
+ ifeq ($(shell test -d /opt/local/lib && echo y),y)
+ ALL_CFLAGS += -I/opt/local/include
+ ALL_LDFLAGS += -L/opt/local/lib
+ endif
endif
ifeq ($(uname_S),SunOS)
NEEDS_SOCKET = YesPlease