chiark / gitweb /
72a555900f4083b227d75f19a3642bf8216ebd89
[clg] / gffi / gffi.asd
1 ;;; -*- Mode: lisp -*-
2
3 (asdf:oos 'asdf:load-op :clg-tools)
4
5 (defpackage "GFFI-SYSTEM"
6   (:use "COMMON-LISP" "ASDF" "PKG-CONFIG"))
7
8 #+cmu(ext:unlock-all-packages)
9 #+sbcl
10 (progn
11   (sb-ext:unlock-package "COMMON-LISP")
12   (sb-ext:unlock-package "SB-PCL"))
13
14 (in-package "GFFI-SYSTEM")
15
16
17 #+(and sbcl (not alien-callbacks))
18 (eval-when (:compile-toplevel :load-toplevel :execute)
19   (unless (find-symbol "DEFINE-ALIEN-FUNCTION" "SB-ALIEN")
20     (error "You need to upgrade SBCL to a version with native C callback support or see the README file about how to add third party callbacks to your current SBCL version.")))
21
22 #+(and sbcl alien-callbacks)
23 (eval-when (:compile-toplevel :load-toplevel :execute)
24   (when (find-symbol "DEFINE-ALIEN-FUNCTION" "SB-ALIEN")
25     (error "Third party C callback code detected in a SBCL image with native callback support. As clg now uses native callbacks when available, you need to use a \"clean\" core file.")))
26
27
28 (defsystem gffi
29     :depends-on (clg-tools)
30     :components ((:file "defpackage")
31                  #+(and cmu19a (not non-broken-pcl))(:file "pcl")
32                  (:unix-dso "alien" :components ((:c-source-file "memory")))
33                  (:file "memory" :depends-on ("defpackage"))
34                  (:file "interface" :depends-on ("memory"))
35                  (:file "basic-types" :depends-on ("alien" "interface"))
36                  (:file "vectors" :depends-on ("basic-types"))
37                  (:file "enums" :depends-on ("basic-types"))
38                  (:file "virtual-slots" :depends-on (#+(and cmu19a (not non-broken-pcl))"pcl" "interface" "basic-types"))
39                  (:file "proxy" :depends-on ("virtual-slots"))))