Skip to content

Instantly share code, notes, and snippets.

@azadkuh
Last active August 29, 2015 13:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save azadkuh/8957344 to your computer and use it in GitHub Desktop.
Save azadkuh/8957344 to your computer and use it in GitHub Desktop.
a mini howto for installing Oracle client in ubuntu server and compiling Qt OCI plugin.

Oracle Client install in Ubuntu server

(for Qt developers)

installation needs the following procedures:

1. download

download rpm of Instant Client for Linux x86-64 from this link oracle site.

list of required packages:

  • Basic
  • SDK
  • odbc (optional)

2. convert to deb

convert rpm to deb by (Oracle's rpms):
$>sudo alien blah.rpm

3. install oracle client

install deb packages by:
$>sudo dpkg -i blah.deb

4. install libaio1

Oracle's client library (.so files) depend on libaio1:
$>sudo apt-get install libaio1

5. add to the path

make sure Oracle's libs are added to LD_LIBRARY_PATH by:

$>sudo su
$>echo "path/to/oracle/client/libs" > /etc/ld.so.conf.d/oracle.conf
$>ldconf

6. compile Qt OCI

compile Qt OCI plugin as described in Qt docs: Qt doc 4.8 the output shoulb be somthing like libqsqloci.so

7. copy to qt plugins

copy (or link) the compiled *.so file to: $>cp libqsqloci.so /usr/lib/x86_64-linux-gnu/qt4/plugins/sqldrivers
or any other path on your system which contains other Qt SQL drivers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment