Don't ship bouncycastle libraries in plugin API
We cannot shade bouncycastle in the plugin API. Still we need it to be included in the gerrit.war, licenses file and Eclipse classpath. Expose bouncycastle libraries in PLUGIN_TEST_DEPS constant, so that the plugins don't need to change anything in tree build mode. gerrit_api() bazlet in bazlets repository is extended too, so that the plugins don't need to change anything in standalone build mode. One side effect of this change, is that bouncycastle libraries are now listed with neverlink suffix, e.g.: * bouncycastle:bcprov-neverlink Bug: Issue 5826 Change-Id: Idb8051e16b14e20c8dd528783ab297ee25707bb3
This commit is contained in:
parent
c0c01903fe
commit
c5f8066629
@ -10,8 +10,6 @@ def acceptance_tests(
|
||||
name = group,
|
||||
deps = deps + [
|
||||
'//gerrit-acceptance-tests:lib',
|
||||
"//lib/bouncycastle:bcpkix",
|
||||
"//lib/bouncycastle:bcpg",
|
||||
],
|
||||
tags = labels + [
|
||||
'acceptance',
|
||||
|
@ -19,8 +19,8 @@ java_library(
|
||||
srcs = glob(["src/main/java/**/*.java"]),
|
||||
visibility = ["//visibility:public"],
|
||||
deps = DEPS + [
|
||||
"//lib/bouncycastle:bcpg",
|
||||
"//lib/bouncycastle:bcprov",
|
||||
"//lib/bouncycastle:bcpg-neverlink",
|
||||
"//lib/bouncycastle:bcprov-neverlink",
|
||||
],
|
||||
)
|
||||
|
||||
@ -32,9 +32,9 @@ java_library(
|
||||
srcs = TESTUTIL_SRCS,
|
||||
visibility = ["//visibility:public"],
|
||||
deps = DEPS + [
|
||||
"//lib/bouncycastle:bcpg-neverlink",
|
||||
"//lib/bouncycastle:bcprov-neverlink",
|
||||
":gpg",
|
||||
"//lib/bouncycastle:bcpg",
|
||||
"//lib/bouncycastle:bcprov",
|
||||
],
|
||||
)
|
||||
|
||||
|
@ -55,8 +55,8 @@ java_library(
|
||||
"//lib:velocity",
|
||||
"//lib/antlr:java_runtime",
|
||||
"//lib/auto:auto-value",
|
||||
"//lib/bouncycastle:bcpkix",
|
||||
"//lib/bouncycastle:bcprov",
|
||||
"//lib/bouncycastle:bcpkix-neverlink",
|
||||
"//lib/bouncycastle:bcprov-neverlink",
|
||||
"//lib/commons:codec",
|
||||
"//lib/commons:compress",
|
||||
"//lib/commons:dbcp",
|
||||
@ -230,6 +230,7 @@ junit_tests(
|
||||
"//lib:guava-retrying",
|
||||
"//lib:protobuf",
|
||||
"//lib/bouncycastle:bcprov",
|
||||
"//lib/bouncycastle:bcpkix",
|
||||
"//lib/dropwizard:dropwizard-core",
|
||||
"//lib/guice:guice-assistedinject",
|
||||
"//lib/prolog:runtime",
|
||||
|
@ -23,7 +23,7 @@ java_library(
|
||||
"//lib:jsch",
|
||||
"//lib:servlet-api-3_1",
|
||||
"//lib/auto:auto-value",
|
||||
"//lib/bouncycastle:bcprov",
|
||||
"//lib/bouncycastle:bcprov-neverlink",
|
||||
"//lib/commons:codec",
|
||||
"//lib/dropwizard:dropwizard-core",
|
||||
"//lib/guice",
|
||||
|
@ -18,3 +18,27 @@ java_library(
|
||||
visibility = ["//visibility:public"],
|
||||
exports = ["@bcpkix//jar"],
|
||||
)
|
||||
|
||||
java_library(
|
||||
name = "bcprov-neverlink",
|
||||
data = ["//lib:LICENSE-bouncycastle"],
|
||||
neverlink = 1,
|
||||
visibility = ["//visibility:public"],
|
||||
exports = ["@bcprov//jar"],
|
||||
)
|
||||
|
||||
java_library(
|
||||
name = "bcpg-neverlink",
|
||||
data = ["//lib:LICENSE-bouncycastle"],
|
||||
neverlink = 1,
|
||||
visibility = ["//visibility:public"],
|
||||
exports = ["@bcpg//jar"],
|
||||
)
|
||||
|
||||
java_library(
|
||||
name = "bcpkix-neverlink",
|
||||
data = ["//lib:LICENSE-bouncycastle"],
|
||||
neverlink = 1,
|
||||
visibility = ["//visibility:public"],
|
||||
exports = ["@bcpkix//jar"],
|
||||
)
|
||||
|
@ -21,6 +21,9 @@ LIBS = [
|
||||
"//gerrit-war:log4j-config",
|
||||
"//gerrit-war:version",
|
||||
"//lib:postgresql",
|
||||
"//lib/bouncycastle:bcpkix",
|
||||
"//lib/bouncycastle:bcprov",
|
||||
"//lib/bouncycastle:bcpg",
|
||||
"//lib/log:impl_log4j",
|
||||
]
|
||||
|
||||
|
@ -12,7 +12,12 @@ load(
|
||||
|
||||
PLUGIN_DEPS = ["//gerrit-plugin-api:lib"]
|
||||
|
||||
PLUGIN_TEST_DEPS = ["//gerrit-acceptance-framework:lib"]
|
||||
PLUGIN_TEST_DEPS = [
|
||||
"//gerrit-acceptance-framework:lib",
|
||||
"//lib/bouncycastle:bcpg",
|
||||
"//lib/bouncycastle:bcpkix",
|
||||
"//lib/bouncycastle:bcprov",
|
||||
]
|
||||
|
||||
def gerrit_plugin(
|
||||
name,
|
||||
|
Loading…
x
Reference in New Issue
Block a user