Difference between revisions of "UnixODBC"

From CBLFS
Jump to navigationJump to search
(Optional)
Line 162: Line 162:
 
| is a graphical program used to test the ODBC API.
 
| is a graphical program used to test the ODBC API.
 
|}
 
|}
 +
 +
[[Category:General Utilities]]

Revision as of 15:05, 19 March 2009

Download Source: http://www.unixodbc.org/unixODBC-2.2.12.tar.gz

Introduction to UnixODBC

Project Homepage: Unknown

Dependencies

Optional

Caution.png

Note

Currently, UnixODBC does not compile with Flex 2.5.34. With 2.5.33 and 2.5.35 there are no problems.

Non-Multilib

Compile the package:

sed -i "s/void yyerror/#define YY_FLUSH_BUFFER\n\n&/" sqp/lex.l &&
./configure --prefix=/usr --sysconfdir=/etc/unixodbc \
    --enable-ltdllib --enable-fdb && 
sed -i 's@^LDFLAGS.*=@& ../libltdl/.libs/libltdlc.a -ldl@' exe/Makefile
make

Install the package

make install &&
find doc -name "Makefile*" -exec rm {} \; &&
chmod 644 doc/{lst,ProgrammerManual/Tutorial}/* &&
install -v -m755 -d /usr/share/doc/unixODBC-2.2.12 &&
cp -v -R doc/* /usr/share/doc/unixODBC-2.2.12

Command Explanations

sed -i "..." sqp/lex.l: This fixes a build issue if using a compiler version greater than GCC-3.x.x.

--enable-ltdllib: This parameter causes the build to use the system-installed version of Libtool.

--enable-fdb: This parameter enables support for file-based data access.

--disable-gui: This parameter disables building the GUI tools. Remove it if you have Qt installed and wish to build the GUI tools.

Multilib

32Bit

Compile the package:

sed -i "s/void yyerror/#define YY_FLUSH_BUFFER\n\n&/" sqp/lex.l &&
CC="gcc ${BUILD32}" CXX="g++ ${BUILD32}" USE_ARCH=32 PKG_CONFIG_PATH="${PKG_CONFIG_PATH32}" \
LDFLAGS="-L/usr/lib" ./configure --prefix=/usr --sysconfdir=/etc/unixodbc \
    --enable-ltdllib --enable-fdb &&
sed -i 's@^LDFLAGS.*=@& ../libltdl/.libs/libltdlc.a -ldl@' exe/Makefile
make

Install the package

make install &&
mv -v /usr/bin/odbc_config{,-32}

N32

Compile the package:

sed -i "s/void yyerror/#define YY_FLUSH_BUFFER\n\n&/" sqp/lex.l &&
CC="gcc ${BUILDN32}" CXX="g++ ${BUILDN32}" USE_ARCH=n32 PKG_CONFIG_PATH="${PKG_CONFIG_PATHN32}" \
LDFLAGS="-L/usr/lib32" ./configure --prefix=/usr --sysconfdir=/etc/unixodbc \
    --libdir=/usr/lib32 --enable-ltdllib --enable-fdb --with-qt-libraries=${QTDIR}/lib32 &&
sed -i -e "/sys_lib_search_path_spec=/s@/lib@&32@g" \
       -e "/sys_lib_dlsearch_path_spec=/s@/lib@&32@g" libtool &&
sed -i 's@^LDFLAGS.*=@& ../libltdl/.libs/libltdlc.a -ldl@' exe/Makefile
make

Install the package

make install &&
mv -v /usr/bin/odbc_config{,-n32}

64Bit

Compile the package:

sed -i "s/void yyerror/#define YY_FLUSH_BUFFER\n\n&/" sqp/lex.l &&
CC="gcc ${BUILD64}" CXX="g++ ${BUILD64}" USE_ARCH=64 PKG_CONFIG_PATH="${PKG_CONFIG_PATH64}" \
LDFLAGS="-L/usr/lib64" ./configure --prefix=/usr --sysconfdir=/etc/unixodbc \
    --libdir=/usr/lib64 --enable-ltdllib --enable-fdb --with-qt-libraries=${QTDIR}/lib64 &&
sed -i -e "/sys_lib_search_path_spec=/s@/lib@&64@g" \
       -e "/sys_lib_dlsearch_path_spec=/s@/lib@&64@g" libtool &&
sed -i 's@^LDFLAGS.*=@& ../libltdl/.libs/libltdlc.a -ldl@' exe/Makefile
make

Install the package

make install &&
mv -v /usr/bin/odbc_config{,-64} &&
ln -sfv multiarch_wrapper /usr/bin/odbc_config &&
find doc -name "Makefile*" -exec rm {} \; &&
chmod 644 doc/{lst,ProgrammerManual/Tutorial}/* &&
install -v -m755 -d /usr/share/doc/unixODBC-2.2.12 &&
cp -v -R doc/* /usr/share/doc/unixODBC-2.2.12

Configuring UnixODBC

Config Files

/etc/unixodbc/*

Configuration information

The files in /etc/unixodbc are meant to be configured by the system administrator (or the ODBC site administrator if appropriate privileges are granted to /etc/unixodbc). These files are not meant to be directly edited. The ODBC installer library is responsible for reading and writing the unixODBC config files.

Unfortunately, there are no man or info pages for the various programs available in the unixODBC package. Along with the information in the “Short Descriptions” below and the documentation installed in /usr/share/doc/unixODBC-2.2.11, there are many README files throughout the source tree where the use and functionality of the programs can be found. Additionally, you can use the parameter -? with the non-GUI tools for syntax and usage information. Lastly, the unixODBC web site at http://www.unixodbc.org/ has very good information.

Contents

Installed Programs: DataManager, DataManagerII, ODBCConfig, dltest, isql, iusql, odbc_config, odbcinst and odbctest
Installed Libraries: libboundparam.so, libesoobS.so, libgtrtst.so, libmimerS.so, libnn.so, libodbc.so, libodbccr.so, libodbcdrvcfg1S.so, libodbcdrvcfg2S.so, libodbcinst.so, libodbcinstQ.so, libodbcminiS.so, libodbcmyS.so, libodbcnnS.so, libodbcpsql.so, libodbcpsqlS.so, libodbctxt.so, libodbctxtS.so, liboplodbcS.so, liboraodbcS.so, libsapdbS.so, libtdsS.so and libtemplate.so
Installed Directories: /etc/unixodbc and /usr/share/doc/unixODBC-2.2.12

Short Descriptions

DataManager is a graphical program which can be used to browse/explore ODBC data sources.
DataManagerII is an enhanced version of DataManager.
ODBCConfig is a graphical program used to make configuration of ODBC data sources extremely easy.
dltest is a utility used to check a share library to see if it can be loaded and if a given symbol exists in it.
isql is a utility which can be used to submit SQL to a data source and to format/output results. It can be used in batch or interactive mode.
iusql provides the same functionality as the isql program.
odbc_config is used to find out details about the installation of the unixODBC package.
odbcinst is a utility created for install script/RPM writers. It is a command line interface to key functionality in the libodbcinst library. It does not copy any files (i.e., libraries) but it will modify the ODBC System Information for the user.
odbctest is a graphical program used to test the ODBC API.
Retrieved from "?title=UnixODBC&oldid=17289"