Compiling/testing in 32-bit on Ubuntu X86-64

Last update on December 7, 2008 08:58 AM by netty5
Published by netty5

Compiling/testing in 32-bit on Ubuntu X86-64





If you want compile a source code for testing purpose or to use it as a 32-bit binary,the main problem is that the headers of the standard library are not suitable for this purpose and that a version of the standard library in 32 bits is needed. (specific gcc library compiled in 32 bits).

To install these packages, type this command:
sudo apt-get install gcc-multilib libc6-i386 lib6-dev-i386


To compile your program so we were just attach the-m32:

gcc -m32 test.c -o test


This will be enough for a simple program using only the standard library but for programs using other libraries,all these libraries must be compile in 32-bit too.
Best answers for « Compiling/testing in 32 bit on Ubuntu X86 64 » in :
How to use a driver ODBC 32 BITS under the Window 2003(64 bits)? ShowHow to use a driver ODBC 32 BITS under the Window 2003(64 bits)? You have a Windows 2003 server (64-bits) and you want to use a 32 bits ODBC driver: one that is usually found in the administrative panel for ODBC on Windows or an external...
Converting a 32-bit integer into IP ShowConverting a 32-bit integer into IP Number to convert: 3265917058 Binary representation 11000010 10101001 11110000 10000010 - 3265917058 00000000 00000000 00000000 11000010 - 3265917058 >> 24 ( 194 ) 11000010 10101001 11110000...
Compiling an assembly program with Nasm ShowCompiling an assembly program with Nasm Intro With LInux With Windows Intro Netwide Assembler (NASM) is an assembler and disassembler for the Intel x86 architecture and is commonly used to create 16-bit, 32-bit (IA-32) and 64-bit...
Download ATI Catalyst Software Suite for Vista (32 bit) ShowThe latest release for ATI drivers for windows Vista regrouping the following features and option: Catalyst Control Center Version 8.9 Radeon display driver 8.522 HydraVision WDM Driver Install Bundle Southbridge/IXP...
Rundll32 - rundll32.exe Showrundll32 - rundll32.exe rundll32.exe (rundll32 stands for Run a DLL as a 32-bit application) is a Windows NT/2000/XP generic process used for loading dynamic link libraries (DLLs) in memory so that other programs can use them. The file that...
The PC Card bus (PCMCIA) ShowPC Card Bus Introduction The PC Card bus was developed in 1989 by the PCMCIA (Personal Computer Memory Card International Association, which is the name sometimes given to the bus) consortium in order to extend current peripheral equipment...