diff --git a/gerrit-acceptance-framework/BUCK b/gerrit-acceptance-framework/BUCK index 2e4218e98e..d642942713 100644 --- a/gerrit-acceptance-framework/BUCK +++ b/gerrit-acceptance-framework/BUCK @@ -16,7 +16,7 @@ DEPS = [ '//lib/jetty:servlet', '//lib/log:impl_log4j', '//lib/log:log4j', - '@jgit//:junit', + '@jgit//org.eclipse.jgit.junit:junit', ] PROVIDED = [ @@ -32,7 +32,7 @@ PROVIDED = [ '//lib:jsch', '//lib/mina:sshd', '//lib:servlet-api-3_1', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ] java_binary( diff --git a/gerrit-acceptance-tests/BUCK b/gerrit-acceptance-tests/BUCK index ebc5d005b9..9adaa01e2e 100644 --- a/gerrit-acceptance-tests/BUCK +++ b/gerrit-acceptance-tests/BUCK @@ -34,7 +34,7 @@ java_library( '//lib/guice:guice-servlet', '//lib/log:api', '//lib/mina:sshd', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = [ '//gerrit-plugin-api/...', diff --git a/gerrit-cache-h2/BUCK b/gerrit-cache-h2/BUCK index 7790a23af9..36f91ec786 100644 --- a/gerrit-cache-h2/BUCK +++ b/gerrit-cache-h2/BUCK @@ -9,7 +9,7 @@ java_library( '//lib:h2', '//lib/guice:guice', '//lib/log:api', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = ['PUBLIC'], ) diff --git a/gerrit-common/BUCK b/gerrit-common/BUCK index 10bb754804..ab62b40b72 100644 --- a/gerrit-common/BUCK +++ b/gerrit-common/BUCK @@ -46,7 +46,7 @@ java_library( '//lib:guava', '//lib/joda:joda-time', '//lib/log:api', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = ['PUBLIC'], ) diff --git a/gerrit-gpg/BUCK b/gerrit-gpg/BUCK index 6d6579c342..5d193aa743 100644 --- a/gerrit-gpg/BUCK +++ b/gerrit-gpg/BUCK @@ -9,7 +9,7 @@ DEPS = [ '//lib/guice:guice-assistedinject', '//lib/guice:guice-servlet', '//lib/log:api', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ] java_library( @@ -50,7 +50,7 @@ java_test( '//lib:truth', '//lib/bouncycastle:bcpg', '//lib/bouncycastle:bcprov', - '@jgit//:junit', + '@jgit//org.eclipse.jgit.junit:junit', ], source_under_test = [':gpg'], visibility = ['//tools/eclipse:classpath'], diff --git a/gerrit-gwtui-common/BUCK b/gerrit-gwtui-common/BUCK index 6aa2d9812a..b417d30e7d 100644 --- a/gerrit-gwtui-common/BUCK +++ b/gerrit-gwtui-common/BUCK @@ -64,7 +64,7 @@ java_test( ':client', '//lib:junit', '//lib/gwt:user', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], source_under_test = [':client'], vm_args = ['-Xmx512m'], diff --git a/gerrit-httpd/BUCK b/gerrit-httpd/BUCK index 3eff7d9353..e17caede55 100644 --- a/gerrit-httpd/BUCK +++ b/gerrit-httpd/BUCK @@ -35,8 +35,8 @@ java_library( '//lib/guice:guice-servlet', '//lib/log:api', '//lib/lucene:lucene-core-and-backward-codecs', - '@jgit//:jgit', - '@jgit//:jgit-servlet', + '@jgit//org.eclipse.jgit:jgit', + '@jgit//org.eclipse.jgit.http.server:jgit-servlet', ], provided_deps = ['//lib:servlet-api-3_1'], visibility = ['PUBLIC'], @@ -70,8 +70,8 @@ java_test( '//lib/guice:guice', '//lib/guice:guice-servlet', '//lib/joda:joda-time', - '@jgit//:jgit', - '@jgit//:junit', + '@jgit//org.eclipse.jgit:jgit', + '@jgit//org.eclipse.jgit.junit:junit', ], source_under_test = [':httpd'], # TODO(sop) Remove after Buck supports Eclipse diff --git a/gerrit-lucene/BUCK b/gerrit-lucene/BUCK index 7b524df9d3..163340ba8f 100644 --- a/gerrit-lucene/BUCK +++ b/gerrit-lucene/BUCK @@ -35,7 +35,7 @@ java_library( '//lib/lucene:lucene-analyzers-common', '//lib/lucene:lucene-core-and-backward-codecs', '//lib/lucene:lucene-misc', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = ['PUBLIC'], ) diff --git a/gerrit-openid/BUCK b/gerrit-openid/BUCK index 9e9939923e..bfbdb431b5 100644 --- a/gerrit-openid/BUCK +++ b/gerrit-openid/BUCK @@ -20,7 +20,7 @@ java_library( '//lib/guice:guice', '//lib/guice:guice-servlet', '//lib/log:api', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = ['PUBLIC'], ) diff --git a/gerrit-patch-jgit/BUCK b/gerrit-patch-jgit/BUCK index 434be3714c..90f5e4e311 100644 --- a/gerrit-patch-jgit/BUCK +++ b/gerrit-patch-jgit/BUCK @@ -29,7 +29,7 @@ prebuilt_jar( genrule( name = 'jgit_edit_src', - cmd = 'unzip -qd $TMP $(location @jgit//:jgit_src) ' + + cmd = 'unzip -qd $TMP $(location @jgit//org.eclipse.jgit:jgit_src) ' + 'org/eclipse/jgit/diff/Edit.java;' + 'cd $TMP;' + 'zip -Dq $OUT org/eclipse/jgit/diff/Edit.java', @@ -46,7 +46,7 @@ java_library( ], deps = [ '//lib:gson', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = ['PUBLIC'], ) @@ -57,7 +57,7 @@ java_test( deps = [ ':server', '//lib:junit', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], source_under_test = [':server'], visibility = ['//tools/eclipse:classpath'], diff --git a/gerrit-pgm/BUCK b/gerrit-pgm/BUCK index 8ea8eabb91..0737c44264 100644 --- a/gerrit-pgm/BUCK +++ b/gerrit-pgm/BUCK @@ -17,7 +17,7 @@ BASE_JETTY_DEPS = [ '//lib/guice:guice-servlet', '//lib/log:api', '//lib/log:log4j', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ] DEPS = BASE_JETTY_DEPS + [ @@ -176,8 +176,8 @@ java_test( '//lib:junit', '//lib/easymock:easymock', '//lib/guice:guice', - '@jgit//:jgit', - '@jgit//:junit', + '@jgit//org.eclipse.jgit:jgit', + '@jgit//org.eclipse.jgit.junit:junit', ], source_under_test = [':pgm'], ) diff --git a/gerrit-plugin-api/BUCK b/gerrit-plugin-api/BUCK index fa90b884b3..3ef4fdb94d 100644 --- a/gerrit-plugin-api/BUCK +++ b/gerrit-plugin-api/BUCK @@ -42,7 +42,7 @@ java_library( '//lib/joda:joda-time', '//lib/log:api', '//lib/mina:sshd', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = ['PUBLIC'], ) diff --git a/gerrit-prettify/BUCK b/gerrit-prettify/BUCK index b4d0844b9c..baaf56def2 100644 --- a/gerrit-prettify/BUCK +++ b/gerrit-prettify/BUCK @@ -44,7 +44,7 @@ java_library( '//gerrit-reviewdb:server', '//lib:guava', '//lib:gwtjsonrpc', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = ['PUBLIC'], ) diff --git a/gerrit-server/BUCK b/gerrit-server/BUCK index 3fc4580f35..4876137201 100644 --- a/gerrit-server/BUCK +++ b/gerrit-server/BUCK @@ -70,8 +70,8 @@ java_library( '//lib/ow2:ow2-asm-tree', '//lib/ow2:ow2-asm-util', '//lib/prolog:runtime', - '@jgit//:jgit', - '@jgit//:jgit-archive', + '@jgit//org.eclipse.jgit:jgit', + '@jgit//org.eclipse.jgit.archive:jgit-archive', ], provided_deps = [ '//lib:servlet-api-3_1', @@ -102,8 +102,8 @@ TESTUTIL_DEPS = [ '//lib/log:api', '//lib/log:impl_log4j', '//lib/log:log4j', - '@jgit//:jgit', - '@jgit//:junit', + '@jgit//org.eclipse.jgit:jgit', + '@jgit//org.eclipse.jgit.junit:junit', ] TESTUTIL = glob([ diff --git a/gerrit-sshd/BUCK b/gerrit-sshd/BUCK index fa45746552..e8db32b0dc 100644 --- a/gerrit-sshd/BUCK +++ b/gerrit-sshd/BUCK @@ -28,8 +28,8 @@ java_library( '//lib/log:log4j', '//lib/mina:core', '//lib/mina:sshd', - '@jgit//:jgit', - '@jgit//:jgit-archive', + '@jgit//org.eclipse.jgit:jgit', + '@jgit//org.eclipse.jgit.archive:jgit-archive', ], provided_deps = [ '//lib/bouncycastle:bcpkix', diff --git a/gerrit-util-http/BUCK b/gerrit-util-http/BUCK index 328e7a4cc7..32948511bd 100644 --- a/gerrit-util-http/BUCK +++ b/gerrit-util-http/BUCK @@ -15,7 +15,7 @@ java_library( '//lib:guava', '//lib:servlet-api-3_1', '//lib/httpcomponents:httpclient', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], visibility = ['PUBLIC'], ) diff --git a/gerrit-war/BUCK b/gerrit-war/BUCK index 71ce2c65eb..b1f0487008 100644 --- a/gerrit-war/BUCK +++ b/gerrit-war/BUCK @@ -24,7 +24,7 @@ java_library( '//lib/guice:guice', '//lib/guice:guice-servlet', '//lib/log:api', - '@jgit//:jgit', + '@jgit//org.eclipse.jgit:jgit', ], provided_deps = ['//lib:servlet-api-3_1'], visibility = [ diff --git a/lib/JGIT_VERSION b/lib/JGIT_VERSION new file mode 100644 index 0000000000..37b99a6fa8 --- /dev/null +++ b/lib/JGIT_VERSION @@ -0,0 +1,4 @@ +include_defs('//lib/maven.defs') + +REPO = MAVEN_CENTRAL # Leave here even if set to MAVEN_CENTRAL. +VERS = '4.2.0.201601211800-r' diff --git a/lib/jgit/.buckconfig b/lib/jgit/.buckconfig index 267958f322..e67976e829 100644 --- a/lib/jgit/.buckconfig +++ b/lib/jgit/.buckconfig @@ -1,3 +1,7 @@ [cache] mode = dir dir = ~/.gerritcodereview/buck-cache/locally-built-artifacts + +[repositories] + jgit = . + diff --git a/lib/jgit/BUCK b/lib/jgit/BUCK deleted file mode 100644 index bf3e2a8201..0000000000 --- a/lib/jgit/BUCK +++ /dev/null @@ -1,65 +0,0 @@ -include_defs('//lib/maven.defs') - -REPO = MAVEN_CENTRAL # Leave here even if set to MAVEN_CENTRAL. -VERS = '4.2.0.201601211800-r' - -maven_jar( - name = 'jgit', - id = 'org.eclipse.jgit:org.eclipse.jgit:' + VERS, - bin_sha1 = 'a042910b86546a9d8f8aee745e5f8e80104e386d', - src_sha1 = '3224099036bc3396f9ad611bc22f72fa1d126685', - license = 'jgit', - repository = REPO, - unsign = True, - deps = [':ewah'], - exclude = [ - 'META-INF/eclipse.inf', - 'about.html', - 'plugin.properties', - ], -) - -maven_jar( - name = 'jgit-servlet', - id = 'org.eclipse.jgit:org.eclipse.jgit.http.server:' + VERS, - sha1 = '33392946493bb1ff54f843843424022e8c8213e9', - license = 'jgit', - repository = REPO, - deps = [':jgit'], - unsign = True, - exclude = [ - 'about.html', - 'plugin.properties', - ], -) - -maven_jar( - name = 'jgit-archive', - id = 'org.eclipse.jgit:org.eclipse.jgit.archive:' + VERS, - sha1 = 'e599670a9b163182868e2e928e44eb93c5d2b1ab', - license = 'jgit', - repository = REPO, - deps = [':jgit'], - unsign = True, - exclude = [ - 'about.html', - 'plugin.properties', - ], - ) - -maven_jar( - name = 'junit', - id = 'org.eclipse.jgit:org.eclipse.jgit.junit:' + VERS, - sha1 = '215b322b5e37ff6731bc23794772346eb4e3d9c0', - license = 'DO_NOT_DISTRIBUTE', - repository = REPO, - unsign = True, - deps = [':jgit'], -) - -maven_jar( - name = 'ewah', - id = 'com.googlecode.javaewah:JavaEWAH:0.7.9', - sha1 = 'eceaf316a8faf0e794296ebe158ae110c7d72a5a', - license = 'Apache2.0', -) diff --git a/lib/jgit/lib/JGIT_VERSION b/lib/jgit/lib/JGIT_VERSION new file mode 120000 index 0000000000..d52b3f9c3c --- /dev/null +++ b/lib/jgit/lib/JGIT_VERSION @@ -0,0 +1 @@ +../../JGIT_VERSION \ No newline at end of file diff --git a/lib/jgit/org.eclipse.jgit.archive/BUCK b/lib/jgit/org.eclipse.jgit.archive/BUCK new file mode 100644 index 0000000000..c92cf9196f --- /dev/null +++ b/lib/jgit/org.eclipse.jgit.archive/BUCK @@ -0,0 +1,16 @@ +include_defs('//lib/maven.defs') +include_defs('//lib/JGIT_VERSION') + +maven_jar( + name = 'jgit-archive', + id = 'org.eclipse.jgit:org.eclipse.jgit.archive:' + VERS, + sha1 = 'e599670a9b163182868e2e928e44eb93c5d2b1ab', + license = 'jgit', + repository = REPO, + deps = ['@jgit//org.eclipse.jgit:jgit'], + unsign = True, + exclude = [ + 'about.html', + 'plugin.properties', + ], + ) diff --git a/lib/jgit/org.eclipse.jgit.http.server/BUCK b/lib/jgit/org.eclipse.jgit.http.server/BUCK new file mode 100644 index 0000000000..02a9271151 --- /dev/null +++ b/lib/jgit/org.eclipse.jgit.http.server/BUCK @@ -0,0 +1,16 @@ +include_defs('//lib/maven.defs') +include_defs('//lib/JGIT_VERSION') + +maven_jar( + name = 'jgit-servlet', + id = 'org.eclipse.jgit:org.eclipse.jgit.http.server:' + VERS, + sha1 = '33392946493bb1ff54f843843424022e8c8213e9', + license = 'jgit', + repository = REPO, + deps = ['@jgit//org.eclipse.jgit:jgit'], + unsign = True, + exclude = [ + 'about.html', + 'plugin.properties', + ], +) diff --git a/lib/jgit/org.eclipse.jgit.junit/BUCK b/lib/jgit/org.eclipse.jgit.junit/BUCK new file mode 100644 index 0000000000..8536d007be --- /dev/null +++ b/lib/jgit/org.eclipse.jgit.junit/BUCK @@ -0,0 +1,12 @@ +include_defs('//lib/maven.defs') +include_defs('//lib/JGIT_VERSION') + +maven_jar( + name = 'junit', + id = 'org.eclipse.jgit:org.eclipse.jgit.junit:' + VERS, + sha1 = '215b322b5e37ff6731bc23794772346eb4e3d9c0', + license = 'DO_NOT_DISTRIBUTE', + repository = REPO, + unsign = True, + deps = ['@jgit//org.eclipse.jgit:jgit'], +) diff --git a/lib/jgit/org.eclipse.jgit/BUCK b/lib/jgit/org.eclipse.jgit/BUCK new file mode 100644 index 0000000000..4fb59e9c1d --- /dev/null +++ b/lib/jgit/org.eclipse.jgit/BUCK @@ -0,0 +1,25 @@ +include_defs('//lib/maven.defs') +include_defs('//lib/JGIT_VERSION') + +maven_jar( + name = 'jgit', + id = 'org.eclipse.jgit:org.eclipse.jgit:' + VERS, + bin_sha1 = 'a042910b86546a9d8f8aee745e5f8e80104e386d', + src_sha1 = '3224099036bc3396f9ad611bc22f72fa1d126685', + license = 'jgit', + repository = REPO, + unsign = True, + deps = [':ewah'], + exclude = [ + 'META-INF/eclipse.inf', + 'about.html', + 'plugin.properties', + ], +) + +maven_jar( + name = 'ewah', + id = 'com.googlecode.javaewah:JavaEWAH:0.7.9', + sha1 = 'eceaf316a8faf0e794296ebe158ae110c7d72a5a', + license = 'Apache2.0', +)