1 ;;;; -*- Mode: LISP; Syntax: ANSI-Common-Lisp; Base: 10 -*-
2 ;;;; *************************************************************************
3 ;;;; FILE IDENTIFICATION
6 ;;;; Purpose: ASDF System definition for CLSQL
7 ;;;; Authors: Marcus Pearce and Kevin M. Rosenberg
8 ;;;; Created: March 2004
10 ;;;; CLSQL users are granted the rights to distribute and use this software
11 ;;;; as governed by the terms of the Lisp Lesser GNU Public License
12 ;;;; (http://opensource.franz.com/preamble.html), also known as the LLGPL.
13 ;;;; *************************************************************************
15 (in-package #:cl-user)
16 (defpackage #:clsql-system (:use #:asdf #:cl))
17 (in-package #:clsql-system)
19 #+(and clisp (not :clsql-cffi))
20 (asdf:operate 'asdf:load-op 'clsql-cffi)
22 ;; need to load uffi for below perform :after method
23 (eval-when (:compile-toplevel :load-toplevel :execute)
25 (unless (find-package 'cffi-uffi-compat)
27 (ql:quickload :cffi-uffi-compat)
29 (asdf:operate 'asdf:load-op 'cffi-uffi-compat))
31 (unless (find-package 'uffi)
32 (asdf:operate 'asdf:load-op 'uffi)))
36 :author "Kevin Rosenberg <kevin@rosenberg.net>"
37 :maintainer "Kevin M. Rosenberg <kmr@debian.org>"
38 :licence "Lessor Lisp General Public License"
39 :description "Common Lisp SQL Interface library"
40 :long-description "A Common Lisp interface to SQL RDBMS based on
41 the Xanalys CommonSQL interface for Lispworks. It provides low-level
42 database interfaces as well as a functional and an object
51 ((:file "cmucl-compat")
53 (:file "kmr-mop" :depends-on ("package"))
54 (:file "base-classes" :depends-on ("package"))
55 (:file "conditions" :depends-on ("base-classes"))
56 (:file "db-interface" :depends-on ("conditions"))
57 (:file "decimals" :depends-on ("package" "db-interface"))
58 (:file "utils" :depends-on ("package" "db-interface"))
59 (:file "time" :depends-on ("package" "conditions" "utils"))
60 (:file "generics" :depends-on ("package"))))
65 (:file "database" :depends-on ("initialize"))
66 (:file "recording" :depends-on ("database"))
67 (:file "pool" :depends-on ("database")))
71 :components ((:file "expressions")
73 :depends-on ("expressions"))
74 (:file "syntax" :depends-on ("operations")))
75 :depends-on (database))
78 :components ((:file "fdml")
79 (:file "transaction" :depends-on ("fdml"))
80 #+clisp (:file "ansi-loop")
81 (:file "loop-extension"
82 :depends-on ("fdml" #+clisp "ansi-loop"))
83 (:file "fddl" :depends-on ("fdml")))
87 :components ((:file "metaclasses")
88 (:file "ooddl" :depends-on ("metaclasses"))
89 (:file "oodml" :depends-on ("ooddl")))
90 :depends-on (functional))
93 :components ((:file "generic-postgresql")
94 (:file "generic-odbc")
96 (:file "command-object"))
97 :depends-on (functional)))))
98 :in-order-to ((test-op (test-op "clsql-tests"))))
100 (defmethod perform :after ((o load-op) (c (eql (find-system 'clsql))))
101 (let* ((init-var (uffi::getenv "CLSQLINIT"))
102 (init-file (or (when init-var (probe-file init-var))
105 (namestring (user-homedir-pathname))
107 (probe-file "/etc/clsql-init.lisp")
108 #+(or mswin windows win32 win64 mswindows)
109 (probe-file "c:\\etc\\clsql-init.lisp"))))
110 (when init-file (load init-file))))