- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- 64/32 bits problem compiling with Oracle libraries
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2004 04:06 AM
тАО06-09-2004 04:06 AM
I have the following setup:
$ uname -a
HP-UX HPSPPS3W B.11.00 U 9000/861 2004611039 unlimited-user license
Oracle 9.2.0
When I try to compile a very simple program using the proC compiler I got the error:
$ aCC -L$ORACLE_HOME/lib -lclntsh cprograma2.c
/usr/ccs/bin/ld: /icb/oracle9/app/oracle/product/9.2.0/lib/libclntsh.sl: Mismatched ABI. 64-bit PA shared library found in 32-bit l.
If I do the same but 32 bits libraries from Oracle it works fine:
$ aCC -L$ORACLE_HOME/lib32 -lclntsh cprograma2.c
$ a.out
Connected to ORACLE as user: IC
Cosa leida : 0x400012e8
Have a nice day!
But if I try to force 64 bit compilation its compile/link OK but I get the following error:
$ aCC +DD64 -L$ORACLE_HOME/lib -lclntsh cprograma2.c
$ a.out
Bus error(coredump)
I would like the program working in 64 bits, or at least understand why is compiling but not working properly.
Could anyone help, please?
Thank you very much.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2004 04:38 AM
тАО06-09-2004 04:38 AM
Re: 64/32 bits problem compiling with Oracle libraries
getconf KERNEL_BITS
then, if this verifies to be 64 bits, are you sure you have the oracle 64 bit binaries installed on your server.
UNIX because I majored in cryptology...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2004 04:42 AM
тАО06-09-2004 04:42 AM
Re: 64/32 bits problem compiling with Oracle libraries
64
Regarding the Oracle executables as far as I knos Oracle 9.2.0 is only distributed in 64 bit version.
64 bits Libraries are in lib and 32 bit libraries are in lib32
Thank you for your prompt response.
Lorenzo.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2004 04:48 AM
тАО06-09-2004 04:48 AM
Re: 64/32 bits problem compiling with Oracle libraries
I am not sure what the solution would be in short of reinstalling oracle.
UNIX because I majored in cryptology...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2004 04:58 AM
тАО06-09-2004 04:58 AM
Re: 64/32 bits problem compiling with Oracle libraries
Do you know how or where may I check the aCC libraries that may be in use? How do I know if a library is 36/64 bits?
Also I have read something about 32/64 bits versions of the aCC compiler. Could this have something to do with the problem? I guess that may be 32 bits version of the compiler are distributed with older operating systems and that on 11.0/64 bits the compiler version should be 64 bits but I am not sure.
Do you know any way to know the bits of the compiler version?
The compiler is:
what /opt/aCC/bin/aCC
/opt/aCC/bin/aCC:
$Revision: 92453-07 linker linker crt0.o B.11.16.01 030316 $
HP aC++ B3910B A.03.55
HP aC++ B3910B X.03.37.01 Language Support Library
$
Thank you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2004 05:07 AM
тАО06-09-2004 05:07 AM
Re: 64/32 bits problem compiling with Oracle libraries
LD_LIBRARY_PATH and SHLIB_PATH set to?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2004 05:12 AM
тАО06-09-2004 05:12 AM
SolutionPROBLEM
=======
When you try to relink cppdemo1 sample proc program
under $ORACLE_HOME/precomp/demo/proc
make -f demo_proc.mk cppdemo1
you get the following error
exit error code 1
libclntsh.sl mismatched ABI 64 bit pa risc
shared library found in 32 bit link
SOLUTION
=========
step 1
-------
under $ORACLE_HOME/precomp/demo/proc
edit demo_proc.mk
step 2
-------
Under " include env_precomp.mk " statement
insert the following line:
CC=aCC +DA2.0w
step 3
-------
change the cppbuild and cppbuild_static targets
from:
...
cppbuild:
$(PROC) $(PROCPPFLAGS) iname=$(EXE)
CC -c $(INCLUDE) $(EXE).c
CC -o $(EXE) $(OBJS) -L$(LIBHOME) $(CPPLDLIBS)
cppbuild_static:
$(PROC) $(PROCPPFLAGS) iname=$(EXE)
CC -c $(INCLUDE) $(EXE).c
CC -o $(EXE) $(OBJS) -L$(LIBHOME) $(STATICCPPLDLIBS)
to
cppbuild:
$(PROC) $(PROCPPFLAGS) iname=$(EXE)
$(CC) -c $(INCLUDE) $(EXE).c
$(CC) -o $(EXE) $(OBJS) -L$(LIBHOME) $(CPPLDLIBS)
cppbuild_static:
$(PROC) $(PROCPPFLAGS) iname=$(EXE)
$(CC) -c $(INCLUDE) $(EXE).c
$(CC) -o $(EXE) $(OBJS) -L$(LIBHOME) $(STATICCPPLDLIBS)
That is
from
.... CC ....
to
....$(CC) ....
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2004 05:13 AM
тАО06-09-2004 05:13 AM
Re: 64/32 bits problem compiling with Oracle libraries
$ echo $LD_LIBRARY_PATH
/icb/oracle9/app/oracle/product/9.2.0/lib:/lib:/usr/lib:/icb/oracle9/app/oracle/product/9.2.0
$ echo $SHLIB_PATH
ORACLE_HOME/lib32:/icb/oracle9/app/oracle/product/9.2.0/rdbms/lib32
However I have managed to use the demo makefile that cames with Oracle instad of trying to do the compilation directly through command line and it works, so I consider closed the case.
I appreciate sincerely your help and interest.