r10325: * sql/oodml.lisp: Use explicit database in fault-join-target-slot
[clsql.git] / db-sqlite / sqlite-loader.lisp
index 71e33854da3dc5aa0d664241dbf710a9805a2084..59baaee3822d4cfe8d81b0a0dcb477775e1c27ab 100644 (file)
 to load the SQLite library succesfully.  If this differs at your site,
 set to the right path before compiling or loading the system.")
 
 to load the SQLite library succesfully.  If this differs at your site,
 set to the right path before compiling or loading the system.")
 
-(defvar *sqlite-library-loaded* #+clisp t
-                               #-clisp nil
-    "T if foreign library was able to be loaded successfully")
+(defvar *sqlite-library-loaded* nil
+  "T if foreign library was able to be loaded successfully")
 
 (defmethod database-type-library-loaded ((database-type (eql :sqlite)))
   "T if foreign library was able to be loaded successfully. "
   *sqlite-library-loaded*)
 
 (defmethod database-type-load-foreign ((database-type (eql :sqlite)))
 
 (defmethod database-type-library-loaded ((database-type (eql :sqlite)))
   "T if foreign library was able to be loaded successfully. "
   *sqlite-library-loaded*)
 
 (defmethod database-type-load-foreign ((database-type (eql :sqlite)))
-  #+clisp
-   t
-  #-clisp
   (let ((libpath (uffi:find-foreign-library
   (let ((libpath (uffi:find-foreign-library
-                 "libsqlite"
+                 '("libsqlite" "sqlite")
                  '(#+64bit "/usr/lib64/"
                  '(#+64bit "/usr/lib64/"
-                   "/usr/lib/" "/usr/local/lib/")
+                   "/usr/lib/" "/usr/local/lib/" "/bin/")
                  :drive-letters '("C" "D" "E"))))
     (if (uffi:load-foreign-library libpath
                                   :module "sqlite"
                  :drive-letters '("C" "D" "E"))))
     (if (uffi:load-foreign-library libpath
                                   :module "sqlite"
@@ -47,7 +43,7 @@ set to the right path before compiling or loading the system.")
        (setq *sqlite-library-loaded* t)
        (warn "Can't load SQLite library ~A" libpath))))
 
        (setq *sqlite-library-loaded* t)
        (warn "Can't load SQLite library ~A" libpath))))
 
-(clsql-base:database-type-load-foreign :sqlite)
+(clsql-sys:database-type-load-foreign :sqlite)