- Download the latest version of solx from the Releases page inside your project folder.
- Make the compiler binary executable with
chmod +x solx. - Make sure that the binary name matches with
SOLX_BINARY_FILENAMEin thehardhat.config.tsfile.
⚠️ Thehardhat.config.tsfile has a custom subtask to usesolxif the env variableSOLX_ENABLEDis present. If you want to use a different filename for thesolxbinary, update theSOLX_BINARY_FILENAMEvariable in thehardhat.config.tsfile as well.
- To compile with
solx, set the environment variableSOLX_ENABLEDor compile or test your project withSOLX_ENABLED=1 npx hardhat compile
This project uses hardhat-gas-reporter to generate and save gas reports for both solc and solx.