-
Install rustup
-
Set the default rust toolchain to the latest nightly supported by the rust-sgx-sdk
Currently this is
nightly-2020-10-25
. So dorustup default nightly-2020-10-25
-
Install the relevant rust tooling for you IDE/Text editor
- VSCode: plugin on the marketplace I would recommend using rust-analyzer rather than rls. Check the plugin settings for more info
- Jetbrains: Open source plugin for their IDEs
- Other: For any editor with support for the language server protocol, I would recommend using rust analyzer. See the editor's LSP docs for info on how to install
-
For debugging you can use gdb from the interactive shell of the docker environment
For a dev environment, SGX does not need to be setup on the host machine. All building will happen inside of the docker container, and simulation mode should be fine for most cases. If you want to use the hardware capabilities you can install the SGX driver and pass through the device when starting the docker container.
Use docker-compose run dev
to start the dev container. This will put you in an interactive shell.
To run the application inside of the container, do cd rtc-data
and then ./runall.sh
Check, build, and test everything:
./all.sh
Run tests :
./runtests.sh