我保存了这个简单的程序。
使用
(defun hello-world ()
(format t "Hello, world"))
(defun main ()
(hello-world))
使用
ccl:save-application
命令来保存应用程序。(ccl:save-application "test"
:toplevel-function #'main
:prepend-kernel t
:purify t
:impurify t)
从Clozure Common Lisp REPL中运行。
在Mac OS X上,生成的可执行文件大小为25M。我知道它包含了Lisp内核和Lisp系统的内存表示。但是对于这样一个简单的程序来说,25M似乎有点大。参数purify
和impurify
似乎没有太大的影响。
我有什么选项可以减小可执行文件的大小吗?有吗?