+ use unified patch format
This commit is contained in:
		
							parent
							
								
									975e08732e
								
							
						
					
					
						commit
						45dfc0fbde
					
				
							
								
								
									
										466
									
								
								scsh/odbc/README
								
								
								
								
							
							
						
						
									
										466
									
								
								scsh/odbc/README
								
								
								
								
							|  | @ -20,88 +20,137 @@ Index: autogen.sh | |||
| =================================================================== | ||||
| RCS file: /cvsroot/scsh/scsh-0.6/autogen.sh,v | ||||
| retrieving revision 1.7 | ||||
| diff -r1.7 autogen.sh | ||||
| 5c5 | ||||
| < ./configure && | ||||
| --- | ||||
| > ./configure --with-iODBC=/usr/lib && | ||||
| 15,16c15 | ||||
| < make build/initial.image && | ||||
| < make distclean  | ||||
| --- | ||||
| > make build/initial.image  | ||||
| diff -u -r1.7 autogen.sh | ||||
| --- autogen.sh	12 Feb 2002 16:26:05 -0000	1.7 | ||||
| +++ autogen.sh	20 Mar 2003 16:01:57 -0000 | ||||
| @@ -2,7 +2,7 @@ | ||||
|   | ||||
|  autoheader && | ||||
|  autoconf && | ||||
| -./configure && | ||||
| +./configure --with-iODBC=/usr/lib && | ||||
|  touch scsh/*.c && | ||||
|  touch build/filenames.scm && | ||||
|  rm -f scheme48.image cig/cig.image scsh/scsh.image && | ||||
| @@ -12,5 +12,4 @@ | ||||
|  make i-know-what-i-am-doing && | ||||
|  make c/scheme48.h&& | ||||
|  make linker && | ||||
| -make build/initial.image && | ||||
| -make distclean  | ||||
| +make build/initial.image  | ||||
| Index: configure.in | ||||
| =================================================================== | ||||
| RCS file: /cvsroot/scsh/scsh-0.6/configure.in,v | ||||
| retrieving revision 1.27 | ||||
| diff -r1.27 configure.in | ||||
| 397c397,420 | ||||
| <      | ||||
| --- | ||||
| > AC_ARG_WITH(unixODBC, | ||||
| > 	[ --with-unixODBC=DIR 		Support for unixODBC ], | ||||
| > 	[ with_unixodbc=$withval ], | ||||
| > 	[ with_unixodbc=no ] | ||||
| > 	) | ||||
| > if test "$with_unixodbc" != no; then | ||||
| > 	odbc_includes="-I$with_unixodbc/include" | ||||
| > 	odbc_libs="-lodbc -L$with_unixodbc/lib" | ||||
| > 	AC_SUBST(odbc_includes) | ||||
| > 	AC_SUBST(odbc_libs) | ||||
| > fi	 | ||||
| >  | ||||
| > AC_ARG_WITH(iODBC, | ||||
| > 	[ --with-iODBC=DIR			Support for iODBC ], | ||||
| > 	[ with_iodbc=$with_iodbc ], | ||||
| > 	[ with_iodbc=no ] | ||||
| > 	) | ||||
| > if test "$with_iodbc" != no; then | ||||
| > 	odbc_includes="-I$with_iodbc/include" | ||||
| > 	odbc_libs="-liodbc -L$with_iodbc/lib" | ||||
| > 	AC_SUBST(odbc_includes) | ||||
| > 	AC_SUBST(odbc_libs) | ||||
| > fi	 | ||||
| >  | ||||
| diff -u -r1.27 configure.in | ||||
| --- configure.in	13 Dec 2002 15:22:13 -0000	1.27 | ||||
| +++ configure.in	20 Mar 2003 16:01:57 -0000 | ||||
| @@ -394,7 +394,30 @@ | ||||
|       AC_SUBST(LIBS) | ||||
|       AC_SUBST(TMPDIR) | ||||
|   | ||||
| -     | ||||
| +AC_ARG_WITH(unixODBC, | ||||
| +	[ --with-unixODBC=DIR 		Support for unixODBC ], | ||||
| +	[ with_unixodbc=$withval ], | ||||
| +	[ with_unixodbc=no ] | ||||
| +	) | ||||
| +if test "$with_unixodbc" != no; then | ||||
| +	odbc_includes="-I$with_unixodbc/include" | ||||
| +	odbc_libs="-lodbc -L$with_unixodbc/lib" | ||||
| +	AC_SUBST(odbc_includes) | ||||
| +	AC_SUBST(odbc_libs) | ||||
| +fi	 | ||||
| + | ||||
| +AC_ARG_WITH(iODBC, | ||||
| +	[ --with-iODBC=DIR			Support for iODBC ], | ||||
| +	[ with_iodbc=$with_iodbc ], | ||||
| +	[ with_iodbc=no ] | ||||
| +	) | ||||
| +if test "$with_iodbc" != no; then | ||||
| +	odbc_includes="-I$with_iodbc/include" | ||||
| +	odbc_libs="-liodbc -L$with_iodbc/lib" | ||||
| +	AC_SUBST(odbc_includes) | ||||
| +	AC_SUBST(odbc_libs) | ||||
| +fi	 | ||||
| + | ||||
|  AC_CONFIG_FILES(Makefile scsh/endian.scm scsh-config) | ||||
|  AC_CONFIG_COMMANDS([scsh-config+x],[chmod +x scsh-config]) | ||||
|  AC_OUTPUT | ||||
| Index: Makefile.in | ||||
| =================================================================== | ||||
| RCS file: /cvsroot/scsh/scsh-0.6/Makefile.in,v | ||||
| retrieving revision 1.59 | ||||
| diff -r1.59 Makefile.in | ||||
| 11,12c11,12 | ||||
| < LIBS = @LIBS@ | ||||
| < CFLAGS = @CFLAGS@ | ||||
| --- | ||||
| > LIBS = @LIBS@ @odbc_libs@ | ||||
| > CFLAGS = @CFLAGS@ @odbc_includes@ | ||||
| 50c50,51 | ||||
| < BUILD_RUNNABLE = /afs/wsi/i386_fbsd32/bin/scheme48 | ||||
| --- | ||||
| > BUILD_RUNNABLE = /afs/wsi/ppc_macx55/scheme48-0.53/bin/scheme48 | ||||
| > #BUILD_RUNNABLE = /afs/wsi/ppc_macx55/scheme48-0.53/bin/scheme48 | ||||
| 136c137 | ||||
| < 	scsh/md5.o | ||||
| --- | ||||
| > 	scsh/md5.o  | ||||
| 172,173c173,175 | ||||
| < EXTERNAL_OBJECTS = $(SOCKET_OBJECTS) $(LOOKUP_OBJECTS) | ||||
| < EXTERNAL_FLAGS = $(SOCKET_FLAGS) | ||||
| --- | ||||
| > EXTERNAL_OBJECTS = $(SOCKET_OBJECTS) $(LOOKUP_OBJECTS) $(ODBC_OBJECTS) | ||||
| > EXTERNAL_FLAGS = $(SOCKET_FLAGS) $(ODBC_FLAGS) | ||||
| > EXTERNAL_LDFLAGS = $(SOCKET_LD_FLAGS) $(ODBC_LD_FLAGS) | ||||
| 176a179 | ||||
| > 	$(ODBC_INITIALIZERS) 							\ | ||||
| 181a185,189 | ||||
| > scsh/odbc/odbc.o: scsh/odbc/odbc.h | ||||
| >  | ||||
| > ODBC_OBJECTS = scsh/odbc/odbc.o | ||||
| > ODBC_INITIALIZERS = s48_init_odbc | ||||
| >  | ||||
| 838c846,847 | ||||
| < 	scsh/rx/regress.scm | ||||
| --- | ||||
| > 	scsh/rx/regress.scm \ | ||||
| > 	scsh/odbc/odbc.scm | ||||
| diff -u -r1.59 Makefile.in | ||||
| --- Makefile.in	13 Jan 2003 06:17:49 -0000	1.59 | ||||
| +++ Makefile.in	20 Mar 2003 16:01:57 -0000 | ||||
| @@ -8,8 +8,8 @@ | ||||
|  VPATH = @srcdir@ | ||||
|  CC = @CC@ | ||||
|  DEFS = @DEFS@ | ||||
| -LIBS = @LIBS@ | ||||
| -CFLAGS = @CFLAGS@ | ||||
| +LIBS = @LIBS@ @odbc_libs@ | ||||
| +CFLAGS = @CFLAGS@ @odbc_includes@ | ||||
|  INSTALL = @INSTALL@ | ||||
|  INSTALL_PROGRAM = @INSTALL_PROGRAM@ | ||||
|  INSTALL_DATA = @INSTALL_DATA@ | ||||
| @@ -47,7 +47,8 @@ | ||||
|  # BUILD_RUNNABLE has to be Scheme 48 0.53. This is used for builds directly  | ||||
|  # out of the CVS repository. | ||||
|  # We cannot use Scsh here since -i is not understood. | ||||
| -BUILD_RUNNABLE = /afs/wsi/i386_fbsd32/bin/scheme48 | ||||
| +BUILD_RUNNABLE = /afs/wsi/ppc_macx55/scheme48-0.53/bin/scheme48 | ||||
| +#BUILD_RUNNABLE = /afs/wsi/ppc_macx55/scheme48-0.53/bin/scheme48 | ||||
|  RUNNABLE = scsh | ||||
|  MANPAGE = $(RUNNABLE).$(manext) | ||||
|  LIB = $(libdir)/$(RUNNABLE) | ||||
| @@ -133,7 +134,7 @@ | ||||
|  	scsh/userinfo1.o \ | ||||
|  	scsh/sighandlers1.o \ | ||||
|  	scsh/libscsh.o \ | ||||
| -	scsh/md5.o | ||||
| +	scsh/md5.o  | ||||
|   | ||||
|  SCSH_INITIALIZERS = s48_init_syslog s48_init_posix_regexp \ | ||||
|  	s48_init_userinfo s48_init_sighandlers \ | ||||
| @@ -169,16 +170,23 @@ | ||||
|  # External code to include in the VM | ||||
|  # After changing any of these you should delete `scheme48vm' and remake it. | ||||
|   | ||||
| -EXTERNAL_OBJECTS = $(SOCKET_OBJECTS) $(LOOKUP_OBJECTS) | ||||
| -EXTERNAL_FLAGS = $(SOCKET_FLAGS) | ||||
| +EXTERNAL_OBJECTS = $(SOCKET_OBJECTS) $(LOOKUP_OBJECTS) $(ODBC_OBJECTS) | ||||
| +EXTERNAL_FLAGS = $(SOCKET_FLAGS) $(ODBC_FLAGS) | ||||
| +EXTERNAL_LDFLAGS = $(SOCKET_LD_FLAGS) $(ODBC_LD_FLAGS) | ||||
|  EXTERNAL_INITIALIZERS = $(ADDITIONAL_INITIALIZER) $(SOCKET_INITIALIZERS) 	\ | ||||
|  	$(LOOKUP_INITIALIZERS) 							\ | ||||
|  	$(SCSH_INITIALIZERS) $(SRFI_INITIALIZERS)				\ | ||||
| +	$(ODBC_INITIALIZERS) 							\ | ||||
|  	s48_init_cig | ||||
|   | ||||
|   | ||||
|  # Rules for any external code. | ||||
|   | ||||
| +scsh/odbc/odbc.o: scsh/odbc/odbc.h | ||||
| + | ||||
| +ODBC_OBJECTS = scsh/odbc/odbc.o | ||||
| +ODBC_INITIALIZERS = s48_init_odbc | ||||
| + | ||||
|  # Socket rules | ||||
|   | ||||
|  c/unix/socket.o: c/scheme48.h c/fd-io.h c/event.h | ||||
| @@ -835,7 +843,8 @@ | ||||
|  	scsh/rx/re-high.scm \ | ||||
|  	scsh/rx/regexp.scm \ | ||||
|  	scsh/rx/re-low.scm \ | ||||
| -	scsh/rx/regress.scm | ||||
| +	scsh/rx/regress.scm \ | ||||
| +	scsh/odbc/odbc.scm | ||||
|  #    	scsh/dbm.scm db.scm ndbm.scm | ||||
|  #	jcontrol | ||||
|   | ||||
| 
 | ||||
| This will add some rules to Makefile and add two options to configure: | ||||
| --with-iODBC=PATH and --with-unixODBC=PATH.  | ||||
|  | @ -114,137 +163,152 @@ Index: scsh-package.scm | |||
| =================================================================== | ||||
| RCS file: /cvsroot/scsh/scsh-0.6/scsh/scsh-package.scm,v | ||||
| retrieving revision 1.59 | ||||
| diff -r1.59 scsh-package.scm | ||||
| 599a600,617 | ||||
| >  | ||||
| > ;;; ODBC stuff | ||||
| >  | ||||
| > (define-structure odbc-data-types odbc-data-types-interface | ||||
| >   (open  | ||||
| >    scheme define-structure | ||||
| >    external-calls) | ||||
| >   (files (odbc odbc-types))) | ||||
| >  | ||||
| > (define-structure odbc odbc-interface | ||||
| >   (open  | ||||
| > 	scheme define-record-types | ||||
| > 	external-calls | ||||
| > 	scsh-utilities  | ||||
| > 	conditions signals) | ||||
| >   (files (odbc odbc) | ||||
| > 	 (odbc odbc-bindcol))) | ||||
| >  | ||||
| diff -u -r1.59 scsh-package.scm | ||||
| --- scsh-package.scm	25 Feb 2003 12:58:37 -0000	1.59 | ||||
| +++ scsh-package.scm	20 Mar 2003 16:03:38 -0000 | ||||
| @@ -597,3 +597,21 @@ | ||||
|        signals | ||||
|        srfi-9) | ||||
|    (files srfi-19)) | ||||
| + | ||||
| +;;; ODBC stuff | ||||
| + | ||||
| +(define-structure odbc-data-types odbc-data-types-interface | ||||
| +  (open  | ||||
| +   scheme define-structure | ||||
| +   external-calls) | ||||
| +  (files (odbc odbc-types))) | ||||
| + | ||||
| +(define-structure odbc odbc-interface | ||||
| +  (open  | ||||
| +	scheme define-record-types | ||||
| +	external-calls | ||||
| +	scsh-utilities  | ||||
| +	conditions signals) | ||||
| +  (files (odbc odbc) | ||||
| +	 (odbc odbc-bindcol))) | ||||
| + | ||||
| Index: scsh-interfaces.scm | ||||
| =================================================================== | ||||
| RCS file: /cvsroot/scsh/scsh-0.6/scsh/scsh-interfaces.scm,v | ||||
| retrieving revision 1.53 | ||||
| diff -r1.53 scsh-interfaces.scm | ||||
| 1169,1175c1169,1175 | ||||
| <   (export uname | ||||
| < 	  uname:os-name | ||||
| < 	  uname:node-name | ||||
| < 	  uname:release | ||||
| < 	  uname:version | ||||
| < 	  uname:machine | ||||
| < 	  type/uname)) | ||||
| --- | ||||
| >    (export uname | ||||
| >  	  uname:os-name | ||||
| >  	  uname:node-name | ||||
| >  	  uname:release | ||||
| >  	  uname:version | ||||
| >  	  uname:machine | ||||
| >  	  type/uname)) | ||||
| 1277a1278,1366 | ||||
| >  | ||||
| > ;;; ODBC stuff | ||||
| > (define-interface odbc-data-types-interface | ||||
| >   (export  | ||||
| >  | ||||
| >    make-sql-date | ||||
| >    sql-date? | ||||
| >    sql-date-year | ||||
| >    sql-date-month | ||||
| >    sql-date-day | ||||
| >  | ||||
| >    make-sql-time | ||||
| >    sql-time? | ||||
| >    sql-time-hour | ||||
| >    sql-time-minute | ||||
| >    sql-time-second | ||||
| >  | ||||
| >    make-sql-timestamp | ||||
| >    sql-timestamp? | ||||
| >    sql-timestamp-year | ||||
| >    sql-timestamp-month | ||||
| >    sql-timestamp-day | ||||
| >    sql-timestamp-hour | ||||
| >    sql-timestamp-minute | ||||
| >    sql-timestamp-second | ||||
| >    sql-timestamp-fraction | ||||
| >  | ||||
| >    make-sql-numeric | ||||
| >    sql-numeric? | ||||
| >    sql-numeric-precision | ||||
| >    sql-numeric-scale | ||||
| >    sql-numeric-sign | ||||
| >    sql-numeric-value)) | ||||
| >  | ||||
| > (define-interface odbc-interface | ||||
| >   (export  | ||||
| >    odbc-handle? | ||||
| >    environment-handle? | ||||
| >    connection-handle? | ||||
| >    statement-handle? | ||||
| >    descriptor-handle? | ||||
| >     | ||||
| >    odbc-alloc-environment-handle | ||||
| >    odbc-alloc-connection-handle | ||||
| >    odbc-alloc-statement-handle | ||||
| >    odbc-sql-connect | ||||
| >  | ||||
| >    odbc-sql-data-sources | ||||
| >    odbc-sql-drivers | ||||
| >    odbc-sql-get-info-int | ||||
| >    odbc-sql-get-info-string | ||||
| >    odbc-sql-get-func | ||||
| >    odbc-sql-get-type-info | ||||
| >  | ||||
| >    odbc-sql-set-connect-attr-int | ||||
| >    odbc-sql-set-connect-attr-string | ||||
| >    odbc-sql-get-connect-attr-string | ||||
| >    odbc-sql-get-connect-attr-int | ||||
| >    odbc-sql-set-env-attr-int | ||||
| >    odbc-sql-get-env-attr-int | ||||
| >    odbc-sql-set-stmt-attr-int | ||||
| >    odbc-sql-get-stmt-attr-int | ||||
| >  | ||||
| >    odbc-sql-prepare | ||||
| >    odbc-sql-bind-parameter-exec-out | ||||
| >    odbc-sql-get-cursor-name | ||||
| >    odbc-sql-set-cursor-name | ||||
| >  | ||||
| >    odbc-sql-execute | ||||
| >    odbc-sql-execute-direct | ||||
| >     | ||||
| >    odbc-sql-row-count | ||||
| >    odbc-sql-get-data | ||||
| >    odbc-sql-fetch | ||||
| >     | ||||
| >    odbc-sql-free-statement | ||||
| >    odbc-sql-close-cursor | ||||
| >    odbc-sql-cancel | ||||
| >    odbc-sql-num-result-cols | ||||
| >    odbc-sql-describe-col | ||||
| >     | ||||
| >    odbc-sql-disconnect | ||||
| >    odbc-sql-free-handle | ||||
| >  | ||||
| >    odbc-buffer-exceeded? | ||||
| >    signal-buffer-exceeded | ||||
| >    odbc-unbound-column? | ||||
| >    signal-unbound-column | ||||
| >    odbc-sql-bindcol)) | ||||
| diff -u -r1.53 scsh-interfaces.scm | ||||
| --- scsh-interfaces.scm	25 Feb 2003 12:58:37 -0000	1.53 | ||||
| +++ scsh-interfaces.scm	20 Mar 2003 16:03:39 -0000 | ||||
| @@ -1166,13 +1166,13 @@ | ||||
|    (export crypt)) | ||||
|   | ||||
|  (define-interface uname-interface | ||||
| -  (export uname | ||||
| -	  uname:os-name | ||||
| -	  uname:node-name | ||||
| -	  uname:release | ||||
| -	  uname:version | ||||
| -	  uname:machine | ||||
| -	  type/uname)) | ||||
| +   (export uname | ||||
| + 	  uname:os-name | ||||
| + 	  uname:node-name | ||||
| + 	  uname:release | ||||
| + 	  uname:version | ||||
| + 	  uname:machine | ||||
| + 	  type/uname)) | ||||
|   | ||||
|  (define-interface md5-interface | ||||
|    (export make-md5-context | ||||
| @@ -1275,3 +1275,92 @@ | ||||
|     ;; Date to string/string to date converters. | ||||
|     date->string | ||||
|     string->date)) | ||||
| + | ||||
| +;;; ODBC stuff | ||||
| +(define-interface odbc-data-types-interface | ||||
| +  (export  | ||||
| + | ||||
| +   make-sql-date | ||||
| +   sql-date? | ||||
| +   sql-date-year | ||||
| +   sql-date-month | ||||
| +   sql-date-day | ||||
| + | ||||
| +   make-sql-time | ||||
| +   sql-time? | ||||
| +   sql-time-hour | ||||
| +   sql-time-minute | ||||
| +   sql-time-second | ||||
| + | ||||
| +   make-sql-timestamp | ||||
| +   sql-timestamp? | ||||
| +   sql-timestamp-year | ||||
| +   sql-timestamp-month | ||||
| +   sql-timestamp-day | ||||
| +   sql-timestamp-hour | ||||
| +   sql-timestamp-minute | ||||
| +   sql-timestamp-second | ||||
| +   sql-timestamp-fraction | ||||
| + | ||||
| +   make-sql-numeric | ||||
| +   sql-numeric? | ||||
| +   sql-numeric-precision | ||||
| +   sql-numeric-scale | ||||
| +   sql-numeric-sign | ||||
| +   sql-numeric-value)) | ||||
| + | ||||
| +(define-interface odbc-interface | ||||
| +  (export  | ||||
| +   odbc-handle? | ||||
| +   environment-handle? | ||||
| +   connection-handle? | ||||
| +   statement-handle? | ||||
| +   descriptor-handle? | ||||
| +    | ||||
| +   odbc-alloc-environment-handle | ||||
| +   odbc-alloc-connection-handle | ||||
| +   odbc-alloc-statement-handle | ||||
| +   odbc-sql-connect | ||||
| + | ||||
| +   odbc-sql-data-sources | ||||
| +   odbc-sql-drivers | ||||
| +   odbc-sql-get-info-int | ||||
| +   odbc-sql-get-info-string | ||||
| +   odbc-sql-get-func | ||||
| +   odbc-sql-get-type-info | ||||
| + | ||||
| +   odbc-sql-set-connect-attr-int | ||||
| +   odbc-sql-set-connect-attr-string | ||||
| +   odbc-sql-get-connect-attr-string | ||||
| +   odbc-sql-get-connect-attr-int | ||||
| +   odbc-sql-set-env-attr-int | ||||
| +   odbc-sql-get-env-attr-int | ||||
| +   odbc-sql-set-stmt-attr-int | ||||
| +   odbc-sql-get-stmt-attr-int | ||||
| + | ||||
| +   odbc-sql-prepare | ||||
| +   odbc-sql-bind-parameter-exec-out | ||||
| +   odbc-sql-get-cursor-name | ||||
| +   odbc-sql-set-cursor-name | ||||
| + | ||||
| +   odbc-sql-execute | ||||
| +   odbc-sql-execute-direct | ||||
| +    | ||||
| +   odbc-sql-row-count | ||||
| +   odbc-sql-get-data | ||||
| +   odbc-sql-fetch | ||||
| +    | ||||
| +   odbc-sql-free-statement | ||||
| +   odbc-sql-close-cursor | ||||
| +   odbc-sql-cancel | ||||
| +   odbc-sql-num-result-cols | ||||
| +   odbc-sql-describe-col | ||||
| +    | ||||
| +   odbc-sql-disconnect | ||||
| +   odbc-sql-free-handle | ||||
| + | ||||
| +   odbc-buffer-exceeded? | ||||
| +   signal-buffer-exceeded | ||||
| +   odbc-unbound-column? | ||||
| +   signal-unbound-column | ||||
| +   odbc-sql-bindcol)) | ||||
| 
 | ||||
| Now it's time to build scsh. Edit the call to configure in autgen.sh to | ||||
| your needs, e.g.: | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	 eknauel
						eknauel