This section explains how to keep packages and symbols in the application when Delivery would otherwise remove them.
You can protect these packages with :packages-to-keep. All packages in the list passed with this keyword are kept in the delivered image, regardless of the state of the :smash-packages and :delete-packages keywords. If you pass :packages-to-keep
:all, then the two variables are set to
COMMON-LISP is the package your application is most likely to rely on, and it is also very large. Keeping it has a very noticeable effect on the size of the application. However, if your application uses
load, it invites the possibility of reading arbitrary code, and so
COMMON-LISP must be kept.
This is the recommended solution in most circumstances. See :keep-symbols.
This solution is suitable when all the symbols to keep are in one package,
FOO-PKG say. Pass
(list "FOO-PKG"). See :never-shake-packages.
You can override this behavior by passing
deliver. See :shake-externals.
Note: If you need to retain the names of the symbols if the symbols themselves are not shaken out, use deliver-keep-symbol-names. This is useful when the symbol name is used as long the symbol is used.
LispWorks Delivery User Guide - 10 Aug 2017