aboutsummaryrefslogtreecommitdiff
path: root/java/org/brotli/wrapper/dec/BUILD
diff options
context:
space:
mode:
authorEugene Kliuchnikov <eustas@google.com>2017-10-09 17:07:34 +0200
committerGitHub <noreply@github.com>2017-10-09 17:07:34 +0200
commit42d78807bb56a336ff6b30d8e9dc14cd1cf8f105 (patch)
tree171473e64230d3b5dda796ec897b6563d0242b91 /java/org/brotli/wrapper/dec/BUILD
parent4f8cd4c0f4443d51a9603790a445b06c073b7a4d (diff)
downloadbrotli-42d78807bb56a336ff6b30d8e9dc14cd1cf8f105.zip
brotli-42d78807bb56a336ff6b30d8e9dc14cd1cf8f105.tar.gz
brotli-42d78807bb56a336ff6b30d8e9dc14cd1cf8f105.tar.bz2
Improve Bazel/JNI portability (#611)
* Improve Bazel/JNI portability * Update go and closure bazel addons
Diffstat (limited to 'java/org/brotli/wrapper/dec/BUILD')
-rwxr-xr-xjava/org/brotli/wrapper/dec/BUILD33
1 files changed, 23 insertions, 10 deletions
diff --git a/java/org/brotli/wrapper/dec/BUILD b/java/org/brotli/wrapper/dec/BUILD
index 58ab3d4..c8808fa 100755
--- a/java/org/brotli/wrapper/dec/BUILD
+++ b/java/org/brotli/wrapper/dec/BUILD
@@ -7,16 +7,17 @@ filegroup(
srcs = ["decoder_jni.cc"],
)
-#########################################
-# WARNING: do not depend on this target!
-#########################################
java_library(
name = "dec",
srcs = glob(
["*.java"],
exclude = ["*Test*.java"],
),
- deps = ["//:jni"],
+)
+
+filegroup(
+ name = "brotli_jni",
+ srcs = ["//:brotli_jni.dll"],
)
filegroup(
@@ -29,12 +30,16 @@ java_test(
size = "large",
srcs = ["BrotliDecoderChannelTest.java"],
data = [
+ ":brotli_jni", # Bazel JNI workaround
":test_bundle",
- "//:jni", # Bazel JNI workaround
],
- jvm_flags = ["-DTEST_BUNDLE=$(location :test_bundle)"],
+ jvm_flags = [
+ "-DBROTLI_JNI_LIBRARY=$(location :brotli_jni)",
+ "-DTEST_BUNDLE=$(location :test_bundle)",
+ ],
deps = [
":dec",
+ "//java/org/brotli/integration:brotli_jni_test_base",
"//java/org/brotli/integration:bundle_helper",
"@junit_junit//jar",
],
@@ -45,12 +50,16 @@ java_test(
size = "large",
srcs = ["BrotliInputStreamTest.java"],
data = [
+ ":brotli_jni", # Bazel JNI workaround
":test_bundle",
- "//:jni", # Bazel JNI workaround
],
- jvm_flags = ["-DTEST_BUNDLE=$(location :test_bundle)"],
+ jvm_flags = [
+ "-DBROTLI_JNI_LIBRARY=$(location :brotli_jni)",
+ "-DTEST_BUNDLE=$(location :test_bundle)",
+ ],
deps = [
":dec",
+ "//java/org/brotli/integration:brotli_jni_test_base",
"//java/org/brotli/integration:bundle_helper",
"@junit_junit//jar",
],
@@ -61,12 +70,16 @@ java_test(
size = "large",
srcs = ["DecoderTest.java"],
data = [
+ ":brotli_jni", # Bazel JNI workaround
":test_bundle",
- "//:jni", # Bazel JNI workaround
],
- jvm_flags = ["-DTEST_BUNDLE=$(location :test_bundle)"],
+ jvm_flags = [
+ "-DBROTLI_JNI_LIBRARY=$(location :brotli_jni)",
+ "-DTEST_BUNDLE=$(location :test_bundle)",
+ ],
deps = [
":dec",
+ "//java/org/brotli/integration:brotli_jni_test_base",
"//java/org/brotli/integration:bundle_helper",
"@junit_junit//jar",
],