This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Python module cx_Oracle ld installation issue on Solaris11U3 SPARC: fatal: file /oracle/database/lib/libclntsh.so: wrong ELF class: ELFCLASS64 error
Type: compile error Stage: resolved
Components: Installation Versions: Python 2.7
process
Status: closed Resolution: third party
Dependencies: Superseder:
Assigned To: Nosy List: berker.peksag, sameernatekar
Priority: normal Keywords:

Created on 2017-05-24 10:56 by sameernatekar, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Messages (2)
msg294344 - (view) Author: sameer natekar (sameernatekar) Date: 2017-05-24 10:56
Trying to install cx_Oracle on Solaris11U3 but getting ld: fatal: file /oracle/database/lib/libclntsh.so: wrong ELF class: ELFCLASS64 error
 
# python setup.py build
running build
running build_ext
building 'cx_Oracle' extension
cc -DNDEBUG -KPIC -DPIC -I/oracle/database/rdbms/demo -I/oracle/database/rdbms/public -I/usr/include/python2.7 -c cx_Oracle.c -o build/temp.solaris-2.11-sun4v.32bit-2.7-11g/cx_Oracle.o -DBUILD_VERSION=5.2.1
"SessionPool.c", line 202: warning: integer overflow detected: op "<<"
cc -G build/temp.solaris-2.11-sun4v.32bit-2.7-11g/cx_Oracle.o -L/oracle/database/lib -L/usr/lib -lclntsh -lpython2.7 -o build/lib.solaris-2.11-sun4v.32bit-2.7-11g/cx_Oracle.so
ld: fatal: file /oracle/database/lib/libclntsh.so: wrong ELF class: ELFCLASS64
error: command 'cc' failed with exit status 2
 
Tried all available information on the internet:
Installed gcc
Installed solarisstudio12.4
Installed instantclient-basic-solaris.sparc64-12.2.0.1.0, instantclient-odbc-solaris.sparc64-12.2.0.1.0
Set LD_LIBRARY_PATH to oracle home directory:instantclient_12_2/
 
Same issue seen while installing DBD:Oracle perl module.
msg298922 - (view) Author: Berker Peksag (berker.peksag) * (Python committer) Date: 2017-07-24 00:34
cx_Oracle is not part of the Python standard library and according to https://community.oracle.com/thread/4048639 the solution is to install it from Solaris' package repository.
History
Date User Action Args
2022-04-11 14:58:46adminsetgithub: 74639
2017-07-24 00:34:18berker.peksagsetstatus: open -> closed

nosy: + berker.peksag
messages: + msg298922

resolution: third party
stage: resolved
2017-05-24 10:56:57sameernatekarcreate