OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 config("protobuf_config") { | 5 config("protobuf_config") { |
6 include_dirs = [ "src" ] | 6 include_dirs = [ "src" ] |
7 defines = [ | 7 defines = [ |
8 "GOOGLE_PROTOBUF_NO_RTTI", | 8 "GOOGLE_PROTOBUF_NO_RTTI", |
9 "GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER", | 9 "GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER", |
10 ] | 10 ] |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
168 # Required for component builds. See http://crbug.com/172800. | 168 # Required for component builds. See http://crbug.com/172800. |
169 if (is_component_build) { | 169 if (is_component_build) { |
170 public_configs += [ ":protobuf_use_dlls" ] | 170 public_configs += [ ":protobuf_use_dlls" ] |
171 defines = [ "LIBPROTOBUF_EXPORTS" ] | 171 defines = [ "LIBPROTOBUF_EXPORTS" ] |
172 } | 172 } |
173 } | 173 } |
174 | 174 |
175 # This is the full, heavy protobuf lib that's needed for c++ .protos that don't | 175 # This is the full, heavy protobuf lib that's needed for c++ .protos that don't |
176 # specify the LITE_RUNTIME option. The protocol compiler itself (protoc) falls | 176 # specify the LITE_RUNTIME option. The protocol compiler itself (protoc) falls |
177 # into that category. Do not use in Chrome code. | 177 # into that category. Do not use in Chrome code. |
178 source_set("protobuf_full") { | 178 static_library("protobuf_full") { |
179 # Prevent people from depending on this outside our file. | 179 # Prevent people from depending on this outside our file. |
180 visibility = [ ":*" ] | 180 visibility = [ ":*" ] |
181 | 181 |
182 sources = protobuf_lite_sources | 182 sources = protobuf_lite_sources |
183 sources += [ | 183 sources += [ |
184 "src/google/protobuf/any.cc", | 184 "src/google/protobuf/any.cc", |
185 "src/google/protobuf/any.h", | 185 "src/google/protobuf/any.h", |
186 "src/google/protobuf/any.pb.cc", | 186 "src/google/protobuf/any.pb.cc", |
187 "src/google/protobuf/any.pb.h", | 187 "src/google/protobuf/any.pb.h", |
188 "src/google/protobuf/api.pb.cc", | 188 "src/google/protobuf/api.pb.cc", |
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
331 ] | 331 ] |
332 | 332 |
333 cflags = protobuf_lite_cflags | 333 cflags = protobuf_lite_cflags |
334 } | 334 } |
335 | 335 |
336 # Only compile the compiler for the host architecture. | 336 # Only compile the compiler for the host architecture. |
337 if (current_toolchain == host_toolchain) { | 337 if (current_toolchain == host_toolchain) { |
338 # protoc compiler is separated into protoc library and executable targets to | 338 # protoc compiler is separated into protoc library and executable targets to |
339 # support protoc plugins that need to link libprotoc, but not the main() | 339 # support protoc plugins that need to link libprotoc, but not the main() |
340 # itself. See src/google/protobuf/compiler/plugin.h | 340 # itself. See src/google/protobuf/compiler/plugin.h |
341 source_set("protoc_lib") { | 341 static_library("protoc_lib") { |
342 sources = [ | 342 sources = [ |
343 "src/google/protobuf/compiler/code_generator.cc", | 343 "src/google/protobuf/compiler/code_generator.cc", |
344 "src/google/protobuf/compiler/code_generator.h", | 344 "src/google/protobuf/compiler/code_generator.h", |
345 "src/google/protobuf/compiler/command_line_interface.cc", | 345 "src/google/protobuf/compiler/command_line_interface.cc", |
346 "src/google/protobuf/compiler/command_line_interface.h", | 346 "src/google/protobuf/compiler/command_line_interface.h", |
347 "src/google/protobuf/compiler/cpp/cpp_enum.cc", | 347 "src/google/protobuf/compiler/cpp/cpp_enum.cc", |
348 "src/google/protobuf/compiler/cpp/cpp_enum.h", | 348 "src/google/protobuf/compiler/cpp/cpp_enum.h", |
349 "src/google/protobuf/compiler/cpp/cpp_enum_field.cc", | 349 "src/google/protobuf/compiler/cpp/cpp_enum_field.cc", |
350 "src/google/protobuf/compiler/cpp/cpp_enum_field.h", | 350 "src/google/protobuf/compiler/cpp/cpp_enum_field.h", |
351 "src/google/protobuf/compiler/cpp/cpp_extension.cc", | 351 "src/google/protobuf/compiler/cpp/cpp_extension.cc", |
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
643 ":copy_google_protobuf_internal", | 643 ":copy_google_protobuf_internal", |
644 ":copy_six", | 644 ":copy_six", |
645 ] | 645 ] |
646 | 646 |
647 # Targets that depend on this should depend on the copied data files. | 647 # Targets that depend on this should depend on the copied data files. |
648 data = get_target_outputs(":copy_google") | 648 data = get_target_outputs(":copy_google") |
649 data += get_target_outputs(":copy_six") | 649 data += get_target_outputs(":copy_six") |
650 data += get_target_outputs(":copy_google_protobuf") | 650 data += get_target_outputs(":copy_google_protobuf") |
651 data += get_target_outputs(":copy_google_protobuf_internal") | 651 data += get_target_outputs(":copy_google_protobuf_internal") |
652 } | 652 } |
OLD | NEW |