|
| 1 | +# Copyright 2022 Google LLC |
| 2 | +# |
| 3 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | +# you may not use this file except in compliance with the License. |
| 5 | +# You may obtain a copy of the License at |
| 6 | +# |
| 7 | +# https://www.apache.org/licenses/LICENSE-2.0 |
| 8 | +# |
| 9 | +# Unless required by applicable law or agreed to in writing, software |
| 10 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | +# See the License for the specific language governing permissions and |
| 13 | +# limitations under the License. |
| 14 | + |
| 15 | +package(default_visibility = ["//visibility:private"]) |
| 16 | + |
| 17 | +licenses(["notice"]) # Apache 2.0 |
| 18 | + |
| 19 | +SOURCE_GLOB = "**/*.cc" |
| 20 | + |
| 21 | +MOCK_SOURCE_GLOB = "mocks/*.cc" |
| 22 | + |
| 23 | +HEADER_GLOB = "**/*.h" |
| 24 | + |
| 25 | +MOCK_HEADER_GLOB = "mocks/*.h" |
| 26 | + |
| 27 | +cc_library( |
| 28 | + name = "google_cloud_cpp_shell", |
| 29 | + srcs = glob( |
| 30 | + include = [SOURCE_GLOB], |
| 31 | + exclude = [MOCK_SOURCE_GLOB], |
| 32 | + ), |
| 33 | + hdrs = glob( |
| 34 | + include = [HEADER_GLOB], |
| 35 | + exclude = [MOCK_HEADER_GLOB], |
| 36 | + ), |
| 37 | + visibility = ["//:__pkg__"], |
| 38 | + deps = [ |
| 39 | + "//google/cloud:google_cloud_cpp_common", |
| 40 | + "//google/cloud:google_cloud_cpp_grpc_utils", |
| 41 | + "@com_google_googleapis//google/cloud/shell/v1:shell_cc_grpc", |
| 42 | + ], |
| 43 | +) |
| 44 | + |
| 45 | +cc_library( |
| 46 | + name = "google_cloud_cpp_shell_mocks", |
| 47 | + srcs = glob( |
| 48 | + include = [MOCK_SOURCE_GLOB], |
| 49 | + ), |
| 50 | + hdrs = glob( |
| 51 | + include = [MOCK_HEADER_GLOB], |
| 52 | + ), |
| 53 | + visibility = ["//:__pkg__"], |
| 54 | + deps = [ |
| 55 | + ":google_cloud_cpp_shell", |
| 56 | + "//google/cloud:google_cloud_cpp_common", |
| 57 | + "//google/cloud:google_cloud_cpp_grpc_utils", |
| 58 | + ], |
| 59 | +) |
0 commit comments