Switch to transient DynamicAssembly to support sandbox

DefineDynamicAssembly relies on GetCurrentDirectory() which will fail in the Mac sandbox. NSHomeDirectory() must be used instead. Rather than persisting to disk, this patch makes DynamicAssembly transient when used by the runtime.