From 6c7878a151f05d64f675b800b054c5fc43f3dd6d Mon Sep 17 00:00:00 2001 From: Derek Mauro Date: Thu, 12 Jul 2018 13:46:50 -0400 Subject: Adds the UniversalPrinter for absl::variant. --- BUILD.bazel | 36 +++++++++++++++++++----------------- 1 file changed, 19 insertions(+), 17 deletions(-) (limited to 'BUILD.bazel') diff --git a/BUILD.bazel b/BUILD.bazel index 6d828294..f6dccd38 100644 --- a/BUILD.bazel +++ b/BUILD.bazel @@ -38,7 +38,7 @@ licenses(["notice"]) config_setting( name = "windows", - values = { "cpu": "x64_windows" }, + values = {"cpu": "x64_windows"}, ) config_setting( @@ -51,7 +51,6 @@ config_setting( values = {"define": "absl=1"}, ) - # Google Test including Google Mock cc_library( name = "gtest", @@ -70,7 +69,7 @@ cc_library( "googlemock/src/gmock_main.cc", ], ), - hdrs =glob([ + hdrs = glob([ "googletest/include/gtest/*.h", "googlemock/include/gmock/*.h", ]), @@ -81,6 +80,14 @@ cc_library( "//conditions:default": ["-pthread"], }, ), + defines = select( + { + ":has_absl": [ + "GTEST_HAS_ABSL=1", + ], + "//conditions:default": [], + }, + ), includes = [ "googlemock", "googlemock/include", @@ -94,21 +101,16 @@ cc_library( "-pthread", ], }), - defines = select ({ - ":has_absl": [ - "GTEST_HAS_ABSL=1", - ], - "//conditions:default": [], - } + deps = select( + { + ":has_absl": [ + "@com_google_absl//absl/types:optional", + "@com_google_absl//absl/types:variant", + "@com_google_absl//absl/strings", + ], + "//conditions:default": [], + }, ), - deps = select ({ - ":has_absl": [ - "@com_google_absl//absl/types:optional", - "@com_google_absl//absl/strings" - ], - "//conditions:default": [], - } - ) ) cc_library( -- cgit v1.2.1