Skip to content

Instantly share code, notes, and snippets.

@lsgalves
Last active April 3, 2023 09:50
Show Gist options
  • Save lsgalves/337fac19a219409350768d9250422a23 to your computer and use it in GitHub Desktop.
Save lsgalves/337fac19a219409350768d9250422a23 to your computer and use it in GitHub Desktop.
Install latest Firebird ODBC Driver (2.0.5) on RHEL
#!/bin/bash
set -e
if [ "$EUID" -ne 0 ]
then echo "Need run as root"
exit 1
fi
# Install libfbclient
yum install -y libfbclient2
# Install ODBC Firebird Driver
wget https://ufpr.dl.sourceforge.net/project/firebird/firebird-ODBC-driver/2.0.5-Release/OdbcFb-LIB-2.0.5.156.amd64.gz
tar -xzf OdbcFb-LIB-2.0.5.156.amd64.gz
rm -f OdbcFb-LIB-2.0.5.156.amd64.gz
chmod +x libOdbcFb.so
mv -f libOdbcFb.so /usr/local/lib64/libodbcfb.so
# Create symlinks
cd /usr/lib64/
ln -s libodbcinst.so.2.0.0 libodbcinst.so.1
ln -s libfbclient.so.2 libgds.so
cat << EOT >> /etc/odbcinst.ini
[Firebird]
Description = InterBase/Firebird ODBC Driver
Driver = /usr/local/lib64/libodbcfb.so
Setup = /usr/local/lib64/libodbcfb.so
Threading = 1
FileUsage = 1
CPTimeout =
CPReuse =
EOT
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment