Remove unnecessary defines

The only macro referenced by the public headers is GOOGLE_GLOG_DLL_DECL.
This means fewer defines are propagated to rules that depend on glog.
This commit is contained in:
Rodrigo Queiro 2019-11-20 13:59:59 +01:00 committed by Rodrigo Queiro
parent c0d2ceade6
commit 95a3655796

View File

@ -118,15 +118,9 @@ def glog_library(namespace = "google", with_gflags = 1, **kwargs):
name = "windows_glog_headers",
hdrs = native.glob(["src/windows/glog/*.h"]),
strip_include_prefix = "src/windows",
# TODO(rodrigoq): are these necessary?
# config.h for windows seem hardcoded that way,
# and we need to propagate those defines to binaries/libraries linking
# against glog.
defines = [
"GOOGLE_GLOG_IS_A_DLL=1",
"GOOGLE_GLOG_DLL_DECL=__declspec(dllexport)",
"GOOGLE_GLOG_DLL_DECL_FOR_UNITTEST=__declspec(dllimport)",
],
# We need to override the default GOOGLE_GLOG_DLL_DECL from
# src/windows/glog/*.h to match src/windows/config.h.
defines = ["GOOGLE_GLOG_DLL_DECL=__declspec(dllexport)"],
deps = [":strip_include_prefix_hack"],
)