Make INFO's compiler-macro more forgiving.
[sbcl.git] / contrib / sb-mpfr / sb-mpfr.asd
blob181fbd107d01ae7e266bac97fc5b5145fbd5c967
1 (defpackage #:sb-mpfr-system (:use #:asdf #:cl))
3 (in-package #:sb-mpfr-system)
5 (defsystem sb-mpfr
6   :name "SB-MPFR"
7   :version "0.1"
8   :description "bignum float calculations for SBCL using the MPFR library"
9   :serial t
10   :depends-on (sb-gmp)
11   :components ((:module sb-mpfr
12                 :pathname ""
13                 :components ((:file "mpfr")))))
15 (defsystem sb-mpfr-tests
16   :depends-on (sb-rt sb-mpfr)
17   :components ((:file "tests")))
19 (defmethod perform :after ((o load-op) (c (eql (find-system :sb-mpfr))))
20   (provide 'sb-mpfr))
22 (defmethod perform ((o test-op) (c (eql (find-system :sb-mpfr))))
23   (operate 'load-op 'sb-mpfr)
24   (cond ((member :sb-mpfr *features*)
25          (operate 'load-op 'sb-mpfr-tests)
26          (operate 'test-op 'sb-mpfr-tests))
27         (t
28          (warn "unable to test sb-mpfr: libmpfr unavailable"))))
30 (defmethod perform ((o test-op) (c (eql (find-system :sb-mpfr-tests))))
31   (multiple-value-bind (soft strict pending)
32       (funcall (intern "DO-TESTS" (find-package "SB-RT")))
33     (declare (ignorable pending))
34     (fresh-line)
35     (unless strict
36       (warn "ignoring expected failures in sb-mpfr-tests"))
37     (unless soft
38       (error "sb-mpfr-tests failed with unexpected failures"))))