Click to See Complete Forum and Search --> : make - is it smart?


micro
04-05-2005, 07:59 PM
Trying to compile 2.6.11.6 kernel for my notebook - which runs on the slackware 10.1 distro with kernel 2.4.29 - I was frightened again about all the configuration that I would have to make things go.

For once I decided to do some automation. Without having a .config file, I issued: make oldconfig.

The routine started asking me and I kept <enter> pressed letting it decide by itself.

Making menuconfig just after this, I saw that all must have been configured well, in fact too well.

PCI and IDE: All relevant code is inside the kernel.
Filesystems: ext2 and 3 are inside.
Codepages: 437 and 737 inside, all others as modules.
Graphics: Framebuffer on, vga inside, agp_via as module.
Sound: Alsa default, via as module.
Network: TCP-IP inside, via-rhine as module

etc. etc.

The impressive thing is that while the routine was very economic in selecting modules, it didn't miss even one critical issue.

How did it know about the 737 (greek) codepage to compile inside???

For experimentation's sake I am compiling with this configuration.

Have you found the make routine to be that smart in other occasions?

Hayl
04-05-2005, 08:02 PM
make oldconfig doesn't (or isn't supposed to) do anything but take all the defaults unless you copy an old .config file into the kernel sources you are issuing the make oldconfig against. in which case it merges the old .config with any new kernel options intelligently.

regular software - the make command is not smart.

the only reason the make oldconfig works is because there is a script for it in the kernel sources.

micro
04-05-2005, 08:32 PM
I checked this issue against another computer and I have to say that the "miracles" I described previously didn't happen again.

But, all necessary defaults have been chosen correctly, which means that it is a good method not to start from scratch.

One correction though to the first post:
Device drivers - graphics support - console display driver support: Framebuffer support was a module.

The kernel did start correctly but without high resolution consoles. I fixed it and now it runs ok. If I started tweaking from scratch I would still make choices. At least this method proves to be quicker.

bwkaz
04-06-2005, 06:45 PM
Originally posted by micro
Without having a .config file, I issued: make oldconfig. How well did you make sure you had no .config file? Did you ls -a, or just ls?

micro
04-06-2005, 08:26 PM
ls -a

No .config file was present.
The case I saw too well guessed options happened only once. I couldn't reproduce it to another computer in the network.

But nevertheless, the standard make oldconfig behavior, which I am sure of, makes a .config file from scratch suitable enough for a standard pci-ide computer. This saves a lot of time. Afterwards we can revisit it with make menuconfig to fine tune just our extra needs.

If we configure the framebuffer support to be built-in (inside drivers-graphics support - console) then the kernel will be ready for high resolution consoles.