Set the deliver keyword :keep-clos to t or :no-empty to keep the code needed for dynamic definition in the image.
deliver
:keep-clos
t
:no-empty