Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Moved building with Ant to its own page

...

If you had an open PR in the old GitHub repo, these are gone from the GitHub site. Please submit a new PR against the new repo. If you should want to see information in one of your old PRs, you may send us an email, as we have an export of all old PRs.

Building

...

Solr


Note
titleGradle is the preferred build environment for trunk/Solr9Use Gradle for Solr 9 and Ant for Solr 8 and earlier

Solr has transitioned from Ant to Gradle Solr is transitioning to Gradle rather than Ant as it's build environment.It is not necessary to use Gradle to build trunk/Solr9, but it is preferred as we'd like to get as much feedback as possiblesystem starting with Solr 9. See: Building Solr with Gradle.

Trunk/Solr9 can be built only with either Gradle or Ant. Previous versions of Solr, including all 8x versions can only be built with Ant.

If you're working on trunk code, consider using Gradle. Here's a page to help get started: Building Solr with Gradle. This is still a Work in Progress, so please point out any deficiencies.

No Format

cd lucene-solr
Issue any of the following commands.

'ant -projecthelp ' will show the available build targets

'ant ivy-bootstrap' will install ivy

cd solr

'ant usage' will show the available build targets

'ant server' will build a runnable Solr (note, 'ant example' is the target pre 5.x)

'ant dist' will build the libraries you might want to link against from, say, a SolrJ program.

'ant package' will build files like 'package/solr-5.2.0-SNAPSHOT-src.tgz' which are standard distributions you can install somewhere else just like an official release.

'ant test' will run all of the unit tests. NOTE: this takes quite a while.

NOTE: If your build hangs when building and especially on a "resolve" step, it's probably because there are left over lock files in your ivy directory (often because you crtl-c'd during a build). To fix this navigate to your .ivy2 directory and delete all of the "*.lck" files in the tree. For *nix operating systems, issue a command similar to:
find . -name "*.lck" | xargs rm

...

See: Building Solr with Ant.

Exporting to a local repository

...