Build FIO from Source

Download FIO Source

To download the FIO source code, clone the fio repo and its submodules. It is advised to create a home fio folder first and download all the FIO related software there:

mkdir -p ~/fioprotocol && cd ~/fioprotocol
git clone --recursive

Update Submodules

If a repository is cloned without the --recursive flag, the submodules must be updated before starting the build process:

cd ~/fioprotocol/fio
git submodule update --init --recursive

Pull Changes

When pulling changes, especially after switching branches, the submodules must also be updated. This can be achieved with the git submodule command as above, or using git pull directly:

[git checkout <branch>]  (optional)
git pull --recurse-submodules

Build FIO Binaries

The build script first installs all dependencies and then builds FIO. The script supports these Operating Systems. To run it, first change to the ~/fioprotocol/fio folder, then launch the script:

cd ~/fioprotocol/fio/scripts
./ -P

The build process writes temporary content to the fio/build folder. After building, the program binaries can be found at fio/build/programs.

To confirm your clang version, first get the install directory for nodeos (e.g., /usr/local/bin/nodeos):

ps -ef | grep nodeos

Next, insert your nodeos dir in the following command:

strings /usr/local/bin/nodeos |grep -i clang |head -10

Install FIO Binaries

For ease of contract development, content can be installed at the ~/fio folder using the script within the fio/scripts folder. Adequate permission is required to install on system folders:

cd ~/fioprotocol/fio/scripts