I2P Address: [http://git.idk.i2p]

Skip to content

Draft: Build: vendor instead of bundling some dependencies

tharvik requested to merge tharvik/i2p.i2p:unbundle into master

a bunch of external dependencies are copied inside the project. I wanted to have a clearer and easier for a packager (such as myself) to change theses. this PR introduces a centralized way to define dependencies and put needed jars in there.

  • dependencies/build.xml defines a few properties to easily depend on a given lib
    • can be used via <import file="…/dependencies/build.xml" /> and then referencing wanted ones (for eg. <classpath path="${gettext.jar}" />)
    • can be overridden for system-local dependencies via cmdline props (ant -Dgettext.jar=/…)
  • replace bundled code by jars from maven
    • make it easier to upgrade, and to know which are having security issues
  • taglibs-standard, jstl, gettext, getopt & simple-json were unbundled and replaced by corresponding ${….jar}
  • tests jar (junit, mockito, hamcrest) have also been bundled
    • I wasn't really sure on what's the policy there: do we want i2p to be installable by anyone without clearnet but not testing it? there was already some support for system-local ${junit.home} and ${hamcrest.home} but it doesn't work on some systems
  • this is in fact quite similar to what I'm doing in Gentoo's ebuild (clearnet link)

this works for building and testing. I'm quite sure that I broke the debian packages, and probably a bunch of other things. I didn't wanted to spend too much time unbundling everything before getting some feedback on the general idea. so, WDYT?

Merge request reports

Loading