r3458: load library fixes
authorKevin M. Rosenberg <kevin@rosenberg.net>
Sat, 23 Nov 2002 18:00:26 +0000 (18:00 +0000)
committerKevin M. Rosenberg <kevin@rosenberg.net>
Sat, 23 Nov 2002 18:00:26 +0000 (18:00 +0000)
db-mysql/mysql-loader.lisp
db-postgresql/postgresql-loader.lisp
uffi/Makefile

index 79608087b5ab7e6b881dd7786922b0e5d1c65540..4a7fe2a868f8ec64230d964ce888113a43d1bfc2 100644 (file)
@@ -7,7 +7,7 @@
 ;;;; Programmers:   Kevin M. Rosenberg
 ;;;; Date Started:  Feb 2002
 ;;;;
 ;;;; Programmers:   Kevin M. Rosenberg
 ;;;; Date Started:  Feb 2002
 ;;;;
-;;;; $Id: mysql-loader.lisp,v 1.4 2002/10/18 01:16:26 kevin Exp $
+;;;; $Id: mysql-loader.lisp,v 1.5 2002/11/23 18:00:26 kevin Exp $
 ;;;;
 ;;;; This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg
 ;;;;
 ;;;;
 ;;;; This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg
 ;;;;
    "clsql-mysql"
    `(,(make-pathname :directory (pathname-directory *load-truename*))
      "/usr/lib/clsql/"
    "clsql-mysql"
    `(,(make-pathname :directory (pathname-directory *load-truename*))
      "/usr/lib/clsql/"
+     "/sw/lib/clsql/"
      "/home/kevin/debian/src/clsql/db-mysql/")
      "/home/kevin/debian/src/clsql/db-mysql/")
-   :drive-letters '("C" "D" "E" "F" "G")))
+   :drive-letters '("C" "D" "E")))
   
   
-(defvar *mysql-library-filename*
-    (cond
-     ((probe-file "/opt/mysql/lib/mysql/libmysqlclient.so")
-      "/opt/mysql/lib/mysql/libmysqlclient.so")
-     ((probe-file "/usr/local/lib/libmysqlclient.so")
-      "/usr/local/lib/libmysqlclient.so")
-     ((probe-file "/usr/local/lib/mysql/libmysqlclient.so")
-      "/usr/local/lib/mysql/libmysqlclient.so")
-     ((probe-file "/usr/lib/libmysqlclient.so")
-      "/usr/lib/libmysqlclient.so")
-     ((probe-file "/usr/lib/mysql/libmysqlclient.so")
-      "/usr/lib/mysql/libmysqlclient.so")
-     #+(or win32 mswindows) 
-     ((probe-file "c:/mysql/lib/opt/libmysql.dll")
-      "c:/mysql/lib/opt/libmysql.dll")
-     (t
-      (error "Can't find MySQL client library to load.")))
-  "Location where the MySQL client library is to be found.")
-
 (defvar *mysql-library-candidate-names*
     '("libmysqlclient" "libmysql"))
 
 (defvar *mysql-library-candidate-directories*
 (defvar *mysql-library-candidate-names*
     '("libmysqlclient" "libmysql"))
 
 (defvar *mysql-library-candidate-directories*
-    '("/opt/mysql/lib/mysql/" "/usr/local/lib/" "/usr/lib/" "/usr/local/lib/mysql/" "/usr/lib/mysql/" "/mysql/lib/opt/"))
+    '("/opt/mysql/lib/mysql/" "/usr/local/lib/" "/usr/lib/" "/usr/local/lib/mysql/" "/usr/lib/mysql/" "/mysql/lib/opt/" "/sw/lib/mysql/"))
 
 (defvar *mysql-library-candidate-drive-letters* '("C" "D" "E"))
 
 
 (defvar *mysql-library-candidate-drive-letters* '("C" "D" "E"))
 
@@ -84,7 +66,7 @@ set to the right path before compiling or loading the system.")
       (error "Can't find mysql client library to load"))
     (unless (probe-file zlib-path)
       (error "Can't find zlib client library to load"))
       (error "Can't find mysql client library to load"))
     (unless (probe-file zlib-path)
       (error "Can't find zlib client library to load"))
-    
+
     (uffi:load-foreign-library zlib-path) 
     (if        (and
         (uffi:load-foreign-library mysql-path
     (uffi:load-foreign-library zlib-path) 
     (if        (and
         (uffi:load-foreign-library mysql-path
index 5a0f03932e44ee636080a35e7f7fc27b1a33dce6..cfb9a362b2c6710227551aee8a5d315991ae8ea2 100644 (file)
@@ -7,7 +7,7 @@
 ;;;; Programmer:    Kevin M. Rosenberg
 ;;;; Date Started:  Feb 2002
 ;;;;
 ;;;; Programmer:    Kevin M. Rosenberg
 ;;;; Date Started:  Feb 2002
 ;;;;
-;;;; $Id: postgresql-loader.lisp,v 1.1 2002/09/30 10:19:23 kevin Exp $
+;;;; $Id: postgresql-loader.lisp,v 1.2 2002/11/23 18:00:26 kevin Exp $
 ;;;;
 ;;;; This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg
 ;;;;
 ;;;;
 ;;;; This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg
 ;;;;
@@ -39,7 +39,7 @@ set to the right path before compiling or loading the system.")
                  '("/opt/postgresql/lib/" "/usr/local/lib/" 
                    "/usr/lib/" "/postgresql/lib/"
                    "/usr/local/pgsql/lib/" "/usr/lib/pgsql/"
                  '("/opt/postgresql/lib/" "/usr/local/lib/" 
                    "/usr/lib/" "/postgresql/lib/"
                    "/usr/local/pgsql/lib/" "/usr/lib/pgsql/"
-                   "/opt/pgsql/lib/pgsql")
+                   "/opt/pgsql/lib/pgsql" "/sw/lib/pgsql/")
                  :drive-letters '("C" "D" "E"))))
     (if        (uffi:load-foreign-library libpath
                                   :module "postgresql"
                  :drive-letters '("C" "D" "E"))))
     (if        (uffi:load-foreign-library libpath
                                   :module "postgresql"
index 8093b7033b547f644e72c93871ba5e4492c45760..d24b555b42c0ccd3cab0d123183b68d67fc9e742 100644 (file)
@@ -7,7 +7,7 @@
 #  Programer:    Kevin M. Rosenberg
 #  Date Started: Mar 2002
 #
 #  Programer:    Kevin M. Rosenberg
 #  Date Started: Mar 2002
 #
-#  CVS Id:   $Id: Makefile,v 1.1 2002/09/18 07:50:01 kevin Exp $
+#  CVS Id:   $Id: Makefile,v 1.2 2002/11/23 18:00:26 kevin Exp $
 #
 # This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg
 #
 #
 # This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg
 #
@@ -50,3 +50,6 @@ clean:
 
 distclean: clean
 
 
 distclean: clean
 
+macosx: $(source) Makefile
+       cc -dynamic -c $(source) -o $(object)
+       ld -bundle /usr/lib/bundle1.o -flat_namespace -undefined suppress -o $(base).dylib $(object)