X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcold%2Fshared.lisp;h=985a444d1bfba4372857fbf3ff99c4f8a57ae147;hb=3eb39e017e52b5d704e7d33405c873af52a533fd;hp=f17fedf2034ef2b071973a32a1e6e22c4f4f33be;hpb=e8f173ff44bc069db48585c8844f2d1097bb47d2;p=sbcl.git diff --git a/src/cold/shared.lisp b/src/cold/shared.lisp index f17fedf..985a444 100644 --- a/src/cold/shared.lisp +++ b/src/cold/shared.lisp @@ -151,16 +151,29 @@ (when (probe-file obj) (delete-file obj)) - ;; Work around a bug in CLISP 1999-01-08 #'COMPILE-FILE: CLISP - ;; mangles relative pathnames passed as :OUTPUT-FILE arguments, - ;; but works OK with absolute pathnames. - #+clisp + ;; Original comment: + ;; + ;; Work around a bug in CLISP 1999-01-08 #'COMPILE-FILE: CLISP + ;; mangles relative pathnames passed as :OUTPUT-FILE arguments, + ;; but works OK with absolute pathnames. + ;; + ;; following discussion on cmucl-imp 2002-07 + ;; "COMPILE-FILE-PATHNAME", it would seem safer to deal with + ;; absolute pathnames all the time; it is no longer clear that the + ;; original behaviour in CLISP was wrong or that the current + ;; behaviour is right; and in any case absolutifying the pathname + ;; insulates us against changes of behaviour. -- CSR, 2002-08-09 (setf tmp-obj ;; (Note that this idiom is taken from the ANSI ;; documentation for TRUENAME.) (with-open-file (stream tmp-obj :direction :output) (close stream) (truename stream))) + ;; and some compilers (e.g. OpenMCL) will complain if they're + ;; asked to write over a file that exists already (and isn't + ;; recognizeably a fasl file), so + (when (probe-file tmp-obj) + (delete-file tmp-obj)) ;; Try to use the compiler to generate a new temporary object file. (flet ((report-recompile-restart (stream)