aboutsummaryrefslogtreecommitdiffhomepage
path: root/Makefile
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2015-08-05 07:23:48 -0700
committerGravatar Craig Tiller <ctiller@google.com>2015-08-05 07:23:48 -0700
commit60287b636375cf7ff6ff896b24deaa9c39884e53 (patch)
tree7d132aa770e85a7b0628d1d4b1307c9e8f925857 /Makefile
parent80aecf609b54aeb0677461cae771362b5affe173 (diff)
Revert "Fixing environments where pkg-config isn't installed."
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile62
1 files changed, 21 insertions, 41 deletions
diff --git a/Makefile b/Makefile
index 4ba0c0ffcf..d9ede7a6e6 100644
--- a/Makefile
+++ b/Makefile
@@ -268,21 +268,34 @@ INCLUDES = . include $(GENDIR)
LDFLAGS += -Llibs/$(CONFIG)
ifeq ($(SYSTEM),Darwin)
-LIBS += m
+ifneq ($(wildcard /usr/local/ssl/include),)
+INCLUDES += /usr/local/ssl/include
+endif
+ifneq ($(wildcard /opt/local/include),)
+INCLUDES += /opt/local/include
+endif
+ifneq ($(wildcard /usr/local/include),)
+INCLUDES += /usr/local/include
+endif
+LIBS = m z
+ifneq ($(wildcard /usr/local/ssl/lib),)
+LDFLAGS += -L/usr/local/ssl/lib
+endif
+ifneq ($(wildcard /opt/local/lib),)
+LDFLAGS += -L/opt/local/lib
+endif
+ifneq ($(wildcard /usr/local/lib),)
+LDFLAGS += -L/usr/local/lib
+endif
endif
ifeq ($(SYSTEM),Linux)
-LIBS += rt m pthread
+LIBS = rt m z pthread
LDFLAGS += -pthread
endif
ifeq ($(SYSTEM),MINGW32)
-LIBS += m pthread
-LDFLAGS += -pthread
-endif
-
-ifeq ($(SYSTEM),FreeBSD)
-LIBS += pthread
+LIBS = m z pthread
LDFLAGS += -pthread
endif
@@ -374,39 +387,6 @@ ZLIB_CHECK_CMD = $(PKG_CONFIG) --exists zlib
PROTOBUF_CHECK_CMD = $(PKG_CONFIG) --atleast-version=3.0.0-alpha-3 protobuf
else # HAS_PKG_CONFIG
-ifeq ($(SYSTEM),Darwin)
-ifneq ($(wildcard /usr/local/ssl/include),)
-INCLUDES += /usr/local/ssl/include
-endif
-ifneq ($(wildcard /opt/local/include),)
-INCLUDES += /opt/local/include
-endif
-ifneq ($(wildcard /usr/local/include),)
-INCLUDES += /usr/local/include
-endif
-ifneq ($(wildcard /usr/local/ssl/lib),)
-LDFLAGS += -L/usr/local/ssl/lib
-endif
-ifneq ($(wildcard /opt/local/lib),)
-LDFLAGS += -L/opt/local/lib
-endif
-ifneq ($(wildcard /usr/local/lib),)
-LDFLAGS += -L/usr/local/lib
-endif
-endif
-
-ifeq ($(SYSTEM),Linux)
-LIBS += z
-endif
-
-ifeq ($(SYSTEM),MINGW32)
-LIBS += z
-endif
-
-ifeq ($(SYSTEM),FreeBSD)
-LIBS += z
-endif
-
ifeq ($(SYSTEM),MINGW32)
OPENSSL_LIBS = ssl32 eay32
else