sgx: script improvements

Signed-off-by: Robert Nelson <robertcnelson@gmail.com>