Remove protobuf lite for java.
Since the introduction of nano protobufs for Java in https://codereview.chromium.org/532303003 (and updated in https://codereview.chromium.org/549543002), there is no need for the lite protocol buffers anymore. This CL removes the checked out files initially introduced when protobuf lite support for Java was added in https://chromiumcodereview.appspot.com/11347026 and cleans up the infrastructure regarding generating protocol buffers. Since lite is not supported anymore, this also removes the requirement for setting the 'proto_runtime' variable for targets using build/protoc_java.gypi. BUG=377891 TBR=zea@chromium.org Review URL: https://codereview.chromium.org/556933002 Cr-Commit-Position: refs/heads/master@{#294453}
This commit is contained in:
build
third_party
cacheinvalidation
protobuf
README.chromium
java
README.txtpom.xml
protobuf.gypprotobuf_lite_java_descriptor_proto.pyprotobuf_lite_java_parse_pom.pysrc
main
java
com
google
protobuf
AbstractMessage.javaAbstractMessageLite.javaAbstractParser.javaBlockingRpcChannel.javaBlockingService.javaBoundedByteString.javaByteString.javaCodedInputStream.javaCodedOutputStream.javaDescriptors.javaDynamicMessage.javaExtensionRegistry.javaExtensionRegistryLite.javaFieldSet.javaGeneratedMessage.javaGeneratedMessageLite.javaInternal.javaInvalidProtocolBufferException.javaLazyField.javaLazyStringArrayList.javaLazyStringList.javaLiteralByteString.javaMessage.javaMessageLite.javaMessageLiteOrBuilder.javaMessageOrBuilder.javaParser.javaProtocolMessageEnum.javaRepeatedFieldBuilder.javaRopeByteString.javaRpcCallback.javaRpcChannel.javaRpcController.javaRpcUtil.javaService.javaServiceException.javaSingleFieldBuilder.javaSmallSortedMap.javaTextFormat.javaUninitializedMessageException.javaUnknownFieldSet.javaUnmodifiableLazyStringList.javaUtf8.javaWireFormat.java
test
java
com
google
protobuf
AbstractMessageTest.javaBoundedByteStringTest.javaByteStringTest.javaCodedInputStreamTest.javaCodedOutputStreamTest.javaDeprecatedFieldTest.javaDescriptorsTest.javaDynamicMessageTest.javaForceFieldBuildersPreRun.javaGeneratedMessageTest.javaIsValidUtf8Test.javaIsValidUtf8TestUtil.javaLazyStringArrayListTest.javaLazyStringEndToEndTest.javaLiteTest.javaLiteralByteStringTest.javaMessageTest.javaNestedBuildersTest.javaParserTest.javaRepeatedFieldBuilderTest.javaRopeByteStringSubstringTest.javaRopeByteStringTest.javaServiceTest.javaSingleFieldBuilderTest.javaSmallSortedMapTest.javaTestBadIdentifiers.javaTestUtil.javaTextFormatTest.javaUnknownFieldSetTest.javaUnmodifiableLazyStringListTest.javaWireFormatTest.javamultiple_files_test.protonested_builders_test.protonested_extension.protonested_extension_lite.protonon_nested_extension.protonon_nested_extension_lite.prototest_bad_identifiers.proto
@@ -6,8 +6,7 @@
|
||||
"""Generate java source files from protobuf files.
|
||||
|
||||
Usage:
|
||||
protoc_java.py {protoc} {proto_path} {java_out} {proto_runtime} \
|
||||
{stamp_file} {proto_files}
|
||||
protoc_java.py {protoc} {proto_path} {java_out} {stamp_file} {proto_files}
|
||||
|
||||
This is a helper file for the genproto_java action in protoc_java.gypi.
|
||||
|
||||
@@ -16,8 +15,6 @@ It performs the following steps:
|
||||
2. Creates source directory.
|
||||
3. Generates Java files using protoc.
|
||||
4. Creates a new stamp file.
|
||||
|
||||
proto_runtime must be one of 'nano' and 'lite'.
|
||||
"""
|
||||
|
||||
import os
|
||||
@@ -26,12 +23,12 @@ import subprocess
|
||||
import sys
|
||||
|
||||
def main(argv):
|
||||
if len(argv) < 6:
|
||||
if len(argv) < 5:
|
||||
usage()
|
||||
return 1
|
||||
|
||||
protoc_path, proto_path, java_out, proto_runtime, stamp_file = argv[1:6]
|
||||
proto_files = argv[6:]
|
||||
protoc_path, proto_path, java_out, stamp_file = argv[1:5]
|
||||
proto_files = argv[5:]
|
||||
|
||||
# Delete all old sources.
|
||||
if os.path.exists(java_out):
|
||||
@@ -40,15 +37,10 @@ def main(argv):
|
||||
# Create source directory.
|
||||
os.makedirs(java_out)
|
||||
|
||||
# Figure out which runtime to use.
|
||||
if proto_runtime == 'nano':
|
||||
out_arg = '--javanano_out=optional_field_style=reftypes,' + \
|
||||
'store_unknown_fields=true:' + java_out
|
||||
elif proto_runtime == 'lite':
|
||||
out_arg = '--java_out=' + java_out
|
||||
else:
|
||||
usage()
|
||||
return 1
|
||||
# Specify arguments to the generator.
|
||||
generator_args = ['optional_field_style=reftypes',
|
||||
'store_unknown_fields=true']
|
||||
out_arg = '--javanano_out=' + ','.join(generator_args) + ':' + java_out
|
||||
|
||||
# Generate Java files using protoc.
|
||||
ret = subprocess.call(
|
||||
|
Reference in New Issue
Block a user