Visit Our UNIX and Linux User Community

porting an application on 64-bit AIX version 5

Thread Tools Search this Thread
Operating Systems AIX porting an application on 64-bit AIX version 5
# 8  
Old 10-03-2007

gcc -m64 isnt working,says no such option
and for xlc -q64 it says
xlc: cannot retrieve message number 1501-221
any idea?
# 9  
Old 10-04-2007
Your nls path is not set, that is why your not able to see message.
I did porting a application on AIX 5.3. I used

xlc_r -q64 -qwarn64

try to use these options.
# 10  
Old 10-04-2007

hey great,
can you tell me some points on porting application to 64 bit.It is a combination of 32-bit and 64-bit executables,was running fine on 32-bit AIX but we need to run that on 64 bit.What are the main changes we need to make.
# 11  
Old 10-05-2007
how do i differentiate between an AIX 64 bit and AIX 32 bit using a single command.
I tried versions of uname but it only gives some arbitrary results.for other OS uname -m did work but for AIX it aint working.
any help?
# 12  
Old 10-05-2007
Originally Posted by vishalzone2002
It is a combination of 32-bit and 64-bit executables,was running fine on 32-bit AIX but we need to run that on 64 bit.
Not in the same process, in a single process all loaded binaries have to be either 32bit or 64bit.

Other than that, operating systems like Irix and Solaris use a differenet lib path variable in 64 bit compared to 32 bit. What AIX does is have both 32 bit and 64 bit code in a single shared library, the shared library is actually a normal archive file with a "shr.o" for 32 bit, and a "shr64.o" for 64 bit, both the linker and loader are supposed to sort out what is expected based on the current "mode".
# 13  
Old 10-05-2007
You can always check what compilation environment is available to you by means of the sysconf() function.

_SC_XBS5_ILP32_OFF32 Implementation provides a C-language compilation environment
with 32-bit int, long, pointer and off_t types.
_SC_XBS5_ILP32_OFFBIG Implementation provides a C-language compilation environment
with 32-bit int, long and pointer types and an off_t type
using at least 64 bits.
_SC_XBS5_LP64_OFF64 Implementation provides a C-language compilation environment
with 32-bit int and 64-bit long, pointer and off_t types.
_SC_XBS5_LPBIG_OFFBIG Implementation provides a C-language compilation environment
with an int type using at least 32 bits and long, pointer
and off_t types using at least 64 bits.

Man sysconf for further information.
# 14  
Old 10-09-2007
use following command

#bootinfo -K, if it is 64-bit kernel it will give you 64.

further you can run #file <filename> command on AIX to see whether
the binary it 32-bit or 64-bit. If you have both in one library ared
with ar command then try following commands

dump <binaryfilename>
nm <binaryfilename>

use man pages to learn more about these commands, there are options to
see the symbols too (i.e. 32-bit symbols and 64-bit symbols)

Previous Thread | Next Thread
Test Your Knowledge in Computers #441
Difficulty: Easy
"Hotel California" by the Eagles is a song about a super A.I. who goes rouge and parties all day and night.
True or False?

9 More Discussions You Might Find Interesting

1. Windows & DOS: Issues & Discussions

Which version of Windows Vista to install with a product key? 32-bit or 64-bit?

Hello everyone. I bought a dell laptop (XPS M1330) online which came without a hard drive. There is a Windows Vista Ultimate OEMAct sticker with product key at the bottom case. I checked dell website (here) for this model and it says this model supports both 32 and 64-bit version of Windows... (4 Replies)
Discussion started by: milhan
4 Replies

2. Solaris

Porting graphical Solaris application to Linux

I don't expect any quick answers, but if people have links to resources I can investigate I'd be extremely appreciative. Here is what we have today: The "application" is a multi-process train control system that uses the Unix desktop, currently CDE, several motif-based applications and sound,... (8 Replies)
Discussion started by: paz9
8 Replies

3. Red Hat

Unable to install 32 bit application on 64 bit OS

Hi, I am new to Linux OS. My question is that "is it possible to install 32 Bit application on 64 Bit OS?" I have the following Redhat OS on VMware workstation. OS - Red Hat Enterprise Linux Server release 6.2 | 2.6.32-220.el6.x86_64 While installing the application I am getting the... (2 Replies)
Discussion started by: poga
2 Replies

4. SuSE

64 bit Porting Problem !!!

Dear All, I am trying to build my code (currently functioning on 32bit) on 64 bit SUSE machine. I am getting following error: warning: initializer element is not computable at load time dau.gss.c:275: error: initializer element is not constant dau.gss.c:275: error: (near initialization for... (10 Replies)
Discussion started by: skaushal.schip
10 Replies

5. Red Hat

No Error for 64-bit porting

I am just trying to get the warning while compiling for 64-bit on Linux >> uname -a Linux 2.6.9-22.ELsmp #1 SMP Mon Sep 19 18:00:54 EDT 2005 x86_64 x86_64 x86_64 GNU/Linux =================================== Written test.c file which conatin : #include<stdio.h>... (1 Reply)
Discussion started by: amit_27
1 Replies

6. Linux

Is it possible to compile 64 bit application on 32 bit machine

Hi, I am using 32 bit machine, and I want to compile 64 bit application on 32-bit machine. So please tell me is it possible or not? Regards Mandar (7 Replies)
Discussion started by: Mandar123
7 Replies

7. Solaris

Porting C++ 32-bit code on 64-bit Solaris

Hi, I am trying to convert 32-bit code to 64-bit. I have defined function int main() { int* l; size_t len1; fun(len1); return 0; } void fun(int* ptr) { cout<<"\nsizeof(ptr)"<<sizeof(ptr); } However while compiling getting error as : Error: Formal argument ptr... (2 Replies)
Discussion started by: amit_27
2 Replies

8. Gentoo

compiling 32 bit application on 64 bit linux(x86_64)

hi all, i have a 64 bit linux machine. $uname -a Linux SVRDELLD30 2.6.9-42.ELsmp #1 SMP Tue Aug 15 10:35:26 BST 2006 x86_64 x86_64 x86_64 GNU/Linux here by default gcc creates 64 bit executable. but for some reason i want to create 32bit executable. first i want to create 32 bit object... (3 Replies)
Discussion started by: uttamhoode
3 Replies

9. Programming

Porting Win32 application into Linux

I need port Win32 console application, which was developed with MS Visual Studio 6.0 (without MFC using) into Linux. What is the best way to port project? Are there any standard tools or decisions? Thank you in advance, Sergey (0 Replies)
Discussion started by: Sergeyy
0 Replies

Featured Tech Videos