blob: 44085c696edc466b348d7abd023f545a691b6362 [file] [log] [blame]
include_defs('//plugins/owners/common.defs')
include_defs('//lib/maven.defs')
include_defs('//lib/prolog/prolog.defs')
# buck is unhappy to build a gerrit_plugin with no source files.
# On the other side, gerrit-owners-prolog-rules needs to be built after all the java files have been
# compiled. For this reason we have a stub class that has no content and just makes buck happy.
COMPILE_STUB = ['src/main/java/com/vmware/gerrit/owners/CompileStub.java']
java_library(
name = 'gerrit-owners-lib',
srcs = glob([
'src/main/java/**/*.java',
], excludes=COMPILE_STUB),
deps = [
'//plugins/owners/gerrit-owners-common:common',
] + COMPILE_DEPS + EXTERNAL_DEPS,
)
prolog_cafe_library(
name = 'gerrit-owners-prolog-rules',
srcs = glob(['src/main/prolog/*.pl']),
deps = [
':gerrit-owners-lib',
'//gerrit-server/src/main/prolog:common',
],
)
gerrit_plugin(
name = 'owners',
srcs = COMPILE_STUB,
manifest_entries = [
'Implementation-Title: Gerrit OWNERS plugin',
'Implementation-URL: https://github.com/vadims/gerrit-owners',
'Gerrit-PluginName: owners',
'Gerrit-Module: com.vmware.gerrit.owners.OwnersModule',
],
deps = [
':gerrit-owners-lib',
':gerrit-owners-prolog-rules',
] + EXTERNAL_DEPS,
)