diff --git a/Makefile b/Makefile index 5c618d30224..0046a53341e 100644 --- a/Makefile +++ b/Makefile @@ -2235,6 +2235,10 @@ $(OBJDIR)/$(CONFIG)/test/core/util/test_config.o: LIBGRPC_SRC = \ + src/core/httpcli/format_request.c \ + src/core/httpcli/httpcli.c \ + src/core/httpcli/httpcli_security_context.c \ + src/core/httpcli/parser.c \ src/core/security/auth.c \ src/core/security/base64.c \ src/core/security/credentials.c \ @@ -2244,6 +2248,8 @@ LIBGRPC_SRC = \ src/core/security/secure_transport_setup.c \ src/core/security/security_context.c \ src/core/security/server_secure_chttp2.c \ + src/core/surface/secure_channel_create.c \ + src/core/surface/secure_server_create.c \ src/core/tsi/fake_transport_security.c \ src/core/tsi/ssl_transport_security.c \ src/core/tsi/transport_security.c \ @@ -2263,10 +2269,6 @@ LIBGRPC_SRC = \ src/core/compression/algorithm.c \ src/core/compression/message_compress.c \ src/core/debug/trace.c \ - src/core/httpcli/format_request.c \ - src/core/httpcli/httpcli.c \ - src/core/httpcli/httpcli_security_context.c \ - src/core/httpcli/parser.c \ src/core/iomgr/alarm.c \ src/core/iomgr/alarm_heap.c \ src/core/iomgr/endpoint.c \ @@ -2321,8 +2323,6 @@ LIBGRPC_SRC = \ src/core/surface/init.c \ src/core/surface/lame_client.c \ src/core/surface/metadata_array.c \ - src/core/surface/secure_channel_create.c \ - src/core/surface/secure_server_create.c \ src/core/surface/server.c \ src/core/surface/server_chttp2.c \ src/core/surface/server_create.c \ @@ -2375,6 +2375,10 @@ ifneq ($(OPENSSL_DEP),) # This is to ensure the embedded OpenSSL is built beforehand, properly # installing headers to their final destination on the drive. We need this # otherwise parallel compilation will fail if a source is compiled first. +src/core/httpcli/format_request.c: $(OPENSSL_DEP) +src/core/httpcli/httpcli.c: $(OPENSSL_DEP) +src/core/httpcli/httpcli_security_context.c: $(OPENSSL_DEP) +src/core/httpcli/parser.c: $(OPENSSL_DEP) src/core/security/auth.c: $(OPENSSL_DEP) src/core/security/base64.c: $(OPENSSL_DEP) src/core/security/credentials.c: $(OPENSSL_DEP) @@ -2384,6 +2388,8 @@ src/core/security/secure_endpoint.c: $(OPENSSL_DEP) src/core/security/secure_transport_setup.c: $(OPENSSL_DEP) src/core/security/security_context.c: $(OPENSSL_DEP) src/core/security/server_secure_chttp2.c: $(OPENSSL_DEP) +src/core/surface/secure_channel_create.c: $(OPENSSL_DEP) +src/core/surface/secure_server_create.c: $(OPENSSL_DEP) src/core/tsi/fake_transport_security.c: $(OPENSSL_DEP) src/core/tsi/ssl_transport_security.c: $(OPENSSL_DEP) src/core/tsi/transport_security.c: $(OPENSSL_DEP) @@ -2403,10 +2409,6 @@ src/core/channel/noop_filter.c: $(OPENSSL_DEP) src/core/compression/algorithm.c: $(OPENSSL_DEP) src/core/compression/message_compress.c: $(OPENSSL_DEP) src/core/debug/trace.c: $(OPENSSL_DEP) -src/core/httpcli/format_request.c: $(OPENSSL_DEP) -src/core/httpcli/httpcli.c: $(OPENSSL_DEP) -src/core/httpcli/httpcli_security_context.c: $(OPENSSL_DEP) -src/core/httpcli/parser.c: $(OPENSSL_DEP) src/core/iomgr/alarm.c: $(OPENSSL_DEP) src/core/iomgr/alarm_heap.c: $(OPENSSL_DEP) src/core/iomgr/endpoint.c: $(OPENSSL_DEP) @@ -2461,8 +2463,6 @@ src/core/surface/event_string.c: $(OPENSSL_DEP) src/core/surface/init.c: $(OPENSSL_DEP) src/core/surface/lame_client.c: $(OPENSSL_DEP) src/core/surface/metadata_array.c: $(OPENSSL_DEP) -src/core/surface/secure_channel_create.c: $(OPENSSL_DEP) -src/core/surface/secure_server_create.c: $(OPENSSL_DEP) src/core/surface/server.c: $(OPENSSL_DEP) src/core/surface/server_chttp2.c: $(OPENSSL_DEP) src/core/surface/server_create.c: $(OPENSSL_DEP) @@ -2532,6 +2532,10 @@ ifneq ($(NO_DEPS),true) endif endif +$(OBJDIR)/$(CONFIG)/src/core/httpcli/format_request.o: +$(OBJDIR)/$(CONFIG)/src/core/httpcli/httpcli.o: +$(OBJDIR)/$(CONFIG)/src/core/httpcli/httpcli_security_context.o: +$(OBJDIR)/$(CONFIG)/src/core/httpcli/parser.o: $(OBJDIR)/$(CONFIG)/src/core/security/auth.o: $(OBJDIR)/$(CONFIG)/src/core/security/base64.o: $(OBJDIR)/$(CONFIG)/src/core/security/credentials.o: @@ -2541,6 +2545,8 @@ $(OBJDIR)/$(CONFIG)/src/core/security/secure_endpoint.o: $(OBJDIR)/$(CONFIG)/src/core/security/secure_transport_setup.o: $(OBJDIR)/$(CONFIG)/src/core/security/security_context.o: $(OBJDIR)/$(CONFIG)/src/core/security/server_secure_chttp2.o: +$(OBJDIR)/$(CONFIG)/src/core/surface/secure_channel_create.o: +$(OBJDIR)/$(CONFIG)/src/core/surface/secure_server_create.o: $(OBJDIR)/$(CONFIG)/src/core/tsi/fake_transport_security.o: $(OBJDIR)/$(CONFIG)/src/core/tsi/ssl_transport_security.o: $(OBJDIR)/$(CONFIG)/src/core/tsi/transport_security.o: @@ -2560,10 +2566,6 @@ $(OBJDIR)/$(CONFIG)/src/core/channel/noop_filter.o: $(OBJDIR)/$(CONFIG)/src/core/compression/algorithm.o: $(OBJDIR)/$(CONFIG)/src/core/compression/message_compress.o: $(OBJDIR)/$(CONFIG)/src/core/debug/trace.o: -$(OBJDIR)/$(CONFIG)/src/core/httpcli/format_request.o: -$(OBJDIR)/$(CONFIG)/src/core/httpcli/httpcli.o: -$(OBJDIR)/$(CONFIG)/src/core/httpcli/httpcli_security_context.o: -$(OBJDIR)/$(CONFIG)/src/core/httpcli/parser.o: $(OBJDIR)/$(CONFIG)/src/core/iomgr/alarm.o: $(OBJDIR)/$(CONFIG)/src/core/iomgr/alarm_heap.o: $(OBJDIR)/$(CONFIG)/src/core/iomgr/endpoint.o: @@ -2618,8 +2620,6 @@ $(OBJDIR)/$(CONFIG)/src/core/surface/event_string.o: $(OBJDIR)/$(CONFIG)/src/core/surface/init.o: $(OBJDIR)/$(CONFIG)/src/core/surface/lame_client.o: $(OBJDIR)/$(CONFIG)/src/core/surface/metadata_array.o: -$(OBJDIR)/$(CONFIG)/src/core/surface/secure_channel_create.o: -$(OBJDIR)/$(CONFIG)/src/core/surface/secure_server_create.o: $(OBJDIR)/$(CONFIG)/src/core/surface/server.o: $(OBJDIR)/$(CONFIG)/src/core/surface/server_chttp2.o: $(OBJDIR)/$(CONFIG)/src/core/surface/server_create.o: @@ -2738,10 +2738,6 @@ LIBGRPC_UNSECURE_SRC = \ src/core/compression/algorithm.c \ src/core/compression/message_compress.c \ src/core/debug/trace.c \ - src/core/httpcli/format_request.c \ - src/core/httpcli/httpcli.c \ - src/core/httpcli/httpcli_security_context.c \ - src/core/httpcli/parser.c \ src/core/iomgr/alarm.c \ src/core/iomgr/alarm_heap.c \ src/core/iomgr/endpoint.c \ @@ -2796,8 +2792,6 @@ LIBGRPC_UNSECURE_SRC = \ src/core/surface/init.c \ src/core/surface/lame_client.c \ src/core/surface/metadata_array.c \ - src/core/surface/secure_channel_create.c \ - src/core/surface/secure_server_create.c \ src/core/surface/server.c \ src/core/surface/server_chttp2.c \ src/core/surface/server_create.c \ @@ -2879,10 +2873,6 @@ $(OBJDIR)/$(CONFIG)/src/core/channel/noop_filter.o: $(OBJDIR)/$(CONFIG)/src/core/compression/algorithm.o: $(OBJDIR)/$(CONFIG)/src/core/compression/message_compress.o: $(OBJDIR)/$(CONFIG)/src/core/debug/trace.o: -$(OBJDIR)/$(CONFIG)/src/core/httpcli/format_request.o: -$(OBJDIR)/$(CONFIG)/src/core/httpcli/httpcli.o: -$(OBJDIR)/$(CONFIG)/src/core/httpcli/httpcli_security_context.o: -$(OBJDIR)/$(CONFIG)/src/core/httpcli/parser.o: $(OBJDIR)/$(CONFIG)/src/core/iomgr/alarm.o: $(OBJDIR)/$(CONFIG)/src/core/iomgr/alarm_heap.o: $(OBJDIR)/$(CONFIG)/src/core/iomgr/endpoint.o: @@ -2937,8 +2927,6 @@ $(OBJDIR)/$(CONFIG)/src/core/surface/event_string.o: $(OBJDIR)/$(CONFIG)/src/core/surface/init.o: $(OBJDIR)/$(CONFIG)/src/core/surface/lame_client.o: $(OBJDIR)/$(CONFIG)/src/core/surface/metadata_array.o: -$(OBJDIR)/$(CONFIG)/src/core/surface/secure_channel_create.o: -$(OBJDIR)/$(CONFIG)/src/core/surface/secure_server_create.o: $(OBJDIR)/$(CONFIG)/src/core/surface/server.o: $(OBJDIR)/$(CONFIG)/src/core/surface/server_chttp2.o: $(OBJDIR)/$(CONFIG)/src/core/surface/server_create.o: @@ -3074,18 +3062,18 @@ endif ifeq ($(SYSTEM),MINGW32) -$(LIBDIR)/$(CONFIG)/grpc++.$(SHARED_EXT): $(LIBGRPC++_OBJS) $(ZLIB_DEP)$(LIBDIR)/$(CONFIG)/grpc.$(SHARED_EXT) $(OPENSSL_DEP) +$(LIBDIR)/$(CONFIG)/grpc++.$(SHARED_EXT): $(LIBGRPC++_OBJS) $(ZLIB_DEP)$(LIBDIR)/$(CONFIG)/gpr.$(SHARED_EXT)$(LIBDIR)/$(CONFIG)/grpc.$(SHARED_EXT) $(OPENSSL_DEP) $(E) "[LD] Linking $@" $(Q) mkdir -p `dirname $@` - $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,--output-def=$(LIBDIR)/$(CONFIG)/grpc++.def -Wl,--out-implib=$(LIBDIR)/$(CONFIG)/libgrpc++-imp.a -o $(LIBDIR)/$(CONFIG)/grpc++.$(SHARED_EXT) $(LIBGRPC++_OBJS) $(LDLIBS) $(LDLIBS_SECURE) $(OPENSSL_MERGE_LIBS) -lgrpc-imp + $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,--output-def=$(LIBDIR)/$(CONFIG)/grpc++.def -Wl,--out-implib=$(LIBDIR)/$(CONFIG)/libgrpc++-imp.a -o $(LIBDIR)/$(CONFIG)/grpc++.$(SHARED_EXT) $(LIBGRPC++_OBJS) $(LDLIBS) $(LDLIBS_SECURE) $(OPENSSL_MERGE_LIBS) $(LDLIBSXX) $(LDLIBS_PROTOBUF) -lgpr-imp -lgrpc-imp else -$(LIBDIR)/$(CONFIG)/libgrpc++.$(SHARED_EXT): $(LIBGRPC++_OBJS) $(ZLIB_DEP) $(LIBDIR)/$(CONFIG)/libgrpc.$(SHARED_EXT) $(OPENSSL_DEP) +$(LIBDIR)/$(CONFIG)/libgrpc++.$(SHARED_EXT): $(LIBGRPC++_OBJS) $(ZLIB_DEP) $(LIBDIR)/$(CONFIG)/libgpr.$(SHARED_EXT) $(LIBDIR)/$(CONFIG)/libgrpc.$(SHARED_EXT) $(OPENSSL_DEP) $(E) "[LD] Linking $@" $(Q) mkdir -p `dirname $@` ifeq ($(SYSTEM),Darwin) - $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -dynamiclib -o $(LIBDIR)/$(CONFIG)/libgrpc++.$(SHARED_EXT) $(LIBGRPC++_OBJS) $(LDLIBS) $(LDLIBS_SECURE) $(OPENSSL_MERGE_LIBS) -lgrpc + $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -dynamiclib -o $(LIBDIR)/$(CONFIG)/libgrpc++.$(SHARED_EXT) $(LIBGRPC++_OBJS) $(LDLIBS) $(LDLIBS_SECURE) $(OPENSSL_MERGE_LIBS) $(LDLIBSXX) $(LDLIBS_PROTOBUF) -lgpr -lgrpc else - $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgrpc++.so.0 -o $(LIBDIR)/$(CONFIG)/libgrpc++.$(SHARED_EXT) $(LIBGRPC++_OBJS) $(LDLIBS) $(LDLIBS_SECURE) $(OPENSSL_MERGE_LIBS) -lgrpc + $(Q) $(LDXX) $(LDFLAGS) -L$(LIBDIR)/$(CONFIG) -shared -Wl,-soname,libgrpc++.so.0 -o $(LIBDIR)/$(CONFIG)/libgrpc++.$(SHARED_EXT) $(LIBGRPC++_OBJS) $(LDLIBS) $(LDLIBS_SECURE) $(OPENSSL_MERGE_LIBS) $(LDLIBSXX) $(LDLIBS_PROTOBUF) -lgpr -lgrpc $(Q) ln -sf libgrpc++.$(SHARED_EXT) $(LIBDIR)/$(CONFIG)/libgrpc++.so.0 $(Q) ln -sf libgrpc++.$(SHARED_EXT) $(LIBDIR)/$(CONFIG)/libgrpc++.so endif diff --git a/build.json b/build.json index 172753ba4ac..411391efab6 100644 --- a/build.json +++ b/build.json @@ -33,10 +33,6 @@ "src/core/compression/algorithm.h", "src/core/compression/message_compress.h", "src/core/debug/trace.h", - "src/core/httpcli/format_request.h", - "src/core/httpcli/httpcli.h", - "src/core/httpcli/httpcli_security_context.h", - "src/core/httpcli/parser.h", "src/core/iomgr/alarm.h", "src/core/iomgr/alarm_heap.h", "src/core/iomgr/alarm_internal.h", @@ -126,10 +122,6 @@ "src/core/compression/algorithm.c", "src/core/compression/message_compress.c", "src/core/debug/trace.c", - "src/core/httpcli/format_request.c", - "src/core/httpcli/httpcli.c", - "src/core/httpcli/httpcli_security_context.c", - "src/core/httpcli/parser.c", "src/core/iomgr/alarm.c", "src/core/iomgr/alarm_heap.c", "src/core/iomgr/endpoint.c", @@ -184,8 +176,6 @@ "src/core/surface/init.c", "src/core/surface/lame_client.c", "src/core/surface/metadata_array.c", - "src/core/surface/secure_channel_create.c", - "src/core/surface/secure_server_create.c", "src/core/surface/server.c", "src/core/surface/server_chttp2.c", "src/core/surface/server_create.c", @@ -306,6 +296,10 @@ "include/grpc/grpc_security.h" ], "headers": [ + "src/core/httpcli/format_request.h", + "src/core/httpcli/httpcli.h", + "src/core/httpcli/httpcli_security_context.h", + "src/core/httpcli/parser.h", "src/core/security/auth.h", "src/core/security/base64.h", "src/core/security/credentials.h", @@ -318,6 +312,10 @@ "src/core/tsi/transport_security_interface.h" ], "src": [ + "src/core/httpcli/format_request.c", + "src/core/httpcli/httpcli.c", + "src/core/httpcli/httpcli_security_context.c", + "src/core/httpcli/parser.c", "src/core/security/auth.c", "src/core/security/base64.c", "src/core/security/credentials.c", @@ -327,6 +325,8 @@ "src/core/security/secure_transport_setup.c", "src/core/security/security_context.c", "src/core/security/server_secure_chttp2.c", + "src/core/surface/secure_channel_create.c", + "src/core/surface/secure_server_create.c", "src/core/tsi/fake_transport_security.c", "src/core/tsi/ssl_transport_security.c", "src/core/tsi/transport_security.c" @@ -433,6 +433,7 @@ "src/cpp/util/time.cc" ], "deps": [ + "gpr", "grpc" ], "secure": true, diff --git a/templates/Makefile.template b/templates/Makefile.template index 3cc1a951926..85da0dd8927 100644 --- a/templates/Makefile.template +++ b/templates/Makefile.template @@ -971,6 +971,9 @@ endif common = common + ' $(LDLIBS_SECURE) $(OPENSSL_MERGE_LIBS)' lib_deps = lib_deps + ' $(OPENSSL_DEP)' mingw_lib_deps = mingw_lib_deps + ' $(OPENSSL_DEP)' + + if lib.language == 'c++': + common = common + ' $(LDLIBSXX) $(LDLIBS_PROTOBUF)' %> % if lib.build == "all": diff --git a/vsprojects/vs2013/grpc.vcxproj b/vsprojects/vs2013/grpc.vcxproj index a7ecf5e5bfd..b55c7f926ba 100644 --- a/vsprojects/vs2013/grpc.vcxproj +++ b/vsprojects/vs2013/grpc.vcxproj @@ -85,6 +85,10 @@ + + + + @@ -110,10 +114,6 @@ - - - - @@ -187,6 +187,14 @@ + + + + + + + + @@ -205,6 +213,10 @@ + + + + @@ -243,14 +255,6 @@ - - - - - - - - @@ -359,10 +363,6 @@ - - - - diff --git a/vsprojects/vs2013/grpc.vcxproj.filters b/vsprojects/vs2013/grpc.vcxproj.filters index 8626604551c..9505c37ef4e 100644 --- a/vsprojects/vs2013/grpc.vcxproj.filters +++ b/vsprojects/vs2013/grpc.vcxproj.filters @@ -1,6 +1,18 @@ + + src\core\httpcli + + + src\core\httpcli + + + src\core\httpcli + + + src\core\httpcli + src\core\security @@ -28,6 +40,12 @@ src\core\security + + src\core\surface + + + src\core\surface + src\core\tsi @@ -85,18 +103,6 @@ src\core\debug - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - src\core\iomgr @@ -259,12 +265,6 @@ src\core\surface - - src\core\surface - - - src\core\surface - src\core\surface @@ -353,6 +353,18 @@ + + src\core\httpcli + + + src\core\httpcli + + + src\core\httpcli + + + src\core\httpcli + src\core\security @@ -428,18 +440,6 @@ src\core\debug - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - src\core\iomgr diff --git a/vsprojects/vs2013/grpc_shared.vcxproj b/vsprojects/vs2013/grpc_shared.vcxproj index d53abeb6d46..dfb08991380 100644 --- a/vsprojects/vs2013/grpc_shared.vcxproj +++ b/vsprojects/vs2013/grpc_shared.vcxproj @@ -89,6 +89,10 @@ + + + + @@ -114,10 +118,6 @@ - - - - @@ -191,6 +191,14 @@ + + + + + + + + @@ -209,6 +217,10 @@ + + + + @@ -247,14 +259,6 @@ - - - - - - - - @@ -363,10 +367,6 @@ - - - - diff --git a/vsprojects/vs2013/grpc_shared.vcxproj.filters b/vsprojects/vs2013/grpc_shared.vcxproj.filters index 8626604551c..9505c37ef4e 100644 --- a/vsprojects/vs2013/grpc_shared.vcxproj.filters +++ b/vsprojects/vs2013/grpc_shared.vcxproj.filters @@ -1,6 +1,18 @@ + + src\core\httpcli + + + src\core\httpcli + + + src\core\httpcli + + + src\core\httpcli + src\core\security @@ -28,6 +40,12 @@ src\core\security + + src\core\surface + + + src\core\surface + src\core\tsi @@ -85,18 +103,6 @@ src\core\debug - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - src\core\iomgr @@ -259,12 +265,6 @@ src\core\surface - - src\core\surface - - - src\core\surface - src\core\surface @@ -353,6 +353,18 @@ + + src\core\httpcli + + + src\core\httpcli + + + src\core\httpcli + + + src\core\httpcli + src\core\security @@ -428,18 +440,6 @@ src\core\debug - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - src\core\iomgr diff --git a/vsprojects/vs2013/grpc_unsecure.vcxproj b/vsprojects/vs2013/grpc_unsecure.vcxproj index e8d0a799575..74fc6c96ece 100644 --- a/vsprojects/vs2013/grpc_unsecure.vcxproj +++ b/vsprojects/vs2013/grpc_unsecure.vcxproj @@ -99,10 +99,6 @@ - - - - @@ -208,14 +204,6 @@ - - - - - - - - @@ -324,10 +312,6 @@ - - - - diff --git a/vsprojects/vs2013/grpc_unsecure.vcxproj.filters b/vsprojects/vs2013/grpc_unsecure.vcxproj.filters index ef82e34a62a..ea34d210bfe 100644 --- a/vsprojects/vs2013/grpc_unsecure.vcxproj.filters +++ b/vsprojects/vs2013/grpc_unsecure.vcxproj.filters @@ -49,18 +49,6 @@ src\core\debug - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - src\core\iomgr @@ -223,12 +211,6 @@ src\core\surface - - src\core\surface - - - src\core\surface - src\core\surface @@ -359,18 +341,6 @@ src\core\debug - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - - - src\core\httpcli - src\core\iomgr @@ -608,9 +578,6 @@ {6d8d5774-7291-554d-fafa-583463cd3fd9} - - {1ba3a245-47e7-89b5-b0c9-aca758bd0277} - {a9df8b24-ecea-ff6d-8999-d8fa54cd70bf}