diff options
author | Randy Dunlap <randy.dunlap@oracle.com> | 2008-04-25 19:38:44 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-25 21:24:20 -0400 |
commit | 753d7054c318f323a7c135c71c68171a6b6a88fc (patch) | |
tree | f32efb19dc9b447eb488ec620c51546e140a0b9f | |
parent | 3dd7b71ca0f7ff8410a6b8cb15e5f670f90181e4 (diff) |
documentation: remove smart-config.txt
As requested by Sam Ravnborg: Remove Documentation/smart-config.txt.
It is outdated and has been (functionally) replaced by
Documentation/kbuild/*.txt.
Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | Documentation/00-INDEX | 2 | ||||
-rw-r--r-- | Documentation/smart-config.txt | 98 |
2 files changed, 0 insertions, 100 deletions
diff --git a/Documentation/00-INDEX b/Documentation/00-INDEX index a82a113b4a4b..1977fab38656 100644 --- a/Documentation/00-INDEX +++ b/Documentation/00-INDEX | |||
@@ -329,8 +329,6 @@ sgi-visws.txt | |||
329 | - short blurb on the SGI Visual Workstations. | 329 | - short blurb on the SGI Visual Workstations. |
330 | sh/ | 330 | sh/ |
331 | - directory with info on porting Linux to a new architecture. | 331 | - directory with info on porting Linux to a new architecture. |
332 | smart-config.txt | ||
333 | - description of the Smart Config makefile feature. | ||
334 | sound/ | 332 | sound/ |
335 | - directory with info on sound card support. | 333 | - directory with info on sound card support. |
336 | sparc/ | 334 | sparc/ |
diff --git a/Documentation/smart-config.txt b/Documentation/smart-config.txt deleted file mode 100644 index 8467447b5a87..000000000000 --- a/Documentation/smart-config.txt +++ /dev/null | |||
@@ -1,98 +0,0 @@ | |||
1 | Smart CONFIG_* Dependencies | ||
2 | 1 August 1999 | ||
3 | |||
4 | Michael Chastain <mec@shout.net> | ||
5 | Werner Almesberger <almesber@lrc.di.epfl.ch> | ||
6 | Martin von Loewis <martin@mira.isdn.cs.tu-berlin.de> | ||
7 | |||
8 | Here is the problem: | ||
9 | |||
10 | Suppose that drivers/net/foo.c has the following lines: | ||
11 | |||
12 | #include <linux/config.h> | ||
13 | |||
14 | ... | ||
15 | |||
16 | #ifdef CONFIG_FOO_AUTOFROB | ||
17 | /* Code for auto-frobbing */ | ||
18 | #else | ||
19 | /* Manual frobbing only */ | ||
20 | #endif | ||
21 | |||
22 | ... | ||
23 | |||
24 | #ifdef CONFIG_FOO_MODEL_TWO | ||
25 | /* Code for model two */ | ||
26 | #endif | ||
27 | |||
28 | Now suppose the user (the person building kernels) reconfigures the | ||
29 | kernel to change some unrelated setting. This will regenerate the | ||
30 | file include/linux/autoconf.h, which will cause include/linux/config.h | ||
31 | to be out of date, which will cause drivers/net/foo.c to be recompiled. | ||
32 | |||
33 | Most kernel sources, perhaps 80% of them, have at least one CONFIG_* | ||
34 | dependency somewhere. So changing _any_ CONFIG_* setting requires | ||
35 | almost _all_ of the kernel to be recompiled. | ||
36 | |||
37 | Here is the solution: | ||
38 | |||
39 | We've made the dependency generator, mkdep.c, smarter. Instead of | ||
40 | generating this dependency: | ||
41 | |||
42 | drivers/net/foo.c: include/linux/config.h | ||
43 | |||
44 | It now generates these dependencies: | ||
45 | |||
46 | drivers/net/foo.c: \ | ||
47 | include/config/foo/autofrob.h \ | ||
48 | include/config/foo/model/two.h | ||
49 | |||
50 | So drivers/net/foo.c depends only on the CONFIG_* lines that | ||
51 | it actually uses. | ||
52 | |||
53 | A new program, split-include.c, runs at the beginning of | ||
54 | compilation (make bzImage or make zImage). split-include reads | ||
55 | include/linux/autoconf.h and updates the include/config/ tree, | ||
56 | writing one file per option. It updates only the files for options | ||
57 | that have changed. | ||
58 | |||
59 | Flag Dependencies | ||
60 | |||
61 | Martin Von Loewis contributed another feature to this patch: | ||
62 | 'flag dependencies'. The idea is that a .o file depends on | ||
63 | the compilation flags used to build it. The file foo.o has | ||
64 | its flags stored in .flags.foo.o. | ||
65 | |||
66 | Suppose the user changes the foo driver from resident to modular. | ||
67 | 'make' will notice that the current foo.o was not compiled with | ||
68 | -DMODULE and will recompile foo.c. | ||
69 | |||
70 | All .o files made from C source have flag dependencies. So do .o | ||
71 | files made with ld, and .a files made with ar. However, .o files | ||
72 | made from assembly source do not have flag dependencies (nobody | ||
73 | needs this yet, but it would be good to fix). | ||
74 | |||
75 | Per-source-file Flags | ||
76 | |||
77 | Flag dependencies also work with per-source-file flags. | ||
78 | You can specify compilation flags for individual source files | ||
79 | like this: | ||
80 | |||
81 | CFLAGS_foo.o = -DSPECIAL_FOO_DEFINE | ||
82 | |||
83 | This helps clean up drivers/net/Makefile, drivers/scsi/Makefile, | ||
84 | and several other Makefiles. | ||
85 | |||
86 | Credit | ||
87 | |||
88 | Werner Almesberger had the original idea and wrote the first | ||
89 | version of this patch. | ||
90 | |||
91 | Michael Chastain picked it up and continued development. He is | ||
92 | now the principal author and maintainer. Please report any bugs | ||
93 | to him. | ||
94 | |||
95 | Martin von Loewis wrote flag dependencies, with some modifications | ||
96 | by Michael Chastain. | ||
97 | |||
98 | Thanks to all of the beta testers. | ||