Merge "Buck: Emulate real JGit project structure in its own cell"

This commit is contained in:
Saša Živkov
2016-02-18 15:27:09 +00:00
committed by Gerrit Code Review
25 changed files with 108 additions and 95 deletions

View File

@@ -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(

View File

@@ -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/...',

View File

@@ -9,7 +9,7 @@ java_library(
'//lib:h2',
'//lib/guice:guice',
'//lib/log:api',
'@jgit//:jgit',
'@jgit//org.eclipse.jgit:jgit',
],
visibility = ['PUBLIC'],
)

View File

@@ -46,7 +46,7 @@ java_library(
'//lib:guava',
'//lib/joda:joda-time',
'//lib/log:api',
'@jgit//:jgit',
'@jgit//org.eclipse.jgit:jgit',
],
visibility = ['PUBLIC'],
)

View File

@@ -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'],

View File

@@ -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'],

View File

@@ -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

View File

@@ -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'],
)

View File

@@ -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'],
)

View File

@@ -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'],

View File

@@ -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'],
)

View File

@@ -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'],
)

View File

@@ -44,7 +44,7 @@ java_library(
'//gerrit-reviewdb:server',
'//lib:guava',
'//lib:gwtjsonrpc',
'@jgit//:jgit',
'@jgit//org.eclipse.jgit:jgit',
],
visibility = ['PUBLIC'],
)

View File

@@ -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([

View File

@@ -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',

View File

@@ -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'],
)

View File

@@ -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 = [

4
lib/JGIT_VERSION Normal file
View File

@@ -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'

View File

@@ -1,3 +1,7 @@
[cache]
mode = dir
dir = ~/.gerritcodereview/buck-cache/locally-built-artifacts
[repositories]
jgit = .

View File

@@ -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',
)

1
lib/jgit/lib/JGIT_VERSION Symbolic link
View File

@@ -0,0 +1 @@
../../JGIT_VERSION

View File

@@ -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',
],
)

View File

@@ -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',
],
)

View File

@@ -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'],
)

View File

@@ -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',
)