I'm interested in learning how PCLOS is built, and to see if it is possibly worthwhile compiling
my own kernel tailored to my specific hardware.
Here's some specific questions after reading your reply:
1. What's a spec file? How can I find one for any specific PCLOS package (not just a kernel)?
A spec file is the build instructions that are used to build the rpm. It is in the src.rpm.
2. The gcc manual page says -fomit-frame-pointer is on automatically for -O, -O2, and -O3. Isn't it redundant to specifically include it?
Probably, but sometimes things are listed explicitly so that whoever builds the packages remembers what is selected by default. (This is a just a guess on my part.)
3. Since I have a i686, presumably I would get some gain by compiling my own kernel with -march=native.
I believe Tex found that the difference between a kernel built with i586 and i686 was insignificant. You could certainly try for yourself, though.
4. Why isn't -O3 used instead of -O2?
Originally, -03 was risky, I think. I am not sure that is true now, if it ever was. Again, it may also be the difference in the kernels was not significant.
Just wondering, I don't pretend to know what's right....
Good questions. Although, I've built quite a few kernels, I've not played with these options before.