Re: f7 32bit/64bit compiles.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2007-07-18 at 16:55 -0600, clemens@xxxxxxx wrote:
> OK, a dumb question, but Ive always just assumed that all my machines were
> 32bit, and ignored 64bit stuff.
> 
> Now more than 1/2 are 64bit.
> 
> So the dumb question: How do you compile in 64bit mode?
> Im sure its there in the gcc man page, but after scanning the first
> 20-30pages Im about to go to sleep...
> 
> And, is there some place to put this so that gcc ALWAYS compiles
> in 64bit mode?  Or does so by default.
> 
> Or does gcc look at the machine architecture and make a decision on
> its own.
> 
> So, a quick discussion of the niceties of 32/64bit compiling would be
> appreciated.

A 64-bit machine by default compiles 64 bit code.  Conversely, a 32-bit
machine compiles 32-bit stuff.

You can force a 64-bit machine to build 32-bit stuff, specify
"-march=i686" or similar thing.  "-m32" is similar, but doesn't optimize
for 686 processors (more of a "generic 32-bit" switch).

So, unless you have a specific need to compile for a 32-bit environment
on a 64-bit system, don't worry about it.  The compiler will sort it out
for you.
----------------------------------------------------------------------
- Rick Stevens, Principal Engineer             rstevens@xxxxxxxxxxxx -
- VitalStream, Inc.                       http://www.vitalstream.com -
-                                                                    -
-           Give me ambiguity or give me something else!             -
----------------------------------------------------------------------


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux