Le 25/11/2012 23:38, Ken Moffat a écrit :
> On Sun, Nov 25, 2012 at 11:04:01PM +0100, Pierre Labastie wrote:
>
>> At this place in the book, everything should be independant on what is
>> on the host, shouldn't it ? librt and libpthread are both from glibc. I
>> more suspect the optimization, as pointed out by Armin. Trying again
>> without optimization and I'll let you know  (build takes much longer).
>>
>> Regards,
>> Pierre
>   Are you sure it takes longer ?  Most packages default their CFLAGS,
> CXXFLAGS to '-O2 -g' : using -O3 is *expected* to take longer.
>
>   To be clear, don't set CFLAGS, CXXFLAGS if you want to avoid
> problematic optimisations, just let the packages use their own
> defaults.  Building with "CFLAGS= " and the same for CXXFLAGS will
> turn off all optimisations (if a package accepts that from its
> environment), but for e.g. gcc I *would* expect the resulting
> compilers to be *slow*.
>
> ĸen
Hi,

First, I confirm that without any flag, everything went well.
You are right that -O3 is expected to take longer. I wrote to rapidly.
I suppressed all the optimization, even the -j flag in make. That's
what makes it longer. Marginally, -pipe is supposed to increase speed
too. I guess it was that flag that was wrong in the present case.
I need more testing to confirm that.

Sorry for the noise, but I had been building with these optimizations
(-O3 -march=native -pipe) for years and they seemed innocuous.
I had forgotten about them.

Pierre
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to