Files
gerrit/lib/commons/BUCK
Shawn Pearce fd6bb9f6a5 Build with Buck
Implement a new build system using Buck[1], Facebook's
open source clone of Google's internal build system.

  Pros:
  - Concise build language
  - Test and build output is concise
  - Test failures and stack traces show on terminal
  - Reliable incrementals; clean is unnecessary
  - Extensible with simple blocks of Python
  - Fast
      buck: clean: 0.452s, full 1m21.083s [*], no-op:  7.145s,
      mvn:  clean: 4.596s, full 2m53.776s,     no-op: 59.108s,

      [*] full build includes downloading all dependencies,
          time can vary due to remote server performance.

  Cons:
  - No Windows support
  - No native Maven Central support (added by macros)
  - No native GWT, Prolog, or WAR support (added by macros)
  - Bootstrap of buck requires Ant

Getting started:

  git clone https://gerrit.googlesource.com/buck
  cd buck
  ant

  Mac OS X:
    PATH="`pwd`/bin:/System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands:$PATH"

  Linux:
    PATH="`pwd`/bin:$PATH"

Importing into Eclipse:

  $ time buck build :eclipse
  0m48.949s

  Import existing project from `pwd`
  Import 'gerrit' (do not import other Maven based projects)
  Expand 'gerrit'
  Right click 'buck-out' > Properties
  Under Attributes check 'Derived'

  If the code doesn't currently compile but an updated classpath
  is needed, refresh the configs and obtain missing JARs:

  $ buck build :eclipse_project :download

Running JUnit tests:

  $ time buck test --all -e slow  # skip slow tests
  0m19.320s

  $ time buck test --all          # includes acceptance tests
  5m17.517s

Building WAR:

  $ buck build :gerrit
  $ java -jar buck-out/gen/gerrit.war

Building release:

  $ buck test --all && buck build :api :release
  $ java -jar buck-out/gen/release.war
  $ ls -lh buck-out/gen/{extension,plugin}-api.jar

Downloading dependencies:

  Dependencies are normally downloaded automatically, but Buck can
  inspect its graph and download missing dependencies so future
  compiles can run without the network:

  $ buck build :download

[1] http://facebook.github.io/buck/

Change-Id: I40853b108bd8e153cefa0896a5280a9a5ff81655
2013-05-09 13:40:36 +00:00

80 lines
1.9 KiB
Python

include_defs('//lib/maven.defs')
maven_jar(
name = 'codec',
id = 'commons-codec:commons-codec:1.4',
sha1 = '4216af16d38465bbab0f3dff8efa14204f7a399a',
license = 'Apache2.0',
exclude = ['META-INF/LICENSE.txt', 'META-INF/NOTICE.txt'],
)
maven_jar(
name = 'collections',
id = 'commons-collections:commons-collections:3.2.1',
sha1 = '761ea405b9b37ced573d2df0d1e3a4e0f9edc668',
license = 'Apache2.0',
exclude = ['META-INF/LICENSE.txt', 'META-INF/NOTICE.txt'],
attach_source = False,
visibility = ['//lib:velocity'],
)
maven_jar(
name = 'dbcp',
id = 'commons-dbcp:commons-dbcp:1.4',
sha1 = '30be73c965cc990b153a100aaaaafcf239f82d39',
license = 'Apache2.0',
deps = [':pool'],
exclude = [
'META-INF/LICENSE.txt',
'META-INF/NOTICE.txt',
'testpool.jocl'
],
)
maven_jar(
name = 'lang',
id = 'commons-lang:commons-lang:2.5',
sha1 = 'b0236b252e86419eef20c31a44579d2aee2f0a69',
license = 'Apache2.0',
exclude = ['META-INF/LICENSE.txt', 'META-INF/NOTICE.txt'],
)
maven_jar(
name = 'logging',
id = 'commons-logging:commons-logging:1.1.1',
sha1 = '5043bfebc3db072ed80fbd362e7caf00e885d8ae',
license = 'Apache2.0',
exclude = [
'META-INF/LICENSE',
'META-INF/NOTICE',
],
attach_source = False,
visibility = ['//lib/openid:'],
)
maven_jar(
name = 'net',
id = 'commons-net:commons-net:2.2',
sha1 = '07993c12f63c78378f8c90de4bc2ee62daa7ca3a',
license = 'Apache2.0',
exclude = ['META-INF/LICENSE.txt', 'META-INF/NOTICE.txt'],
)
maven_jar(
name = 'pool',
id = 'commons-pool:commons-pool:1.5.5',
sha1 = '7d8ffbdc47aa0c5a8afe5dc2aaf512f369f1d19b',
license = 'Apache2.0',
attach_source = False,
exclude = ['META-INF/LICENSE.txt', 'META-INF/NOTICE.txt'],
)
maven_jar(
name = 'oro',
id = 'oro:oro:2.0.8',
sha1 = '5592374f834645c4ae250f4c9fbb314c9369d698',
license = 'Apache1.1',
attach_source = False,
exclude = ['META-INF/LICENSE'],
)