Re: [cx-oracle-users] Help/Advice installing cx_oracle on El Capitan
Brought to you by:
atuining
|
From: Kubo T. <ku...@ji...> - 2015-10-21 14:04:42
|
On Wed, Oct 21, 2015 at 9:51 PM, greg <mar...@gm...> wrote:
> ImportError:
> dlopen(/Users/me/sx_direct_env/lib/python2.7/site-packages/cx_Oracle.so,
> 2): Library not loaded: /b/227/rdbms/lib/libclntsh.dylib.10.1
> Referenced from:
> /Users/me/sx_direct_env/lib/python2.7/site-packages/cx_Oracle.so
> Reason: image not found
The cx_Oracle.so is linked with Oracle 10g instant client because it depends
on libclntsh.dylib.10.1.
> $ export ORACLE_HOME=$PWD
> $ export DYLD_LIBRARY_PATH=$ORACLE_HOME
> $ export LD_LIBRARY_PATH=$ORACLE_HOME
> $ export PATH=$PATH:$ORACLE_HOME
IMO, Oracle 10g client is in the $PATH before $ORACLE_HOME.
Could you swap the order as follows?
$ export PATH=$ORACLE_HOME:$PATH
> $ ruby -a fix_oralib.rb
> adrci:
> add rpath: @loader_path
> change install name
> from: /ade/b/3071542110/oracle/rdbms/lib/libclntsh.dylib.11.1
> to: @rpath/libclntsh.dylib.11.1
It uses relative path. Use -a option or --absolute-path option after
fix_oralib.rb as follows.
$ ruby fix_oralib.rb -a
And then uninstall cx_oracle and reinstall it.
$ pip uninstall cx_oracle
$ pip install cx_oracle
|