(with-open-file (s "sample.txt" :direction input :external-format :gbk) (read-line s nil nil nil))
首先在sbcl环境中使用save-lisp-and-die函数
(defun hello () (format t "hello world~%")) (sb-ext:save-lisp-and-die "hello.exe" :toplevel #'hello :executable t)在命令行中执行hello.exe会显示:
This is experimental prerelease support for the Windows platform: use at your own risk. "Your Kitten of Death awaits!" Hello world!这里的警告信息可以通过修改源代码的形式去掉,如果需要的话。