gerrit/antlr3/BUILD
David Pursehouse 726b4cc796 Merge branch 'stable-2.16' into stable-3.0
* stable-2.16:
  Load proto_library from @rules_proto//proto:defs.bzl
  Update git submodules
  Bazel: Add fixes for --incompatible_load_{java|python}_rules_from_bzl
  Bazel: Bump minimum supported version to 0.29.0
  Lucene index configuration and docs.

Change-Id: I401c192096047dd5069be37f17c4a62a8ed3afb7
2019-09-05 08:17:48 +09:00

34 lines
933 B
Python

load("@rules_java//java:defs.bzl", "java_library")
load("//tools/bzl:genrule2.bzl", "genrule2")
genrule2(
name = "query",
srcs = ["com/google/gerrit/index/query/Query.g"],
outs = ["query_antlr.srcjar"],
cmd = " && ".join([
"$(location //lib/antlr:antlr-tool) -o $$TMP $<",
"cd $$TMP",
"find . -exec touch -t 198001010000 '{}' ';'",
"zip -q $$ROOT/$@ $$(find . -type f)",
]),
tools = [
"//lib/antlr:antlr-tool",
],
visibility = ["//visibility:public"],
)
java_library(
name = "query_parser",
srcs = [":query"],
visibility = [
"//java/com/google/gerrit/index:__subpackages__",
"//javatests/com/google/gerrit:__subpackages__",
"//javatests/com/google/gerrit/index:__pkg__",
"//plugins:__pkg__",
],
deps = [
"//java/com/google/gerrit/index:query_exception",
"//lib/antlr:java-runtime",
],
)