diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-23 18:37:02 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-23 18:37:02 -0400 |
| commit | c37efa932598de5e30330a1414e34d9e082e0d9e (patch) | |
| tree | 1e3b782d257fa39a54f583af3dc7c32d7cffc67d /scripts | |
| parent | 9e12a7e7d89ad813d01092890010cf67d0f914bd (diff) | |
| parent | abe1ee3a221d53778c3e58747bbec6e518e5471b (diff) | |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-next
* git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-next: (30 commits)
Use macros for .data.page_aligned section.
Use macros for .bss.page_aligned section.
Use new __init_task_data macro in arch init_task.c files.
kbuild: Don't define ALIGN and ENTRY when preprocessing linker scripts.
arm, cris, mips, sparc, powerpc, um, xtensa: fix build with bash 4.0
kbuild: add static to prototypes
kbuild: fail build if recordmcount.pl fails
kbuild: set -fconserve-stack option for gcc 4.5
kbuild: echo the record_mcount command
gconfig: disable "typeahead find" search in treeviews
kbuild: fix cc1 options check to ensure we do not use -fPIC when compiling
checkincludes.pl: add option to remove duplicates in place
markup_oops: use modinfo to avoid confusion with underscored module names
checkincludes.pl: provide usage helper
checkincludes.pl: close file as soon as we're done with it
ctags: usability fix
kernel hacking: move STRIP_ASM_SYMS from General
gitignore usr/initramfs_data.cpio.bz2 and usr/initramfs_data.cpio.lzma
kbuild: Check if linker supports the -X option
kbuild: introduce ld-option
...
Fix trivial conflict in scripts/basic/fixdep.c
Diffstat (limited to 'scripts')
| -rw-r--r-- | scripts/Kbuild.include | 16 | ||||
| -rw-r--r-- | scripts/Makefile.build | 6 | ||||
| -rw-r--r-- | scripts/basic/docproc.c | 34 | ||||
| -rw-r--r-- | scripts/basic/fixdep.c | 26 | ||||
| -rw-r--r-- | scripts/basic/hash.c | 4 | ||||
| -rwxr-xr-x | scripts/checkincludes.pl | 71 | ||||
| -rw-r--r-- | scripts/kconfig/conf.c | 24 | ||||
| -rw-r--r-- | scripts/kconfig/confdata.c | 2 | ||||
| -rw-r--r-- | scripts/kconfig/expr.c | 6 | ||||
| -rw-r--r-- | scripts/kconfig/gconf.c | 21 | ||||
| -rw-r--r-- | scripts/kconfig/gconf.glade | 4 | ||||
| -rw-r--r-- | scripts/kconfig/kxgettext.c | 4 | ||||
| -rw-r--r-- | scripts/kconfig/lkc_proto.h | 2 | ||||
| -rw-r--r-- | scripts/kconfig/mconf.c | 78 | ||||
| -rw-r--r-- | scripts/kconfig/menu.c | 84 | ||||
| -rw-r--r-- | scripts/kconfig/qconf.cc | 10 | ||||
| -rw-r--r-- | scripts/kconfig/symbol.c | 6 | ||||
| -rw-r--r-- | scripts/markup_oops.pl | 5 | ||||
| -rwxr-xr-x | scripts/tags.sh | 3 |
19 files changed, 235 insertions, 171 deletions
diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include index c29be8f90248..4f9c1908593b 100644 --- a/scripts/Kbuild.include +++ b/scripts/Kbuild.include | |||
| @@ -83,11 +83,12 @@ TMPOUT := $(if $(KBUILD_EXTMOD),$(firstword $(KBUILD_EXTMOD))/) | |||
| 83 | # is automatically cleaned up. | 83 | # is automatically cleaned up. |
| 84 | try-run = $(shell set -e; \ | 84 | try-run = $(shell set -e; \ |
| 85 | TMP="$(TMPOUT).$$$$.tmp"; \ | 85 | TMP="$(TMPOUT).$$$$.tmp"; \ |
| 86 | TMPO="$(TMPOUT).$$$$.o"; \ | ||
| 86 | if ($(1)) >/dev/null 2>&1; \ | 87 | if ($(1)) >/dev/null 2>&1; \ |
| 87 | then echo "$(2)"; \ | 88 | then echo "$(2)"; \ |
| 88 | else echo "$(3)"; \ | 89 | else echo "$(3)"; \ |
| 89 | fi; \ | 90 | fi; \ |
| 90 | rm -f "$$TMP") | 91 | rm -f "$$TMP" "$$TMPO") |
| 91 | 92 | ||
| 92 | # as-option | 93 | # as-option |
| 93 | # Usage: cflags-y += $(call as-option,-Wa$(comma)-isa=foo,) | 94 | # Usage: cflags-y += $(call as-option,-Wa$(comma)-isa=foo,) |
| @@ -105,12 +106,12 @@ as-instr = $(call try-run,\ | |||
| 105 | # Usage: cflags-y += $(call cc-option,-march=winchip-c6,-march=i586) | 106 | # Usage: cflags-y += $(call cc-option,-march=winchip-c6,-march=i586) |
| 106 | 107 | ||
| 107 | cc-option = $(call try-run,\ | 108 | cc-option = $(call try-run,\ |
| 108 | $(CC) $(KBUILD_CFLAGS) $(1) -c -xc /dev/null -o "$$TMP",$(1),$(2)) | 109 | $(CC) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) $(1) -c -xc /dev/null -o "$$TMP",$(1),$(2)) |
| 109 | 110 | ||
| 110 | # cc-option-yn | 111 | # cc-option-yn |
| 111 | # Usage: flag := $(call cc-option-yn,-march=winchip-c6) | 112 | # Usage: flag := $(call cc-option-yn,-march=winchip-c6) |
| 112 | cc-option-yn = $(call try-run,\ | 113 | cc-option-yn = $(call try-run,\ |
| 113 | $(CC) $(KBUILD_CFLAGS) $(1) -c -xc /dev/null -o "$$TMP",y,n) | 114 | $(CC) $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) $(1) -c -xc /dev/null -o "$$TMP",y,n) |
| 114 | 115 | ||
| 115 | # cc-option-align | 116 | # cc-option-align |
| 116 | # Prefix align with either -falign or -malign | 117 | # Prefix align with either -falign or -malign |
| @@ -130,10 +131,15 @@ cc-fullversion = $(shell $(CONFIG_SHELL) \ | |||
| 130 | # Usage: EXTRA_CFLAGS += $(call cc-ifversion, -lt, 0402, -O1) | 131 | # Usage: EXTRA_CFLAGS += $(call cc-ifversion, -lt, 0402, -O1) |
| 131 | cc-ifversion = $(shell [ $(call cc-version, $(CC)) $(1) $(2) ] && echo $(3)) | 132 | cc-ifversion = $(shell [ $(call cc-version, $(CC)) $(1) $(2) ] && echo $(3)) |
| 132 | 133 | ||
| 134 | # cc-ldoption | ||
| 135 | # Usage: ldflags += $(call cc-ldoption, -Wl$(comma)--hash-style=both) | ||
| 136 | cc-ldoption = $(call try-run,\ | ||
| 137 | $(CC) $(1) -nostdlib -xc /dev/null -o "$$TMP",$(1),$(2)) | ||
| 138 | |||
| 133 | # ld-option | 139 | # ld-option |
| 134 | # Usage: ldflags += $(call ld-option, -Wl$(comma)--hash-style=both) | 140 | # Usage: LDFLAGS += $(call ld-option, -X) |
| 135 | ld-option = $(call try-run,\ | 141 | ld-option = $(call try-run,\ |
| 136 | $(CC) $(1) -nostdlib -xc /dev/null -o "$$TMP",$(1),$(2)) | 142 | $(CC) /dev/null -c -o "$$TMPO" ; $(LD) $(1) "$$TMPO" -o "$$TMP",$(1),$(2)) |
| 137 | 143 | ||
| 138 | ###### | 144 | ###### |
| 139 | 145 | ||
diff --git a/scripts/Makefile.build b/scripts/Makefile.build index 5c4b7a400c18..341b58902ffc 100644 --- a/scripts/Makefile.build +++ b/scripts/Makefile.build | |||
| @@ -206,7 +206,7 @@ cmd_modversions = \ | |||
| 206 | endif | 206 | endif |
| 207 | 207 | ||
| 208 | ifdef CONFIG_FTRACE_MCOUNT_RECORD | 208 | ifdef CONFIG_FTRACE_MCOUNT_RECORD |
| 209 | cmd_record_mcount = perl $(srctree)/scripts/recordmcount.pl "$(ARCH)" \ | 209 | cmd_record_mcount = set -e ; perl $(srctree)/scripts/recordmcount.pl "$(ARCH)" \ |
| 210 | "$(if $(CONFIG_64BIT),64,32)" \ | 210 | "$(if $(CONFIG_64BIT),64,32)" \ |
| 211 | "$(OBJDUMP)" "$(OBJCOPY)" "$(CC)" "$(LD)" "$(NM)" "$(RM)" "$(MV)" \ | 211 | "$(OBJDUMP)" "$(OBJCOPY)" "$(CC)" "$(LD)" "$(NM)" "$(RM)" "$(MV)" \ |
| 212 | "$(if $(part-of-module),1,0)" "$(@)"; | 212 | "$(if $(part-of-module),1,0)" "$(@)"; |
| @@ -216,6 +216,7 @@ define rule_cc_o_c | |||
| 216 | $(call echo-cmd,checksrc) $(cmd_checksrc) \ | 216 | $(call echo-cmd,checksrc) $(cmd_checksrc) \ |
| 217 | $(call echo-cmd,cc_o_c) $(cmd_cc_o_c); \ | 217 | $(call echo-cmd,cc_o_c) $(cmd_cc_o_c); \ |
| 218 | $(cmd_modversions) \ | 218 | $(cmd_modversions) \ |
| 219 | $(call echo-cmd,record_mcount) \ | ||
| 219 | $(cmd_record_mcount) \ | 220 | $(cmd_record_mcount) \ |
| 220 | scripts/basic/fixdep $(depfile) $@ '$(call make-cmd,cc_o_c)' > \ | 221 | scripts/basic/fixdep $(depfile) $@ '$(call make-cmd,cc_o_c)' > \ |
| 221 | $(dot-target).tmp; \ | 222 | $(dot-target).tmp; \ |
| @@ -269,7 +270,8 @@ targets += $(extra-y) $(MAKECMDGOALS) $(always) | |||
| 269 | # Linker scripts preprocessor (.lds.S -> .lds) | 270 | # Linker scripts preprocessor (.lds.S -> .lds) |
| 270 | # --------------------------------------------------------------------------- | 271 | # --------------------------------------------------------------------------- |
| 271 | quiet_cmd_cpp_lds_S = LDS $@ | 272 | quiet_cmd_cpp_lds_S = LDS $@ |
| 272 | cmd_cpp_lds_S = $(CPP) $(cpp_flags) -D__ASSEMBLY__ -o $@ $< | 273 | cmd_cpp_lds_S = $(CPP) $(cpp_flags) -P -C -U$(ARCH) \ |
| 274 | -D__ASSEMBLY__ -DLINKER_SCRIPT -o $@ $< | ||
| 273 | 275 | ||
| 274 | $(obj)/%.lds: $(src)/%.lds.S FORCE | 276 | $(obj)/%.lds: $(src)/%.lds.S FORCE |
| 275 | $(call if_changed_dep,cpp_lds_S) | 277 | $(call if_changed_dep,cpp_lds_S) |
diff --git a/scripts/basic/docproc.c b/scripts/basic/docproc.c index 99ca7a698687..79ab973fb43a 100644 --- a/scripts/basic/docproc.c +++ b/scripts/basic/docproc.c | |||
| @@ -71,7 +71,7 @@ FILELINE * docsection; | |||
| 71 | 71 | ||
| 72 | static char *srctree, *kernsrctree; | 72 | static char *srctree, *kernsrctree; |
| 73 | 73 | ||
| 74 | void usage (void) | 74 | static void usage (void) |
| 75 | { | 75 | { |
| 76 | fprintf(stderr, "Usage: docproc {doc|depend} file\n"); | 76 | fprintf(stderr, "Usage: docproc {doc|depend} file\n"); |
| 77 | fprintf(stderr, "Input is read from file.tmpl. Output is sent to stdout\n"); | 77 | fprintf(stderr, "Input is read from file.tmpl. Output is sent to stdout\n"); |
| @@ -84,7 +84,7 @@ void usage (void) | |||
| 84 | /* | 84 | /* |
| 85 | * Execute kernel-doc with parameters given in svec | 85 | * Execute kernel-doc with parameters given in svec |
| 86 | */ | 86 | */ |
| 87 | void exec_kernel_doc(char **svec) | 87 | static void exec_kernel_doc(char **svec) |
| 88 | { | 88 | { |
| 89 | pid_t pid; | 89 | pid_t pid; |
| 90 | int ret; | 90 | int ret; |
| @@ -129,7 +129,7 @@ struct symfile | |||
| 129 | struct symfile symfilelist[MAXFILES]; | 129 | struct symfile symfilelist[MAXFILES]; |
| 130 | int symfilecnt = 0; | 130 | int symfilecnt = 0; |
| 131 | 131 | ||
| 132 | void add_new_symbol(struct symfile *sym, char * symname) | 132 | static void add_new_symbol(struct symfile *sym, char * symname) |
| 133 | { | 133 | { |
| 134 | sym->symbollist = | 134 | sym->symbollist = |
| 135 | realloc(sym->symbollist, (sym->symbolcnt + 1) * sizeof(char *)); | 135 | realloc(sym->symbollist, (sym->symbolcnt + 1) * sizeof(char *)); |
| @@ -137,14 +137,14 @@ void add_new_symbol(struct symfile *sym, char * symname) | |||
| 137 | } | 137 | } |
| 138 | 138 | ||
| 139 | /* Add a filename to the list */ | 139 | /* Add a filename to the list */ |
| 140 | struct symfile * add_new_file(char * filename) | 140 | static struct symfile * add_new_file(char * filename) |
| 141 | { | 141 | { |
| 142 | symfilelist[symfilecnt++].filename = strdup(filename); | 142 | symfilelist[symfilecnt++].filename = strdup(filename); |
| 143 | return &symfilelist[symfilecnt - 1]; | 143 | return &symfilelist[symfilecnt - 1]; |
| 144 | } | 144 | } |
| 145 | 145 | ||
| 146 | /* Check if file already are present in the list */ | 146 | /* Check if file already are present in the list */ |
| 147 | struct symfile * filename_exist(char * filename) | 147 | static struct symfile * filename_exist(char * filename) |
| 148 | { | 148 | { |
| 149 | int i; | 149 | int i; |
| 150 | for (i=0; i < symfilecnt; i++) | 150 | for (i=0; i < symfilecnt; i++) |
| @@ -157,20 +157,20 @@ struct symfile * filename_exist(char * filename) | |||
| 157 | * List all files referenced within the template file. | 157 | * List all files referenced within the template file. |
| 158 | * Files are separated by tabs. | 158 | * Files are separated by tabs. |
| 159 | */ | 159 | */ |
| 160 | void adddep(char * file) { printf("\t%s", file); } | 160 | static void adddep(char * file) { printf("\t%s", file); } |
| 161 | void adddep2(char * file, char * line) { line = line; adddep(file); } | 161 | static void adddep2(char * file, char * line) { line = line; adddep(file); } |
| 162 | void noaction(char * line) { line = line; } | 162 | static void noaction(char * line) { line = line; } |
| 163 | void noaction2(char * file, char * line) { file = file; line = line; } | 163 | static void noaction2(char * file, char * line) { file = file; line = line; } |
| 164 | 164 | ||
| 165 | /* Echo the line without further action */ | 165 | /* Echo the line without further action */ |
| 166 | void printline(char * line) { printf("%s", line); } | 166 | static void printline(char * line) { printf("%s", line); } |
| 167 | 167 | ||
| 168 | /* | 168 | /* |
| 169 | * Find all symbols in filename that are exported with EXPORT_SYMBOL & | ||
