diff --git a/gerrit-common/BUCK b/gerrit-common/BUCK index a4d399ba0a..718c751a5a 100644 --- a/gerrit-common/BUCK +++ b/gerrit-common/BUCK @@ -32,7 +32,7 @@ gwt_module( '//gerrit-reviewdb:client', '//lib:gwtjsonrpc', '//lib:gwtorm', - '//lib/jgit:jgit', + '//lib/jgit:Edit', ], visibility = ['PUBLIC'], ) diff --git a/gerrit-gwtui/BUCK b/gerrit-gwtui/BUCK index 2a6c7f8d33..ce6e081a35 100644 --- a/gerrit-gwtui/BUCK +++ b/gerrit-gwtui/BUCK @@ -44,7 +44,7 @@ gwt_module( '//lib:gwtorm', '//lib/codemirror:codemirror', '//lib/gwt:user', - '//lib/jgit:jgit', + '//lib/jgit:Edit', ], visibility = [ '//tools/eclipse:classpath', diff --git a/gerrit-patch-jgit/BUCK b/gerrit-patch-jgit/BUCK index e62172229c..64155bf7df 100644 --- a/gerrit-patch-jgit/BUCK +++ b/gerrit-patch-jgit/BUCK @@ -10,7 +10,6 @@ gwt_module( deps = [ '//lib:gwtjsonrpc', '//lib/gwt:user', - '//lib/jgit:jgit', '//lib/jgit:Edit', ], visibility = ['PUBLIC'], diff --git a/gerrit-prettify/BUCK b/gerrit-prettify/BUCK index cc42d2b769..2a5367e2f8 100644 --- a/gerrit-prettify/BUCK +++ b/gerrit-prettify/BUCK @@ -18,7 +18,7 @@ gwt_module( '//lib:guava', '//lib:gwtjsonrpc', '//lib/gwt:user', - '//lib/jgit:jgit', + '//lib/jgit:Edit', ], visibility = ['PUBLIC'], ) diff --git a/lib/jgit/BUCK b/lib/jgit/BUCK index 68847f6e9e..c7c63763e7 100644 --- a/lib/jgit/BUCK +++ b/lib/jgit/BUCK @@ -67,17 +67,23 @@ maven_jar( license = 'Apache2.0', ) -prebuilt_jar( +gwt_module( name = 'Edit', - binary_jar = ':jgit_edit_src', + srcs = [':jgit_edit_src'], + deps = [':edit_src'], visibility = ['PUBLIC'], ) +prebuilt_jar( + name = 'edit_src', + binary_jar = ':jgit_edit_src', +) + genrule( name = 'jgit_edit_src', cmd = 'unzip -qd $TMP $(location :jgit_src) ' + 'org/eclipse/jgit/diff/Edit.java;' + 'cd $TMP;' + 'zip -Dq $OUT org/eclipse/jgit/diff/Edit.java', - out = 'edit-src.jar', + out = 'edit.src.zip', )