misterg | c2e7548 | 2017-09-19 16:54:40 -0400 | [diff] [blame] | 1 | # |
| 2 | # Copyright 2017 The Abseil Authors. |
| 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 | load( |
| 18 | "//absl:copts.bzl", |
| 19 | "ABSL_DEFAULT_COPTS", |
| 20 | "ABSL_TEST_COPTS", |
| 21 | ) |
| 22 | load( |
| 23 | "//absl:test_dependencies.bzl", |
| 24 | "GUNIT_MAIN_DEPS_SELECTOR", |
| 25 | ) |
| 26 | |
| 27 | package(default_visibility = ["//visibility:public"]) |
| 28 | |
| 29 | licenses(["notice"]) # Apache 2.0 |
| 30 | |
| 31 | cc_library( |
| 32 | name = "algorithm", |
| 33 | hdrs = ["algorithm.h"], |
| 34 | copts = ABSL_DEFAULT_COPTS, |
| 35 | ) |
| 36 | |
| 37 | cc_test( |
| 38 | name = "algorithm_test", |
| 39 | size = "small", |
| 40 | srcs = ["algorithm_test.cc"], |
| 41 | copts = ABSL_TEST_COPTS, |
| 42 | deps = [":algorithm"] + select(GUNIT_MAIN_DEPS_SELECTOR), |
| 43 | ) |
| 44 | |
| 45 | cc_library( |
| 46 | name = "container", |
| 47 | hdrs = [ |
| 48 | "container.h", |
| 49 | ], |
| 50 | copts = ABSL_DEFAULT_COPTS, |
| 51 | deps = [ |
| 52 | ":algorithm", |
| 53 | "//absl/base:core_headers", |
| 54 | "//absl/meta:type_traits", |
| 55 | ], |
| 56 | ) |
| 57 | |
| 58 | cc_test( |
| 59 | name = "container_test", |
| 60 | srcs = ["container_test.cc"], |
| 61 | copts = ABSL_TEST_COPTS, |
| 62 | deps = [ |
| 63 | ":container", |
| 64 | "//absl/base", |
| 65 | "//absl/base:core_headers", |
| 66 | "//absl/memory", |
| 67 | "//absl/types:span", |
| 68 | ] + select(GUNIT_MAIN_DEPS_SELECTOR), |
| 69 | ) |