From 9b07311c7c0ca0f34f3fea54df478ea6d15dd827 Mon Sep 17 00:00:00 2001 From: Joshua Haberman Date: Tue, 14 May 2019 11:12:13 -0700 Subject: [PATCH] More Blaze fixes. --- BUILD | 15 +++++++++++---- CMakeLists.txt | 6 ++++++ 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/BUILD b/BUILD index 6e624238eb..2197d2c44f 100644 --- a/BUILD +++ b/BUILD @@ -87,6 +87,7 @@ cc_library( visibility = ["//visibility:public"], deps = [ ":descriptor_upbproto", + ":table", ":upb", ], ) @@ -150,6 +151,7 @@ cc_library( ], copts = COPTS, deps = [ + ":descriptor_upbproto", ":handlers", ":table", ":upb", @@ -180,7 +182,11 @@ cc_library( hdrs = [ "upb/bindings/stdc++/string.h", ], - deps = [":upb"], + deps = [ + ":descriptor_upbproto", + ":handlers", + ":upb", + ], ) # upb compiler ################################################################# @@ -229,6 +235,7 @@ cc_library( "tests/upb_test.h", ], copts = CPPOPTS, + deps = [":handlers"], ) cc_test( @@ -359,18 +366,19 @@ cc_test( upb_proto_library( name = "conformance_proto_upb", - deps = ["@com_google_protobuf//:conformance_proto"], testonly = 1, + deps = ["@com_google_protobuf//:conformance_proto"], ) upb_proto_library( name = "test_messages_proto3_proto_upb", - deps = ["@com_google_protobuf//:test_messages_proto3_proto"], testonly = 1, + deps = ["@com_google_protobuf//:test_messages_proto3_proto"], ) cc_binary( name = "conformance_upb", + testonly = 1, srcs = [ "tests/conformance_upb.c", ], @@ -380,7 +388,6 @@ cc_binary( ":test_messages_proto3_proto_upb", ":upb", ], - testonly = 1, ) make_shell_script( diff --git a/CMakeLists.txt b/CMakeLists.txt index d085f48600..1ff4788080 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -79,6 +79,7 @@ add_library(reflection upb/msgfactory.h) target_link_libraries(reflection descriptor_upbproto + table upb) add_library(table INTERFACE) target_link_libraries(table INTERFACE @@ -110,6 +111,7 @@ add_library(upb_pb upb/pb/encoder.h upb/pb/textprinter.h) target_link_libraries(upb_pb + descriptor_upbproto handlers table upb) @@ -123,10 +125,14 @@ target_link_libraries(upb_json upb_pb) add_library(upb_cc_bindings INTERFACE) target_link_libraries(upb_cc_bindings INTERFACE + descriptor_upbproto + handlers upb) add_library(upb_test tests/testmain.cc tests/test_util.h tests/upb_test.h) +target_link_libraries(upb_test + handlers)