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

why does the usage of graphene in DEBUG mode needs driver? #924

Closed
sammyne opened this issue Aug 15, 2019 · 2 comments

Comments

@sammyne
Copy link

commented Aug 15, 2019

I want to develop app based on graphene in localhost without SGX support. When using the original SGX SDK, it's would be fine without SGX driver installed.

So is it possible to remove the dependencies on SGX drivers to ease local development?

I run on my SGX-enabled machine with SGX SDK 2.5 and SGX Driver 2.5, still got

In file included from sgx_framework.c:6:0:
sgx-driver/graphene-sgx.h:8:26: fatal error: isgx_version.h: No such file or directory
compilation terminated.
Makefile:58: recipe for target 'sgx_framework.o' failed
make[3]: *** [sgx_framework.o] Error 1
make[3]: Leaving directory '/home/block01/Workspaces/lixiangmin01/graphene/Pal/src/host/Linux-SGX'
Makefile:95: recipe for target 'host_lib_recurse' failed
make[2]: *** [host_lib_recurse] Error 2
make[2]: Leaving directory '/home/block01/Workspaces/lixiangmin01/graphene/Pal/src'
Makefile:7: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/home/block01/Workspaces/lixiangmin01/graphene/Pal'
Makefile:8: recipe for target 'all' failed
make: *** [all] Error 2

Any help would be greatly appreciated~

@dimakuv

This comment has been minimized.

Copy link
Contributor

commented Aug 15, 2019

Replies for your two questions:

  1. It is currently not possible to run Graphene-SGX in simulation mode. Graphene-SGX always has to run on an SGX-enabled machine. There are two solutions for your problem: (a) use Graphene with Linux PAL (i.e., build and run without SGX=1), or (b) develop and build on your local non-SGX machine, then copy the produced binaries and run them on an SGX-enabled machine.

In general, it is not obvious why Graphene-SGX in simulation mode would be useful. If you are deploying your applications on top of Graphene, you can always try your application in non-SGX (normal Linux PAL) mode. If you need to change/use something specific to SGX, then it only makes sense to develop on an SGX-enabled machine.

  1. For you build error, it looks like you forgot to build a Graphene SGX driver: see Step 4 in https://github.com/oscarlab/graphene/wiki/SGX-Quick-Start.
@mkow

This comment has been minimized.

Copy link
Contributor

commented Oct 2, 2019

No reply from the author, closing.

@mkow mkow closed this Oct 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.