Prerequisites
- Java 17 (soon to be Java 21 - see changelog21 (NEW since https://github.com/hyperledger/besu/pull/7177)
- For Mac installations: MacOS High Sierra 10.13 or later
...
- For Windows:
...
- Besu is currently supported only on 64-bit versions of Windows, and requires a 64-bit version of JDK/JRE. We recommend that you also remove any 32-bit JDK/JRE installations.
Dependency
Dependencies
There are two dependencies required if you want to run the tests: libsodium version Building from source has a two dependencies- libsodium version 1.0.16 or higher and libnss version 3.35 or higher are needed in order to build Besu and run the tests.
If you are not planning on running the tests, you can skip this step.
To install the dependencies type in the following commands on MacOS or Ubuntu.
...
The `sudo` command might be needed on Linux, and if the screen prompts you to enter a password, type your password and press enter.
...
git clone --recursive https://github.com/hyperledger/besu
cd besu
./gradlew build
./gradlew integrationTest LTS
Checkout source code
git clone --recursive git@github.com:hyperledger/besu.git
...
cd besu
./gradlew tasks
Build from source
Note: On Windows, to run gradlew
, you must have the JAVA_HOME system variable set to the Java installation directory. For example: JAVA_HOME = C:\Program Files\Java\jdk1.8.0_181
Build the distribution binaries:
cd besu
./gradlew installDist
Run Besu to see help menu:
cd build\/install\/besu
./bin/besu --help
Running Developer Builds
Build and run Run Besu with default options using:
./gradlew installDist
By (by default this stores all persistent data in build/install/besu
):
cd build/install/besu
./bin/besu
To set custom CLI arguments for the Besu executionoptions:
cd build/install/besu
./bin/besu --discovery-enabled=false --data-path=/tmp/besutmp
Running tests
git clone --recursive https://github.com/hyperledger/besu
cd besu
./gradlew build
./gradlew integrationTest LTS
Building and Running on Windows
Note: On Windows, to run gradlew, you must have the JAVA_HOME system variable set to the Java installation directory. For example:
JAVA_HOME = C:\Program Files\Java\jdk21.0_181
Note: If you are using WSL (Windows Subsystem for Linux) with Ubuntu to build and run Besu using DNS discovery, you might need to change the default DNS provided by Windows. See issue https://github.com/hyperledger/besu/issues/3046 for more detail.