Skip to content

ekiden/contract-evm

Repository files navigation

EVM contract (currently just implements old ethtoken contract)

CircleCI

Checking out

The repository uses submodules so be sure to check them out by doing:

$ git submodule update --init --recursive

Building the contract

The easiest way to build SGX code is to use the provided scripts, which run a Docker container with all the included tools. This has been tested on MacOS and Ubuntu with SGX_MODE=SIM.

To start the SGX development container:

$ ./ekiden/scripts/sgx-enter.sh

Ekiden uses cargo-make as the build system. The development Docker container already comes with cargo-make preinstalled.

First, build Ekiden to get the correct core contracts. This is currently needed because the core contracts are not yet finalized and it is important that correct hashes are used. You can do that by running:

$ cd ekiden
$ cargo make
$ cd ..

After the process completes, to build everything required for running Ekiden, simply run the following in the top-level directory:

$ cargo make

For subsequent rebuilds, you only need to perform this step while rebuilding Ekiden is not required.

This should install any required dependencies and build all packages. By default SGX code is built in simulation mode. To change this, do export SGX_MODE=HW (currently untested) before running the cargo make command.

The built contract will be stored under target/enclave/evm.signed.so.

Building the example client

The example client is located under /client and it may be built using:

$ cd client
$ cargo build

Running the contract

For running the built contract consult the Ekiden documentation.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •