1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205
|
#
# README
#
# (C) 1999 OpenLink Software Inc.
#
# The iODBC driver manager.
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Library General Public
# License as published by the Free Software Foundation; either
# version 2 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Library General Public License for more details.
#
# You should have received a copy of the GNU Library General Public
# License along with this library; if not, write to the Free
# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
1. iODBC driver manager platform availability
iODBC driver manager has been ported to following Unix platforms:
SunOS 4.1.x Sun Sparc
HP/UX 9.x, 10.x HP9000 s700/s800
HP/UX 9.x HP9000 s300/s400
IBM AIX 3.x, 4.x IBM RS6000, PowerPC
Sun Solaris 2.x Sun Sparc, PCx86
SGI Irix SVR4 5.x, 6.x IP12 MIPS, IP22 MIPS
NCR SVR4 3.x NCR 3435
UnixWare SVR4.2 1.x, 2.x x86
DEC Unix(OSF/1) 3.x, 4.x DEC Alpha
FreeBSD 2.x x86
BSDI BSD/OS 2.x ?
Linux ELF 1.2.x, 1.3.x x86
SCO OpenServer 5.x x86
Max/OS SVR4 1.x Concurrent Maxion 9200 MP
DG/UX 5.x Aviion
OpenVMS 6.x DEC Alpha
Windows NT 4.x x86
As the iODBC driver manager uses autoconf/automake/libtool it should
be portable to most modern UNIX platforms out of the box. However if
you do need to make changes to the code or the configuration files,
we would appreciate you share your changes with the rest of the
internet community by mailing your patches to iodbc@openlinksw.com
so we can include them for the next build
Porting of iODBC driver manager to some non-UNIX operating systems
such as Windows family(3.x, 95, NT), OS/2 and Mac is supported but has
not been compiled and tested recently. Of cause, you need to supply
a make/build file and a short LibMain for creating the iodbc.dll.
2. How to build iODBC driver manager:
step 1. Run configure to adjust to target platform
step 2. Run make
step 3. Run make install
Here is an example:
$ ./configure --prefix=/usr/local --with-iodbc-inidir=/etc
...
...
...
$ make
...
...
...
$ su
# make install
...
...
...
The configure program will examine your system for various compiler
flags, system options etc. In some cases extra flags need to be
added for the C compiler to work properly.
E.g. on HP systems you may need:
$ CFLAGS="-Ae -O" ./configure --prefix=/usr/local ..........
Note that the path of the system wide odbc.ini file is calculated as
follows (based on flags to ./configure):
no --prefix default is /usr/local/etc/odbc.ini
--prefix=/usr /etc/odbc.ini
--prefix=/xxx/yyy /xxx/yyy/etc/odbc.ini
--sysconfdir=/xxx/yyy /xxx/yyy/odbc.ini
--with-iodbc-inidir=/xxx/yyy /xxx/yyy/odbc.ini
3. odbc.ini
Driver manager and drivers use odbc.ini file or connection string
when establishing a data source connection. On Windows, odbc.ini is
located in Windows directory.
On UNIX, the iODBC driver manager looks for the odbc.ini file in the
following sequence:
1. check environment variable ODBCINI
2. check $HOME/.odbc.ini
3. check home in /etc/passwd and try .odbc.ini in there
4. system wide odbc.ini (settable at configuration time)
Item 1 is the easiest as most drivers will also look at this variable.
The format of odbc.ini( or ~/.odbc.ini ) is defined as:
odbc.ini ::= data_source_list
data_source_list ::= /* empty */
| data_source '\n' data_source_list
data_source ::= '[' data_source_name ']' '\n' data_source_desc
data_source_name ::= 'default' | [A-Za-z]*[A-Za-z0-9_]*
data_source_desc ::= /* empty */
| attrib_desc '\n' data_source_desc
addrib_desc ::= Attrib '=' attrib_value
Attrib ::= 'Driver' | 'PID' | 'UID' | driver_def_attrib
driver_def_attrib ::= [A-Za-z]*[A-Za-z0-9_]*
An example of an odbc.ini file:
;
; odbc.ini
;
[ODBC Data Sources]
Myodbc = Myodbc
Sample = OpenLink Generic ODBC Driver
Virtuoso = Virtuoso
[Sample]
Driver = /usr/local/openlink/lib/oplodbc.so.1
Description = Sample OpenLink DSN
Host = localhost
UserName = openlink
Password = xxxx
ServerType = Oracle 8
Database =
FetchBufferSize = 99
ReadOnly = no
TraceFile = /tmp/odbc.trace
Trace = 1
[Virtuoso]
Driver = /usr/local/virtuoso/lib/virtodbc.so.1
Address = localhost:1112
Database = Demo
[Myodbc]
Driver = /home/patrick/src/iODBC/new/myodbc/myodbc.so
HOST = localhost
[Default]
Driver = /usr/local/openlink/lib/oplodbc.so.1
4. Tracing
iODBC driver manager traces driver's ODBC call invoked by the driver
manager. Default tracing file is ./odbc.log. Tracing option (i.e.
on/off or optional tracing file name) can be set in odbc.ini file
(under a data source section) as:
TraceFile = <optional_trace_file>
Trace = ON | On | on | 1 | OFF | Off | off | 0
If <optional_trace_file> is stderr or stdout, i.e.
TraceFile = stderr
or
TraceFile = stdout
the tracing message will go to the terminal screen (if it is available).
iODBC driver manager allows one to tune on/off tracing on selected
connection(s). Different connections can share one or use different
tracing file(s). ODBC calls on connections without tuning tracing
on will not be traced.
|