Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crate to link and/or build SGX SDK #7

Open
nick-mobilecoin opened this issue May 17, 2022 · 0 comments
Open

Crate to link and/or build SGX SDK #7

nick-mobilecoin opened this issue May 17, 2022 · 0 comments

Comments

@nick-mobilecoin
Copy link
Collaborator

nick-mobilecoin commented May 17, 2022

Currently the initial logic is looking for the SGX SDK at /opt/intel/sgxsdk and this logic is repeated in multiple places.
We should have a crate that handles this logic and optionally builds the sdk from source

Ideally there should be 2 options:

  1. Linking to a pre-installed SGX SDK
  2. Building the SGX SDK from source

One thought is to implement something like openssl-sys.
It has a build dependency on openssl-src.
When the vendored feature is enabled the openssl-src crate is built providing the OpenSSL libraries to link to at build time. The find_vendored.rs logic will be used to link the built OpenSSL library.
When vendored is not present then (find_normal.rs)[https://github.com/sfackler/rust-openssl/blob/master/openssl-sys/build/find_normal.rs] will be used to locate the system install of OpenSSL.

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

No branches or pull requests

1 participant