Skip to content
Snippets Groups Projects
Commit 228ad9b8 authored by ctiller's avatar ctiller Committed by Tim Emiola
Browse files

Fix opensource build.

	Change on 2015/01/07 by ctiller <ctiller@google.com>
-------------
Created by MOE: http://code.google.com/p/moe-java
MOE_MIGRATED_REVID=83469328
parent f6db7b27
No related branches found
No related tags found
No related merge requests found
...@@ -84,7 +84,7 @@ CPPFLAGS += -g -fPIC -Wall -Werror -Wno-long-long ...@@ -84,7 +84,7 @@ CPPFLAGS += -g -fPIC -Wall -Werror -Wno-long-long
LDFLAGS += -g -pthread -fPIC LDFLAGS += -g -pthread -fPIC
   
INCLUDES = . include gens INCLUDES = . include gens
LIBS = rt m z event event_pthreads pthread LIBS = rt m z pthread
LIBSXX = protobuf LIBSXX = protobuf
LIBS_PROTOC = protoc protobuf LIBS_PROTOC = protoc protobuf
   
...@@ -143,20 +143,12 @@ else ...@@ -143,20 +143,12 @@ else
IS_GIT_FOLDER = true IS_GIT_FOLDER = true
endif endif
   
EVENT2_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/event2.c -levent $(LDFLAGS)
OPENSSL_ALPN_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/openssl-alpn.c -lssl -lcrypto -ldl $(LDFLAGS) OPENSSL_ALPN_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/openssl-alpn.c -lssl -lcrypto -ldl $(LDFLAGS)
ZLIB_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/zlib.c -lz $(LDFLAGS) ZLIB_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/zlib.c -lz $(LDFLAGS)
   
HAS_SYSTEM_EVENT2 = $(shell $(EVENT2_CHECK_CMD) 2> /dev/null && echo true || echo false)
HAS_SYSTEM_OPENSSL_ALPN = $(shell $(OPENSSL_ALPN_CHECK_CMD) 2> /dev/null && echo true || echo false) HAS_SYSTEM_OPENSSL_ALPN = $(shell $(OPENSSL_ALPN_CHECK_CMD) 2> /dev/null && echo true || echo false)
HAS_SYSTEM_ZLIB = $(shell $(ZLIB_CHECK_CMD) 2> /dev/null && echo true || echo false) HAS_SYSTEM_ZLIB = $(shell $(ZLIB_CHECK_CMD) 2> /dev/null && echo true || echo false)
   
ifeq ($(wildcard third_party/libevent/include/event2/event.h),)
HAS_EMBEDDED_EVENT2 = false
else
HAS_EMBEDDED_EVENT2 = true
endif
ifeq ($(wildcard third_party/openssl/ssl/ssl.h),) ifeq ($(wildcard third_party/openssl/ssl/ssl.h),)
HAS_EMBEDDED_OPENSSL_ALPN = false HAS_EMBEDDED_OPENSSL_ALPN = false
else else
...@@ -169,12 +161,6 @@ else ...@@ -169,12 +161,6 @@ else
HAS_EMBEDDED_ZLIB = true HAS_EMBEDDED_ZLIB = true
endif endif
   
ifneq ($(SYSTEM),MINGW32)
ifeq ($(HAS_SYSTEM_EVENT2),false)
DEP_MISSING += libevent
endif
endif
ifeq ($(HAS_SYSTEM_ZLIB),false) ifeq ($(HAS_SYSTEM_ZLIB),false)
ifeq ($(HAS_EMBEDDED_ZLIB),true) ifeq ($(HAS_EMBEDDED_ZLIB),true)
ZLIB_DEP = third_party/zlib/libz.a ZLIB_DEP = third_party/zlib/libz.a
...@@ -466,7 +452,6 @@ chttp2_socket_pair_one_byte_at_a_time_thread_stress_test: bins/$(CONFIG)/chttp2_ ...@@ -466,7 +452,6 @@ chttp2_socket_pair_one_byte_at_a_time_thread_stress_test: bins/$(CONFIG)/chttp2_
chttp2_socket_pair_one_byte_at_a_time_writes_done_hangs_with_pending_read_test: bins/$(CONFIG)/chttp2_socket_pair_one_byte_at_a_time_writes_done_hangs_with_pending_read_test chttp2_socket_pair_one_byte_at_a_time_writes_done_hangs_with_pending_read_test: bins/$(CONFIG)/chttp2_socket_pair_one_byte_at_a_time_writes_done_hangs_with_pending_read_test
   
run_dep_checks: run_dep_checks:
$(EVENT2_CHECK_CMD) || true
$(OPENSSL_ALPN_CHECK_CMD) || true $(OPENSSL_ALPN_CHECK_CMD) || true
$(ZLIB_CHECK_CMD) || true $(ZLIB_CHECK_CMD) || true
   
......
...@@ -100,7 +100,7 @@ CPPFLAGS += -g -fPIC -Wall -Werror -Wno-long-long ...@@ -100,7 +100,7 @@ CPPFLAGS += -g -fPIC -Wall -Werror -Wno-long-long
LDFLAGS += -g -pthread -fPIC LDFLAGS += -g -pthread -fPIC
INCLUDES = . include gens INCLUDES = . include gens
LIBS = rt m z event event_pthreads pthread LIBS = rt m z pthread
LIBSXX = protobuf LIBSXX = protobuf
LIBS_PROTOC = protoc protobuf LIBS_PROTOC = protoc protobuf
...@@ -159,20 +159,12 @@ else ...@@ -159,20 +159,12 @@ else
IS_GIT_FOLDER = true IS_GIT_FOLDER = true
endif endif
EVENT2_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/event2.c -levent $(LDFLAGS)
OPENSSL_ALPN_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/openssl-alpn.c -lssl -lcrypto -ldl $(LDFLAGS) OPENSSL_ALPN_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/openssl-alpn.c -lssl -lcrypto -ldl $(LDFLAGS)
ZLIB_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/zlib.c -lz $(LDFLAGS) ZLIB_CHECK_CMD = $(CC) $(CFLAGS) $(CPPFLAGS) -o /dev/null test/build/zlib.c -lz $(LDFLAGS)
HAS_SYSTEM_EVENT2 = $(shell $(EVENT2_CHECK_CMD) 2> /dev/null && echo true || echo false)
HAS_SYSTEM_OPENSSL_ALPN = $(shell $(OPENSSL_ALPN_CHECK_CMD) 2> /dev/null && echo true || echo false) HAS_SYSTEM_OPENSSL_ALPN = $(shell $(OPENSSL_ALPN_CHECK_CMD) 2> /dev/null && echo true || echo false)
HAS_SYSTEM_ZLIB = $(shell $(ZLIB_CHECK_CMD) 2> /dev/null && echo true || echo false) HAS_SYSTEM_ZLIB = $(shell $(ZLIB_CHECK_CMD) 2> /dev/null && echo true || echo false)
ifeq ($(wildcard third_party/libevent/include/event2/event.h),)
HAS_EMBEDDED_EVENT2 = false
else
HAS_EMBEDDED_EVENT2 = true
endif
ifeq ($(wildcard third_party/openssl/ssl/ssl.h),) ifeq ($(wildcard third_party/openssl/ssl/ssl.h),)
HAS_EMBEDDED_OPENSSL_ALPN = false HAS_EMBEDDED_OPENSSL_ALPN = false
else else
...@@ -185,12 +177,6 @@ else ...@@ -185,12 +177,6 @@ else
HAS_EMBEDDED_ZLIB = true HAS_EMBEDDED_ZLIB = true
endif endif
ifneq ($(SYSTEM),MINGW32)
ifeq ($(HAS_SYSTEM_EVENT2),false)
DEP_MISSING += libevent
endif
endif
ifeq ($(HAS_SYSTEM_ZLIB),false) ifeq ($(HAS_SYSTEM_ZLIB),false)
ifeq ($(HAS_EMBEDDED_ZLIB),true) ifeq ($(HAS_EMBEDDED_ZLIB),true)
ZLIB_DEP = third_party/zlib/libz.a ZLIB_DEP = third_party/zlib/libz.a
...@@ -291,7 +277,6 @@ ${tgt.name}: bins/$(CONFIG)/${tgt.name} ...@@ -291,7 +277,6 @@ ${tgt.name}: bins/$(CONFIG)/${tgt.name}
% endfor % endfor
run_dep_checks: run_dep_checks:
$(EVENT2_CHECK_CMD) || true
$(OPENSSL_ALPN_CHECK_CMD) || true $(OPENSSL_ALPN_CHECK_CMD) || true
$(ZLIB_CHECK_CMD) || true $(ZLIB_CHECK_CMD) || true
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment