occlum/demos/gdb_support/gdb_sample_on_occlum.sh
Hui, Chunyang 85501d8993 Improve implementation for occlum build
This commit mainly accomplish two things:
1. Use makefile to manage dependencies for `occlum build`, which can save lots of time
2. Take dirs `build`, `run` outside from `.occlum`. Remove env var "OCCLUM_INSTANCE_DIR"
2020-08-15 19:12:39 +08:00

15 lines
332 B
Bash
Executable File

#!/bin/bash
set -e
rm -rf occlum_context && mkdir -p occlum_context
cd occlum_context
# 1. Initialize a directory as the Occlum instance
occlum init
# 2. Generate a secure Occlum FS image and Occlum SGX enclave
cp ../sample image/bin
occlum build
# 3. Debug the user program inside an SGX enclave with GDB
occlum gdb /bin/sample