Buck: Fix api build
gwt-dev dependencies were moved from external constant to maven_jar() exported_deps dependency in I54df92daf. As the consequence, maven_jar makes from it java_library instead of prebuil_jar. As the consequence java_library without sources and resources doesn't expose output jar. This broke java_doc() rule in gwtui-api that makes use of $(location) macro. This macros is failing on libraries without own output jar. To rectify it, expose intermediate prebuilt_jar from maven_jar() rule with the same visibility scope as the final artifact. Now it can be used in java_doc() as it exposes output jar and exported_deps aren't needed in this context. Change-Id: I6168fda0aba8827063958f80c6e2828b0a6941f8
This commit is contained in:
parent
78ba17b897
commit
1da31b3520
@ -3,10 +3,7 @@ GWTEXPUI = ['gerrit-gwtexpui/src/main/java/']
|
|||||||
SRC = 'src/main/java/com/google/gerrit/'
|
SRC = 'src/main/java/com/google/gerrit/'
|
||||||
SRCS = glob([SRC + '**/*.java'])
|
SRCS = glob([SRC + '**/*.java'])
|
||||||
|
|
||||||
DEPS = [
|
DEPS = ['//lib/gwt:user']
|
||||||
'//lib/gwt:user',
|
|
||||||
'//lib/gwt:dev',
|
|
||||||
]
|
|
||||||
|
|
||||||
java_binary(
|
java_binary(
|
||||||
name = 'gwtui-api',
|
name = 'gwtui-api',
|
||||||
@ -36,7 +33,7 @@ java_library(
|
|||||||
'//gerrit-gwtexpui:UserAgent',
|
'//gerrit-gwtexpui:UserAgent',
|
||||||
'//gerrit-gwtui-common:client-lib2',
|
'//gerrit-gwtui-common:client-lib2',
|
||||||
],
|
],
|
||||||
provided_deps = DEPS,
|
provided_deps = DEPS + ['//lib/gwt:dev'],
|
||||||
visibility = ['PUBLIC'],
|
visibility = ['PUBLIC'],
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -69,7 +66,10 @@ java_doc(
|
|||||||
],
|
],
|
||||||
paths = COMMON + GWTEXPUI,
|
paths = COMMON + GWTEXPUI,
|
||||||
srcs = SRCS,
|
srcs = SRCS,
|
||||||
deps = DEPS + ['//gerrit-gwtui-common:client-lib2'],
|
deps = DEPS + [
|
||||||
|
'//lib/gwt:dev__jar',
|
||||||
|
'//gerrit-gwtui-common:client-lib2',
|
||||||
|
],
|
||||||
visibility = ['PUBLIC'],
|
visibility = ['PUBLIC'],
|
||||||
do_it_wrong = True,
|
do_it_wrong = True,
|
||||||
)
|
)
|
||||||
|
@ -134,6 +134,7 @@ def maven_jar(
|
|||||||
deps = deps + license,
|
deps = deps + license,
|
||||||
binary_jar = ':%s__download_bin' % name,
|
binary_jar = ':%s__download_bin' % name,
|
||||||
source_jar = ':%s__download_src' % name if srcjar else None,
|
source_jar = ':%s__download_src' % name if srcjar else None,
|
||||||
|
visibility = visibility,
|
||||||
)
|
)
|
||||||
java_library(
|
java_library(
|
||||||
name = name,
|
name = name,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user