diff --git a/README.md b/README.md index 718c738..5e36cf5 100644 --- a/README.md +++ b/README.md @@ -4,16 +4,22 @@ This tool allows for validation of targets (e.g. Firedancer) against Solana Agav ## Requirements -This tool only works on RHEL8. +This tool works on RHEL8 or Ubuntu. ## Installation -Clone this repository and run: +Clone this repository and, for RHEL8, run: ```sh source install.sh ``` +For Ubuntu, run: + +```sh +source install_ubuntu.sh +``` + ### Install auto-completion ```sh diff --git a/impl/.gitignore b/impl/.gitignore index ad4fc39..e4dee90 100644 --- a/impl/.gitignore +++ b/impl/.gitignore @@ -1,3 +1,4 @@ agave-v1.17 agave-v2.0 +agave-v2.1.0 firedancer diff --git a/install_ubuntu.sh b/install_ubuntu.sh new file mode 100755 index 0000000..f412f5f --- /dev/null +++ b/install_ubuntu.sh @@ -0,0 +1,27 @@ +# Install the toolkit on Ubuntu. + +# Clone repositories. +cd impl +git clone http://github.com/firedancer-io/firedancer.git +git clone -b agave-v1.17 http://github.com/firedancer-io/solfuzz-agave.git agave-v1.17 +git clone -b agave-v2.0 http://github.com/firedancer-io/solfuzz-agave.git agave-v2.0 +git clone -b agave-v2.1.0 http://github.com/firedancer-io/solfuzz-agave.git agave-v2.1.0 +cd .. + +# Configure GCC. +sudo apt install -y build-essential software-properties-common +sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test +sudo apt update +sudo apt install -y gcc-12 g++-12 +sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 20 +sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-12 20 + +# Configure Python virtual environment. +sudo apt install -y python3.11 python3.11-dev python3.11-venv +python3.11 -m venv test_suite_env +source test_suite_env/bin/activate + +# Bootstrap environment. +make -j -C impl +pip install -e ".[dev]" +pre-commit install diff --git a/install_ubuntu_lite.sh b/install_ubuntu_lite.sh new file mode 100755 index 0000000..715a973 --- /dev/null +++ b/install_ubuntu_lite.sh @@ -0,0 +1,18 @@ +# Install the toolkit on Ubuntu without cloning targets. + +# Configure GCC. +sudo apt install -y build-essential software-properties-common +sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test +sudo apt update +sudo apt install -y gcc-12 g++-12 +sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 20 +sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-12 20 + +# Configure Python virtual environment. +sudo apt install -y python3.11 python3.11-dev python3.11-venv +python3.11 -m venv test_suite_env +source test_suite_env/bin/activate + +# Bootstrap environment. +pip install -e ".[dev]" +pre-commit install