blob: 4e9391db9a5b0f1acd5ed7eaf96b7a08e1486f1f [file] [log] [blame]
Dan Willemsend3eac262017-09-08 22:47:47 -07001//
2// Copyright (C) 2015 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15//
16
17// ==========================================================
18// Build the host executable: protoc-gen-javastream
19// ==========================================================
Yi Jin0473f88b2017-10-09 11:21:40 -070020cc_defaults {
21 name: "protoc-gen-stream-defaults",
Dan Willemsend3eac262017-09-08 22:47:47 -070022 srcs: [
23 "Errors.cpp",
Yi Jinf9ed04b2017-10-20 16:17:58 -070024 "stream_proto_utils.cpp",
Dan Willemsend3eac262017-09-08 22:47:47 -070025 "string_utils.cpp",
Yi Jin0473f88b2017-10-09 11:21:40 -070026 ],
Chih-Hung Hsieh548fdbd2017-12-05 10:11:02 -080027 cflags: [
28 "-Wall",
29 "-Werror",
30 ],
Yi Jinf9ed04b2017-10-20 16:17:58 -070031
32 shared_libs: ["libprotoc"],
Yi Jin0473f88b2017-10-09 11:21:40 -070033}
34
Yi Jin04625ad2017-10-17 18:29:33 -070035cc_library {
36 name: "streamingflags",
37 host_supported: true,
38 proto: {
39 export_proto_headers: true,
40 include_dirs: ["external/protobuf/src"],
41 },
42
43 target: {
44 host: {
45 proto: {
46 type: "full",
47 },
48 srcs: [
49 "stream.proto",
50 ],
51 },
52 },
53}
Yi Jin0473f88b2017-10-09 11:21:40 -070054
55cc_binary_host {
56 name: "protoc-gen-javastream",
57 srcs: [
58 "java/main.cpp",
Dan Willemsend3eac262017-09-08 22:47:47 -070059 ],
60
Yi Jin0473f88b2017-10-09 11:21:40 -070061 defaults: ["protoc-gen-stream-defaults"],
Yi Jin0473f88b2017-10-09 11:21:40 -070062}
63
64cc_binary_host {
65 name: "protoc-gen-cppstream",
66 srcs: [
67 "cpp/main.cpp",
68 ],
69
70 defaults: ["protoc-gen-stream-defaults"],
Yi Jin04625ad2017-10-17 18:29:33 -070071 static_libs: ["streamingflags"],
Dan Willemsend3eac262017-09-08 22:47:47 -070072}