Catch errors while trying to compile plugins.
A warning with the full error message will be printed and the original file `LOAD`ed instead. If the error isn't related to the `fasl` file output, then the `LOAD` should also throw an error, at which point the normal error handling would take place.
This commit is contained in:
parent
9c4dd4162b
commit
68ee3c942d
1 changed files with 5 additions and 1 deletions
|
@ -53,7 +53,11 @@
|
|||
(plugin-package (sym)
|
||||
(format nil "~:@(coleslaw-~A~)" sym)))
|
||||
(let ((file (plugin-path name)))
|
||||
(load (compile-file file :verbose nil :print nil) :verbose t))
|
||||
(multiple-value-bind (output-file error)
|
||||
(ignore-errors (compile-file file :verbose nil :print nil))
|
||||
(when error
|
||||
(warn "Error while compiling plugin ~A: ~A.~%" name error))
|
||||
(load (or output-file file) :verbose t)))
|
||||
(let ((package (find-package (plugin-package name))))
|
||||
(apply (find-symbol "ENABLE" package) args))))
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue