1 |
On Fri, Dec 19, 2014 at 02:38:48AM +0400, German wrote |
2 |
> Couldn't find those in documentation. Thank you |
3 |
|
4 |
If you're building on the target machine, use the "native" CFLAG. It |
5 |
has been around for a while. It detects the CPU, and builds for it |
6 |
"automagically". You don't have to do any more grunt work, figuring out |
7 |
the flags for your CPU. Computers are supposed to do the hard work. I |
8 |
use... |
9 |
|
10 |
FLAGS="-O2 -march=native -mfpmath=sse -fomit-frame-pointer -pipe -fno-unwind-tables -fno-asynchronous-unwind-tables" |
11 |
CXXFLAGS="${CFLAGS}" |
12 |
|
13 |
Mind you, if you're cross-compiling on another system, and then moving |
14 |
the binaries over, you will have to figure out the correct flags. See |
15 |
below for a method. |
16 |
|
17 |
Another problem is that there are also cpu-specific USE flags. You |
18 |
can get a good start on figuring them out, as well as CFLAGS, by running |
19 |
|
20 |
grep flags /proc/cpuinfo |
21 |
|
22 |
on the target machine. There will be one line of output for each core. |
23 |
You'll have multiple identical lines of output. |
24 |
|
25 |
-- |
26 |
Walter Dnes <waltdnes@××××××××.org> |
27 |
I don't run "desktop environments"; I run useful applications |