File: 0044-trim-protoc-main.patch

package info (click to toggle)
chromium 139.0.7258.127-1
  • links: PTS, VCS
  • area: main
  • in suites:
  • size: 6,122,068 kB
  • sloc: cpp: 35,100,771; ansic: 7,163,530; javascript: 4,103,002; python: 1,436,920; asm: 946,517; xml: 746,709; pascal: 187,653; perl: 88,691; sh: 88,436; objc: 79,953; sql: 51,488; cs: 44,583; fortran: 24,137; makefile: 22,147; tcl: 15,277; php: 13,980; yacc: 8,984; ruby: 7,485; awk: 3,720; lisp: 3,096; lex: 1,327; ada: 727; jsp: 228; sed: 36
file content (69 lines) | stat: -rw-r--r-- 2,833 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
diff --git a/src/google/protobuf/compiler/main.cc b/src/google/protobuf/compiler/main.cc
index 6ffff719fa3d5..02085bb887478 100644
--- a/src/google/protobuf/compiler/main.cc
+++ b/src/google/protobuf/compiler/main.cc
@@ -8,16 +8,9 @@
 #include "absl/log/initialize.h"
 #include "google/protobuf/compiler/command_line_interface.h"
 #include "google/protobuf/compiler/cpp/generator.h"
-#include "google/protobuf/compiler/csharp/csharp_generator.h"
 #include "google/protobuf/compiler/java/generator.h"
-#include "google/protobuf/compiler/kotlin/generator.h"
-#include "google/protobuf/compiler/objectivec/generator.h"
-#include "google/protobuf/compiler/php/php_generator.h"
 #include "google/protobuf/compiler/python/generator.h"
 #include "google/protobuf/compiler/python/pyi_generator.h"
-#include "google/protobuf/compiler/ruby/ruby_generator.h"
-#include "google/protobuf/compiler/rust/generator.h"
-#include "upb_generator/minitable/generator.h"
 
 #ifdef DISABLE_PROTOC_CONFIG
 #include "google/protobuf/compiler/allowlists/allowlist.h"
@@ -63,11 +56,6 @@ int ProtobufMain(int argc, char* argv[]) {
   java_generator.set_opensource_runtime(true);
 #endif
 
-  // Proto2 Kotlin
-  kotlin::KotlinGenerator kt_generator;
-  cli.RegisterGenerator("--kotlin_out", "--kotlin_opt", &kt_generator,
-                        "Generate Kotlin file.");
-
 
   // Proto2 Python
   python::Generator py_generator;
@@ -83,35 +71,6 @@ int ProtobufMain(int argc, char* argv[]) {
   cli.RegisterGenerator("--pyi_out", &pyi_generator,
                         "Generate python pyi stub.");
 
-  // PHP
-  php::Generator php_generator;
-  cli.RegisterGenerator("--php_out", "--php_opt", &php_generator,
-                        "Generate PHP source file.");
-
-  // Ruby
-  ruby::Generator rb_generator;
-  cli.RegisterGenerator("--ruby_out", "--ruby_opt", &rb_generator,
-                        "Generate Ruby source file.");
-
-  // CSharp
-  csharp::Generator csharp_generator;
-  cli.RegisterGenerator("--csharp_out", "--csharp_opt", &csharp_generator,
-                        "Generate C# source file.");
-
-  // Objective-C
-  objectivec::ObjectiveCGenerator objc_generator;
-  cli.RegisterGenerator("--objc_out", "--objc_opt", &objc_generator,
-                        "Generate Objective-C header and source.");
-
-  // Rust
-  rust::RustGenerator rust_generator;
-  cli.RegisterGenerator("--rust_out", "--rust_opt", &rust_generator,
-                        "Generate Rust sources.");
-
-  // upb minitables
-  upb::generator::MiniTableGenerator minitable_generator;
-  cli.RegisterGenerator("--upb_minitable_out", "--upb_minitable_opt",
-                        &minitable_generator, "Generate upb minitables");
 #ifdef DISABLE_PROTOC_CONFIG
   auto cleanup = internal::DisableAllowlistInternalOnly();
 #endif  // DISABLE_PROTOC_CONFIG