aboutsummaryrefslogtreecommitdiffhomepage
path: root/third_party/farmhash.BUILD
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/farmhash.BUILD')
-rw-r--r--third_party/farmhash.BUILD23
1 files changed, 23 insertions, 0 deletions
diff --git a/third_party/farmhash.BUILD b/third_party/farmhash.BUILD
new file mode 100644
index 0000000000..6a1d4da6e5
--- /dev/null
+++ b/third_party/farmhash.BUILD
@@ -0,0 +1,23 @@
+licenses(["notice"]) # MIT
+
+exports_files(["COPYING"])
+
+config_setting(
+ name = "windows",
+ values = {
+ "cpu": "x64_windows_msvc",
+ },
+)
+
+cc_library(
+ name = "farmhash",
+ srcs = ["src/farmhash.cc"],
+ hdrs = ["src/farmhash.h"],
+ # Disable __builtin_expect support on Windows
+ copts = select({
+ ":windows": ["/DFARMHASH_OPTIONAL_BUILTIN_EXPECT"],
+ "//conditions:default": [],
+ }),
+ includes = ["src/."],
+ visibility = ["//visibility:public"],
+)