Changeset 8401

Show
Ignore:
Timestamp:
10/05/07 13:21:39 (1 year ago)
Author:
bdubbs
Message:

Added -mtune to Glibc CFLAGS

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/jh/BOOK/chapter01/changelog.xml

    r8400 r8401  
    3838 
    3939     <listitem> 
     40      <para>2007-10-05</para> 
     41      <itemizedlist> 
     42        <listitem> 
     43          <para>[bdubbs] - Added -mtune to Glibc CFLAGS.</para> 
     44        </listitem> 
     45      </itemizedlist> 
     46    </listitem> 
     47 
     48     <listitem> 
    4049      <para>2007-10-04</para> 
    4150      <itemizedlist> 
  • branches/jh/BOOK/chapter05/glibc.xml

    r8400 r8401  
    5656    Instead of overriding completely what Glibc's internal build system uses 
    5757    for CFLAGS, append the new flag to the existing contents of CFLAGS by 
    58     making use of the special file <filename>configparms</filename>:</para> 
    59  
    60 <screen><userinput remap="configure">uname -m | grep -q i[4-7]86 &amp;&amp; 
    61 echo "CFLAGS += -march=i486" &gt; configparms</userinput></screen> 
     58    making use of the special file <filename>configparms</filename>. The 
     59    -mtune=native flag is also necessary to reset a reasonable value for -mtune 
     60    that is changed when setting -march.</para> 
     61 
     62<screen><userinput remap="configure">if [ uname -m | grep -q i[4-7]86 ]; do 
     63  echo "CFLAGS += -march=i486" &gt; configparms 
     64done</userinput></screen> 
    6265 
    6366    <para>Next, prepare Glibc for compilation:</para> 
  • branches/jh/BOOK/chapter06/glibc.xml

    r8400 r8401  
    105105cd ../glibc-build</userinput></screen> 
    106106 
    107     <para>Again, add the needed compiler flag to CFLAGS for x86 machines:</para> 
    108  
    109 <screen><userinput remap="configure">uname -m | grep -q i[4-7]86 &amp;&amp; 
    110 echo "CFLAGS += -march=i486" &gt; configparms</userinput></screen> 
     107    <para>Again, add the needed compiler flags to CFLAGS for x86 machines:</para> 
     108 
     109<screen><userinput remap="configure">if [ uname -m | grep -q i[4-7]86 ]; do 
     110  echo "CFLAGS += -march=i486" &gt; configparms 
     111done</userinput></screen> 
    111112 
    112113    <para>Prepare Glibc for compilation:</para> 
  • branches/jh/BOOK/chapter06/introduction.xml

    r7970 r8401  
    2424  installed.</para> 
    2525 
    26   <para>If using compiler optimizations, please 
    27   review the optimization hint at <ulink url="&hints-root;optimization.txt"/>. 
    28   Compiler optimizations can make a program run slightly faster, but they may 
    29   also cause compilation difficulties and problems when running the program. 
    30   If a package refuses to compile when using optimization, try to compile it 
    31   without optimization and see if that fixes the problem. Even if the package 
    32   does compile when using optimization, there is the risk it may have been 
    33   compiled incorrectly because of the complex interactions between the code 
    34   and build tools.  Also note that the <option>-march</option> and 
    35   <option>-mtune</option> options may cause problems with the toolchain packages 
    36   (Binutils, GCC and Glibc).  The small potential gains achieved in using 
    37   compiler optimizations are often outweighed by the risks. First-time builders 
    38   of LFS are encouraged to build without custom optimizations. The subsequent 
    39   system will still run very fast and be stable at the same time.</para> 
     26  <para>If using compiler optimizations, please review the optimization hint at 
     27  <ulink url="&hints-root;optimization.txt"/>.  Compiler optimizations can make 
     28  a program run slightly faster, but they may also cause compilation 
     29  difficulties and problems when running the program.  If a package refuses to 
     30  compile when using optimization, try to compile it without optimization and 
     31  see if that fixes the problem. Even if the package does compile when using 
     32  optimization, there is the risk it may have been compiled incorrectly because 
     33  of the complex interactions between the code and build tools.  Also note that 
     34  the <option>-march</option> and <option>-mtune</option> options using values 
     35  not specified in the book have not been tested. This may cause problems with 
     36  the toolchain packages (Binutils, GCC and Glibc).  The small potential gains 
     37  achieved in using compiler optimizations are often outweighed by the risks. 
     38  First-time builders of LFS are encouraged to build without custom 
     39  optimizations. The subsequent system will still run very fast and be stable 
     40  at the same time.</para> 
    4041 
    4142  <para>The order that packages are installed in this chapter needs to be 
  • branches/jh/BOOK/general.ent

    r8399 r8401  
    11<?xml version="1.0" encoding="ISO-8859-1"?> 
    2 <!ENTITY version "SVN-JH-20071004"> 
    3 <!ENTITY releasedate "October 4, 2007"> 
     2<!ENTITY version "SVN-JH-20071005"> 
     3<!ENTITY releasedate "October 5, 2007"> 
    44<!ENTITY milestone "7.0"> 
    55<!ENTITY generic-version "development"> <!-- Use "development", "testing", or "x.y[-pre{x}]" -->