You can build applications using an ODBC Driver Manager on the following operating systems:
Windows
Linux
Mac OS X
The Microsoft ODBC Driver Manager includes a dll named odbc32.dll or an import library named odbc32.lib. On Windows 2000, the odbc32.dll file is located in %SystemRoot%\system32. The odbc32.lib file can appear in a number of locations, depending on which products you have installed. If you use Microsoft Visual Studio.NET the odbc32.lib is located in the %Install Path% to Microsoft Visual Studio%\ Vc7\PlatformSDK\Lib. To link an ODBC application against the Microsoft ODBC Driver Manager, use odbc32.lib.
The ODBC Driver Manager includes a shared library named libodbc.so, which is a soft link to a library named libodbc.so.1. This file is typically located in the /usr/lib directory.
Some older Driver Manager packages do not create the
soft link from libodbc.so.1 to libodbc.so.
Sybase recommends that you manually create this link. The ODBC Driver
Manager also includes another shared library called libodbcinst.so.1.
A soft link from this file to libodbcinst.so should
also exist. If it is not on your system, you should create one.
To link an ODBC application against the ODBC Driver
Manager
Pass the -lodbc
flag
to the linker.
If the ODBC Driver Manager is not installed in the /usr/lib directory,
you also need to pass the -Ldir
flag
to the linker,
where:
dir is the directory where the ODBC Driver Manager shared libraries are located.
To link an ODBC application against the iODBC
Driver manager
The iODBC Driver Manager includes a dynamic library named libiodbc.dylib, typically located in the /usr/lib directory.
Pass the -liodbc
flag
to the linker.
If you use the unixODBC Driver Manager instead of iODBC, the
linker flag should be -lodbc
.
If the ODBC Driver Manager is not installed in the /usr/lib directory,
you also need to pass the -Ldir
flag
to the linker,
where:
dir
is
the directory where the ODBC Driver Manager shared libraries are located.