Skip to content

Conversation

@brenzi
Copy link
Contributor

@brenzi brenzi commented Sep 22, 2019

This adds no_std support. (without depending on sgx_tstd)
In order for this to work, I had to fork substrate-primitives and enable crypto primitives.
This also drops dependency on custom runtime crate.

TODO:

@brenzi brenzi requested a review from clangenb September 22, 2019 14:43
@brenzi
Copy link
Contributor Author

brenzi commented Sep 27, 2019

I suggest to merge although example_contract is broken. If someone wants to use it, I've added a hint

@brenzi
Copy link
Contributor Author

brenzi commented Sep 27, 2019

the recent merge commit broke no_std, need to fix this first

@brenzi
Copy link
Contributor Author

brenzi commented Sep 27, 2019

no_std fix works

pub mod xt_primitives;

pub extern crate codec;
pub extern crate log;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Has this been done for a reason?

I made this for issue #16 . This re-exports the dependencies locally. Making them available in the macro via crate::....

Then third parties using substrate-api-client do not need to import the codec and log dependencies

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the reason for removing it is that it breaks no_std

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

try reexporting conditionally, only if in std environment

@clangenb
Copy link
Collaborator

apart from my comment i think this is ready to merge.

@brenzi brenzi merged commit c28e6ae into master Oct 3, 2019
@brenzi brenzi deleted the no_std_rstd branch October 3, 2019 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants