Commit 2e366958 authored by Robert Goldman's avatar Robert Goldman
Browse files

Improve OS detection.

Replace `:haiku`, `:mezzano`, and `:genera` with `:os-` prefixed
alternatives.  This fixes a problem on SBCL where we were
inadvertently *removing* the `:haiku` feature.

Treat `:haiku` as a unix variant (fix `os-unix-p`).
parent 0c0ac86a
......@@ -41,7 +41,7 @@ keywords explicitly."
(defun os-unix-p ()
"Is the underlying operating system some Unix variant?"
(or (featurep '(:or :unix :cygwin)) (os-macosx-p)))
(or (featurep '(:or :unix :cygwin :haiku)) (os-macosx-p)))
(defun os-windows-p ()
"Is the underlying operating system Microsoft Windows?"
......@@ -69,10 +69,10 @@ except on ABCL where it might change between FASL compilation and runtime."
(loop* :with o
:for (feature . detect) :in '((:os-unix . os-unix-p) (:os-macosx . os-macosx-p)
(:os-windows . os-windows-p)
(:genera . os-genera-p) (:os-oldmac . os-oldmac-p)
(:haiku . os-haiku-p)
(:mezzano . os-mezzano-p))
:when (and (or (not o) (eq feature :os-macosx)) (funcall detect))
(:os-genera . os-genera-p) (:os-oldmac . os-oldmac-p)
(:os-haiku . os-haiku-p)
(:os-mezzano . os-mezzano-p))
:when (and (or (not o) (eq feature :os-macosx) (eq feature :os-haiku)) (funcall detect))
:do (setf o feature) (pushnew feature *features*)
:else :do (setf *features* (remove feature *features*))
:finally
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment