Commit 81cae4d4 authored by Linus Torvalds's avatar Linus Torvalds

Merge bk://linux-sam.bkbits.net/kbuild

into ppc970.osdl.org:/home/torvalds/v2.6/linux
parents a6c13231 e09e5886
...@@ -23,7 +23,7 @@ with changes in the build system the most portable way to compile a ...@@ -23,7 +23,7 @@ with changes in the build system the most portable way to compile a
module outside the kernel is to use the kernel build system, module outside the kernel is to use the kernel build system,
kbuild. Use the following command-line: kbuild. Use the following command-line:
make -C path/to/kernel/src SUBDIRS=$PWD modules make -C path/to/kernel/src M=$PWD modules
This requires that a makefile exits made in accordance to This requires that a makefile exits made in accordance to
Documentation/kbuild/makefiles.txt. Read that file for more details on Documentation/kbuild/makefiles.txt. Read that file for more details on
...@@ -65,4 +65,4 @@ yourmodule-objs := file1.o file2.o file3.o ...@@ -65,4 +65,4 @@ yourmodule-objs := file1.o file2.o file3.o
# Invokes the kernel build system to come back to the current # Invokes the kernel build system to come back to the current
# directory and build yourmodule.ko. # directory and build yourmodule.ko.
default: default:
make -C ${KERNEL_SOURCE} SUBDIRS=`pwd` modules make -C ${KERNEL_SOURCE} M=`pwd` modules
...@@ -53,7 +53,7 @@ ifndef KBUILD_CHECKSRC ...@@ -53,7 +53,7 @@ ifndef KBUILD_CHECKSRC
KBUILD_CHECKSRC = 0 KBUILD_CHECKSRC = 0
endif endif
# Use make M=dir to specify direcotry of external module to build # Use make M=dir to specify directory of external module to build
# Old syntax make ... SUBDIRS=$PWD is still supported # Old syntax make ... SUBDIRS=$PWD is still supported
# Setting the environment variable KBUILD_EXTMOD take precedence # Setting the environment variable KBUILD_EXTMOD take precedence
ifdef SUBDIRS ifdef SUBDIRS
...@@ -130,16 +130,6 @@ else ...@@ -130,16 +130,6 @@ else
_all: modules _all: modules
endif endif
# Make sure we're not wasting cpu-cycles doing locale handling, yet do make
# sure error messages appear in the user-desired language
ifdef LC_ALL
LANG := $(LC_ALL)
LC_ALL :=
endif
LC_COLLATE := C
LC_CTYPE := C
export LANG LC_ALL LC_COLLATE LC_CTYPE
srctree := $(if $(KBUILD_SRC),$(KBUILD_SRC),$(CURDIR)) srctree := $(if $(KBUILD_SRC),$(KBUILD_SRC),$(CURDIR))
TOPDIR := $(srctree) TOPDIR := $(srctree)
# FIXME - TOPDIR is obsolete, use srctree/objtree # FIXME - TOPDIR is obsolete, use srctree/objtree
...@@ -621,25 +611,44 @@ vmlinux: $(vmlinux-objs) $(kallsyms.o) arch/$(ARCH)/kernel/vmlinux.lds.s FORCE ...@@ -621,25 +611,44 @@ vmlinux: $(vmlinux-objs) $(kallsyms.o) arch/$(ARCH)/kernel/vmlinux.lds.s FORCE
$(sort $(vmlinux-objs)) arch/$(ARCH)/kernel/vmlinux.lds.s: $(vmlinux-dirs) ; $(sort $(vmlinux-objs)) arch/$(ARCH)/kernel/vmlinux.lds.s: $(vmlinux-dirs) ;
# Handle descending into subdirectories listed in $(vmlinux-dirs) # Handle descending into subdirectories listed in $(vmlinux-dirs)
# Preset locale variables to speed up the build process. Limit locale
# tweaks to this spot to avoid wrong language settings when running
# make menuconfig etc.
# Error messages still appears in the original language
.PHONY: $(vmlinux-dirs) .PHONY: $(vmlinux-dirs)
$(vmlinux-dirs): prepare-all scripts $(vmlinux-dirs): prepare-all scripts
$(Q)$(MAKE) $(build)=$@ $(Q)if [ ! -z $$LC_ALL ]; then \
export LANG=$$LC_ALL; \
export LC_ALL= ; \
fi; \
export LC_COLLATE=C; export LC_CTYPE=C; \
$(MAKE) $(build)=$@
# Things we need to do before we recursively start building the kernel # Things we need to do before we recursively start building the kernel
# or the modules are listed in "prepare-all". # or the modules are listed in "prepare-all".
# A multi level approach is used. prepare1 is updated first, then prepare0. # A multi level approach is used. prepare1 is updated first, then prepare0.
# prepare-all is the collection point for the prepare targets. # prepare-all is the collection point for the prepare targets.
.PHONY: prepare-all prepare prepare0 prepare1 .PHONY: prepare-all prepare prepare0 prepare1 prepare2
# prepare 2 generate Makefile to be placed in output directory, if
# using a seperate output directory. This allows convinient use
# of make in output directory
prepare2:
$(Q)if [ ! $(srctree) -ef $(objtree) ]; then \
$(CONFIG_SHELL) $(srctree)/scripts/mkmakefile \
$(srctree) $(objtree) $(VERSION) $(PATCHLEVEL) \
> $(objtree)/Makefile; \
fi
# prepare1 is used to check if we are building in a separate output directory, # prepare1 is used to check if we are building in a separate output directory,
# and if so do: # and if so do:
# 1) Check that make has not been executed in the kernel src $(srctree) # 1) Check that make has not been executed in the kernel src $(srctree)
# 2) Create the include2 directory, used for the second asm symlink # 2) Create the include2 directory, used for the second asm symlink
prepare1: prepare1: prepare2
ifneq ($(KBUILD_SRC),) ifneq ($(KBUILD_SRC),)
@echo ' Using $(srctree) as source for kernel' @echo ' Using $(srctree) as source for kernel'
$(Q)if [ -h $(srctree)/include/asm -o -f $(srctree)/.config ]; then \ $(Q)if [ -h $(srctree)/include/asm -o -f $(srctree)/.config ]; then \
...@@ -760,9 +769,13 @@ _modinst_: ...@@ -760,9 +769,13 @@ _modinst_:
sleep 1; \ sleep 1; \
fi fi
@rm -rf $(MODLIB)/kernel @rm -rf $(MODLIB)/kernel
@rm -f $(MODLIB)/build @rm -f $(MODLIB)/source
@mkdir -p $(MODLIB)/kernel @mkdir -p $(MODLIB)/kernel
@ln -s $(TOPDIR) $(MODLIB)/build @ln -s $(srctree) $(MODLIB)/source
@if [ ! $(objtree) -ef $(MODLIB)/build ]; then \
rm -f $(MODLIB)/build ; \
ln -s $(objtree) $(MODLIB)/build ; \
fi
$(Q)$(MAKE) -rR -f $(srctree)/scripts/Makefile.modinst $(Q)$(MAKE) -rR -f $(srctree)/scripts/Makefile.modinst
# If System.map exists, run depmod. This deliberately does not have a # If System.map exists, run depmod. This deliberately does not have a
...@@ -1009,19 +1022,19 @@ endif # KBUILD_EXTMOD ...@@ -1009,19 +1022,19 @@ endif # KBUILD_EXTMOD
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
define all-sources define all-sources
( find . $(RCS_FIND_IGNORE) \ ( find $(srctree) $(RCS_FIND_IGNORE) \
\( -name include -o -name arch \) -prune -o \ \( -name include -o -name arch \) -prune -o \
-name '*.[chS]' -print; \ -name '*.[chS]' -print; \
find arch/$(ARCH) $(RCS_FIND_IGNORE) \ find $(srctree)/arch/$(ARCH) $(RCS_FIND_IGNORE) \
-name '*.[chS]' -print; \ -name '*.[chS]' -print; \
find security/selinux/include $(RCS_FIND_IGNORE) \ find $(srctree)/security/selinux/include $(RCS_FIND_IGNORE) \
-name '*.[chS]' -print; \ -name '*.[chS]' -print; \
find include $(RCS_FIND_IGNORE) \ find $(srctree)/include $(RCS_FIND_IGNORE) \
\( -name config -o -name 'asm-*' \) -prune \ \( -name config -o -name 'asm-*' \) -prune \
-o -name '*.[chS]' -print; \ -o -name '*.[chS]' -print; \
find include/asm-$(ARCH) $(RCS_FIND_IGNORE) \ find $(srctree)/include/asm-$(ARCH) $(RCS_FIND_IGNORE) \
-name '*.[chS]' -print; \ -name '*.[chS]' -print; \
find include/asm-generic $(RCS_FIND_IGNORE) \ find $(srctree)/include/asm-generic $(RCS_FIND_IGNORE) \
-name '*.[chS]' -print ) -name '*.[chS]' -print )
endef endef
......
menu "Generic Driver Options" menu "Generic Driver Options"
config STANDALONE
bool "Select only drivers that don't need compile-time external firmware" if EXPERIMENTAL
default y
help
Select this option if you don't have magic firmware for drivers that
need it.
If unsure, say Y.
config PREVENT_FIRMWARE_BUILD config PREVENT_FIRMWARE_BUILD
bool "Prevent firmware from being built" bool "Prevent firmware from being built"
default y default y
......
...@@ -41,15 +41,6 @@ config CLEAN_COMPILE ...@@ -41,15 +41,6 @@ config CLEAN_COMPILE
If unsure, say Y If unsure, say Y
config STANDALONE
bool "Select only drivers that don't need compile-time external firmware" if EXPERIMENTAL
default y
help
Select this option if you don't have magic firmware for drivers that
need it.
If unsure, say Y.
config BROKEN config BROKEN
bool bool
depends on !CLEAN_COMPILE depends on !CLEAN_COMPILE
......
...@@ -5,24 +5,11 @@ ...@@ -5,24 +5,11 @@
# docproc: Preprocess .tmpl file in order to generate .sgml docs # docproc: Preprocess .tmpl file in order to generate .sgml docs
# conmakehash: Create arrays for initializing the kernel console tables # conmakehash: Create arrays for initializing the kernel console tables
host-progs := conmakehash kallsyms modpost mk_elfconfig pnmtologo bin2c host-progs := conmakehash kallsyms pnmtologo bin2c
always := $(host-progs) empty.o always := $(host-progs)
modpost-objs := modpost.o file2alias.o sumversion.o
subdir-$(CONFIG_MODVERSIONS) += genksyms subdir-$(CONFIG_MODVERSIONS) += genksyms
subdir-y += mod
# Let clean descend into subdirs # Let clean descend into subdirs
subdir- += basic lxdialog kconfig package subdir- += basic lxdialog kconfig package
# dependencies on generated files need to be listed explicitly
$(obj)/modpost.o $(obj)/file2alias.o $(obj)/sumversion.o: $(obj)/elfconfig.h
quiet_cmd_elfconfig = MKELF $@
cmd_elfconfig = $(obj)/mk_elfconfig $(ARCH) < $< > $@
$(obj)/elfconfig.h: $(obj)/empty.o $(obj)/mk_elfconfig FORCE
$(call if_changed,elfconfig)
targets += elfconfig.h
...@@ -50,7 +50,7 @@ _modpost: $(modules) ...@@ -50,7 +50,7 @@ _modpost: $(modules)
# Step 2), invoke modpost # Step 2), invoke modpost
# Includes step 3,4 # Includes step 3,4
quiet_cmd_modpost = MODPOST quiet_cmd_modpost = MODPOST
cmd_modpost = scripts/modpost \ cmd_modpost = scripts/mod/modpost \
$(if $(KBUILD_EXTMOD),-i,-o) $(symverfile) \ $(if $(KBUILD_EXTMOD),-i,-o) $(symverfile) \
$(filter-out FORCE,$^) $(filter-out FORCE,$^)
......
...@@ -156,7 +156,7 @@ static const short yyrhs[] = { 53, ...@@ -156,7 +156,7 @@ static const short yyrhs[] = { 53,
71, 94, 92, 82, 0, 0, 62, 0, 63, 0, 71, 94, 92, 82, 0, 0, 62, 0, 63, 0,
62, 63, 0, 64, 0, 65, 0, 5, 0, 16, 62, 63, 0, 64, 0, 65, 0, 5, 0, 16,
0, 20, 0, 11, 0, 13, 0, 66, 0, 70, 0, 20, 0, 11, 0, 13, 0, 66, 0, 70,
0, 27, 46, 65, 47, 0, 21, 36, 0, 23, 0, 27, 46, 62, 47, 0, 21, 36, 0, 23,
36, 0, 10, 36, 0, 21, 36, 84, 0, 23, 36, 0, 10, 36, 0, 21, 36, 84, 0, 23,
36, 84, 0, 10, 36, 31, 0, 10, 31, 0, 36, 84, 0, 10, 36, 31, 0, 10, 31, 0,
21, 84, 0, 23, 84, 0, 7, 0, 18, 0, 21, 84, 0, 23, 84, 0, 7, 0, 18, 0,
...@@ -291,142 +291,150 @@ static const short yydefgoto[] = { 1, ...@@ -291,142 +291,150 @@ static const short yydefgoto[] = { 1,
}; };
static const short yypact[] = {-32768, static const short yypact[] = {-32768,
19,-32768, 175,-32768, 32,-32768,-32768,-32768,-32768,-32768, 15,-32768, 197,-32768, 23,-32768,-32768,-32768,-32768,-32768,
-18,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768, -18,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
-32768, -30,-32768, -26,-32768,-32768,-32768, -32, -10, -2, -32768, -28,-32768, -25,-32768,-32768,-32768, -26, -22, -12,
-32768,-32768,-32768,-32768, 2, 428,-32768,-32768,-32768,-32768, -32768,-32768,-32768,-32768, 49, 493,-32768,-32768,-32768,-32768,
-32768,-32768,-32768,-32768,-32768,-32768,-32768, 34, 12, 79, -32768,-32768,-32768,-32768,-32768,-32768,-32768, 27, -8, 101,
-32768, 428, 12,-32768, 455, 33,-32768,-32768, 15, 14, -32768, 493, -8,-32768, 493, 10,-32768,-32768, 11, 9,
35, 29,-32768, 2, -14, -21,-32768,-32768,-32768, 67, 18, 26,-32768, 49, -15, -13,-32768,-32768,-32768, 25,
31, 37, 127,-32768,-32768, 2,-32768, 54, 60, 66, 24, 48, 149,-32768,-32768, 49,-32768, 414, 39, 40,
69,-32768, 14,-32768,-32768, 2,-32768,-32768,-32768, 84, 47,-32768, 9,-32768,-32768, 49,-32768,-32768,-32768, 66,
-32768, 219,-32768,-32768, 70,-32768, 20, 91, 72, 84, -32768, 241,-32768,-32768, 50,-32768, 5, 65, 42, 66,
-20, 74, 81,-32768,-32768,-32768, 86,-32768, 102,-32768, 17, 56, 55,-32768,-32768,-32768, 60,-32768, 75,-32768,
106,-32768,-32768,-32768,-32768,-32768, 109, 108, 348, 112, 80,-32768,-32768,-32768,-32768,-32768, 81, 82, 370, 85,
126, 117,-32768,-32768, 118,-32768, 122,-32768,-32768,-32768, 98, 89,-32768,-32768, 88,-32768, 91,-32768,-32768,-32768,
-32768, 262,-32768, 31,-32768, 131,-32768,-32768,-32768,-32768, -32768, 284,-32768, 24,-32768, 103,-32768,-32768,-32768,-32768,
-32768, 7, 120,-32768, -9,-32768,-32768, 392,-32768,-32768, -32768, 8, 43,-32768, 30,-32768,-32768, 457,-32768,-32768,
125, 130,-32768,-32768, 132,-32768, 159,-32768,-32768, 305, 92, 93,-32768,-32768, 95,-32768, 96,-32768,-32768, 327,
-32768,-32768,-32768,-32768,-32768,-32768, 160, 161,-32768,-32768, -32768,-32768,-32768,-32768,-32768,-32768, 99, 104,-32768,-32768,
174,-32768 148,-32768
}; };
static const short yypgoto[] = {-32768, static const short yypgoto[] = {-32768,
208,-32768,-32768,-32768, 158,-32768,-32768, 128, 0, -90, 152,-32768,-32768,-32768, 119,-32768,-32768, 94, 0, -55,
-36,-32768, 157,-32768, -70,-32768,-32768, -51, -31,-32768, -35,-32768,-32768,-32768, -69,-32768,-32768, -56, -30,-32768,
-40,-32768, -125,-32768,-32768, 65, -97,-32768,-32768,-32768, -76,-32768, -122,-32768,-32768, 29, -62,-32768,-32768,-32768,
-32768, -19,-32768,-32768, 143,-32768,-32768, 83, 124, 141, -32768, -17,-32768,-32768, 105,-32768,-32768, 52, 86, 83,
-32768,-32768,-32768 -32768,-32768,-32768
}; };
#define YYLAST 495 #define YYLAST 533
static const short yytable[] = { 67, static const short yytable[] = { 78,
99, 119, 35, 65, 54, 49, 152, 155, 84, 53, 67, 99, 35, 84, 65, 125, 54, 49, 155, 152,
91, 131, 47, 55, 88, 80, 89, 48, 171, 50, 53, 80, 47, 88, 171, 89, 9, 48, 91, 55,
125, 9, 159, 50, 92, 132, 99, 81, 99, 69, 127, 50, 129, 56, 50, 18, 114, 99, 81, 99,
18, 114, 87, 77, 168, 56, 160, 58, -89, 27, 57, 69, 92, 87, 27, 77, 119, 168, 31, -89,
57, 119, 140, 31, 157, 158, 156, 59, 143, 60, 126, 50, 67, 140, 96, 79, 58, 156, 131, 143,
58, 76, 142, -89, 60, 126, 127, 119, 129, 96, 97, 76, 60, 142, -89, 60, 59, 68, 60, 95,
59, 50, 60, 99, 68, 97, 95, 60, 79, 119, 85, 159, 132, 96, 99, 45, 46, 93, 94, 97,
96, 143, 143, 86, 45, 46, 97, 85, 60, 70, 86, 60, 143, 143, 98, 160, 119, 126, 140, 157,
106, 98, 67, 6, 7, 8, 9, 10, 11, 12, 158, 96, 156, 67, 58, 111, 112, 97, 142, 60,
13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 60, 106, 119, 113, 59, 116, 60, 128, 133, 134,
110, 24, 25, 26, 27, 28, 111, 126, 31, 93, 98, 70, 93, 88, 119, 6, 7, 8, 9, 10,
94, 96, 112, 116, -19, 113, 133, 97, 32, 60, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
98, -19, -103, 128, -19, 134, -19, 107, 93, -19, 21, 22, 135, 24, 25, 26, 27, 28, 139, 136,
88, 6, 7, 8, 9, 10, 11, 12, 13, 14, 31, 146, 147, 148, 149, 154, -19, 150, 163, 164,
15, 16, 17, 18, 19, 20, 21, 22, 135, 24, 32, 165, 166, -19, -103, 169, -19, 172, -19, 107,
25, 26, 27, 28, 139, 140, 31, 136, 146, 156, 170, -19, 4, 6, 7, 8, 9, 10, 11, 12,
147, 148, -19, 154, 149, 142, 32, 60, 150, -19,
-104, 163, -19, 172, -19, 5, 164, -19, 165, 6,
7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
17, 18, 19, 20, 21, 22, 23, 24, 25, 26,
27, 28, 29, 30, 31, 166, 169, 170, 4, 75,
-19, 78, 162, 115, 32, 108, 153, -19, 124, 118,
-19, 0, -19, 6, 7, 8, 9, 10, 11, 12,
13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22,
130, 24, 25, 26, 27, 28, 0, 0, 31, 0, 75, 24, 25, 26, 27, 28, 162, 108, 31, 115,
0, 0, 0, -82, 0, 0, 0, 0, 32, 0, 124, 0, 130, 0, -19, 153, 0, 0, 32, 0,
0, 0, 151, 0, 0, -82, 6, 7, 8, 9, 0, -19, -104, 0, -19, 0, -19, 5, 0, -19,
10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 0, 6, 7, 8, 9, 10, 11, 12, 13, 14,
20, 21, 22, 0, 24, 25, 26, 27, 28, 0, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
0, 31, 0, 0, 0, 0, -82, 0, 0, 0, 25, 26, 27, 28, 29, 30, 31, 0, 0, 0,
0, 32, 0, 0, 0, 167, 0, 0, -82, 6, 0, 0, -19, 0, 0, 0, 32, 0, 0, -19,
7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 0, 118, -19, 0, -19, 6, 7, 8, 9, 10,
17, 18, 19, 20, 21, 22, 0, 24, 25, 26, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
27, 28, 0, 0, 31, 0, 0, 0, 0, -82, 21, 22, 0, 24, 25, 26, 27, 28, 0, 0,
0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 31, 0, 0, 0, 0, -82, 0, 0, 0, 0,
0, -82, 6, 7, 8, 9, 10, 11, 12, 13, 32, 0, 0, 0, 151, 0, 0, -82, 6, 7,
14, 15, 16, 17, 18, 19, 20, 21, 22, 0, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
24, 25, 26, 27, 28, 0, 0, 31, 0, 0, 18, 19, 20, 21, 22, 0, 24, 25, 26, 27,
0, 0, 0, 140, 0, 0, 0, 141, 0, 0, 28, 0, 0, 31, 0, 0, 0, 0, -82, 0,
0, 0, 0, 142, 0, 60, 6, 7, 8, 9, 0, 0, 0, 32, 0, 0, 0, 167, 0, 0,
10, 11, 12, 13, 14, 15, 16, 17, 18, 19, -82, 6, 7, 8, 9, 10, 11, 12, 13, 14,
20, 21, 22, 0, 24, 25, 26, 27, 28, 0, 15, 16, 17, 18, 19, 20, 21, 22, 0, 24,
0, 31, 0, 0, 0, 0, 161, 0, 0, 0, 25, 26, 27, 28, 0, 0, 31, 0, 0, 0,
0, 32, 6, 7, 8, 9, 10, 11, 12, 13, 0, -82, 0, 0, 0, 0, 32, 0, 0, 0,
14, 15, 16, 17, 18, 19, 20, 21, 22, 0, 0, 0, 0, -82, 6, 7, 8, 9, 10, 11,
24, 25, 26, 27, 28, 0, 0, 31, 0, 0, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
7, 8, 9, 10, 11, 0, 13, 32, 15, 16, 22, 0, 24, 25, 26, 27, 28, 0, 0, 31,
0, 18, 19, 20, 0, 22, 0, 24, 25, 26, 0, 0, 0, 0, 0, 140, 0, 0, 0, 141,
27, 28, 0, 0, 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 142, 0, 60, 6, 7,
0, 0, 0, 0, 32 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, 22, 0, 24, 25, 26, 27,
28, 0, 0, 31, 0, 0, 0, 0, 0, 0,
0, 0, 0, 32, 0, 0, 0, 0, 0, 0,
110, 6, 7, 8, 9, 10, 11, 12, 13, 14,
15, 16, 17, 18, 19, 20, 21, 22, 0, 24,
25, 26, 27, 28, 0, 0, 31, 0, 0, 0,
0, 161, 0, 0, 0, 0, 32, 6, 7, 8,
9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
19, 20, 21, 22, 0, 24, 25, 26, 27, 28,
0, 0, 31, 0, 0, 0, 0, 0, 0, 0,
0, 0, 32
}; };
static const short yycheck[] = { 36, static const short yycheck[] = { 55,
71, 92, 3, 35, 24, 36, 132, 1, 60, 36, 36, 71, 3, 60, 35, 1, 24, 36, 1, 132,
32, 32, 31, 46, 29, 1, 31, 36, 0, 50, 36, 1, 31, 29, 0, 31, 8, 36, 32, 46,
1, 8, 32, 50, 46, 46, 97, 59, 99, 49, 97, 50, 99, 46, 50, 17, 83, 97, 59, 99,
17, 83, 64, 53, 160, 46, 46, 36, 32, 26, 43, 49, 46, 64, 26, 53, 92, 160, 30, 32,
43, 132, 36, 30, 142, 143, 40, 46, 119, 48, 36, 50, 78, 36, 40, 36, 36, 40, 32, 119,
36, 52, 46, 47, 48, 36, 97, 148, 99, 40, 46, 52, 48, 46, 47, 48, 46, 31, 48, 36,
46, 50, 48, 134, 31, 46, 36, 48, 36, 160, 43, 32, 46, 40, 134, 43, 44, 43, 44, 46,
40, 142, 143, 45, 43, 44, 46, 43, 48, 1, 45, 48, 142, 143, 51, 46, 132, 36, 36, 142,
44, 51, 119, 5, 6, 7, 8, 9, 10, 11, 143, 40, 40, 119, 36, 47, 47, 46, 46, 48,
12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 48, 44, 148, 47, 46, 30, 48, 33, 43, 45,
47, 23, 24, 25, 26, 27, 47, 36, 30, 43, 51, 1, 43, 29, 160, 5, 6, 7, 8, 9,
44, 40, 47, 30, 36, 47, 43, 46, 40, 48, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
51, 43, 44, 33, 46, 45, 48, 1, 43, 51, 20, 21, 43, 23, 24, 25, 26, 27, 47, 49,
29, 5, 6, 7, 8, 9, 10, 11, 12, 13, 30, 47, 35, 45, 47, 33, 36, 47, 47, 47,
14, 15, 16, 17, 18, 19, 20, 21, 43, 23, 40, 47, 47, 43, 44, 47, 46, 0, 48, 1,
24, 25, 26, 27, 47, 36, 30, 49, 47, 40, 47, 51, 1, 5, 6, 7, 8, 9, 10, 11,
35, 45, 36, 33, 47, 46, 40, 48, 47, 43,
44, 47, 46, 0, 48, 1, 47, 51, 47, 5,
6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
26, 27, 28, 29, 30, 47, 47, 47, 1, 52,
36, 55, 148, 86, 40, 73, 134, 43, 95, 1,
46, -1, 48, 5, 6, 7, 8, 9, 10, 11,
12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
100, 23, 24, 25, 26, 27, -1, -1, 30, -1, 52, 23, 24, 25, 26, 27, 148, 73, 30, 86,
-1, -1, -1, 35, -1, -1, -1, -1, 40, -1, 95, -1, 100, -1, 36, 134, -1, -1, 40, -1,
-1, -1, 1, -1, -1, 47, 5, 6, 7, 8, -1, 43, 44, -1, 46, -1, 48, 1, -1, 51,
9, 10, 11, 12, 13, 14, 15, 16, 17, 18, -1, 5, 6, 7, 8, 9, 10, 11, 12, 13,
19, 20, 21, -1, 23, 24, 25, 26, 27, -1, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
-1, 30, -1, -1, -1, -1, 35, -1, -1, -1, 24, 25, 26, 27, 28, 29, 30, -1, -1, -1,
-1, 40, -1, -1, -1, 1, -1, -1, 47, 5, -1, -1, 36, -1, -1, -1, 40, -1, -1, 43,
6, 7, 8, 9, 10, 11, 12, 13, 14, 15, -1, 1, 46, -1, 48, 5, 6, 7, 8, 9,
16, 17, 18, 19, 20, 21, -1, 23, 24, 25, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
26, 27, -1, -1, 30, -1, -1, -1, -1, 35, 20, 21, -1, 23, 24, 25, 26, 27, -1, -1,
-1, -1, -1, -1, 40, -1, -1, -1, -1, -1, 30, -1, -1, -1, -1, 35, -1, -1, -1, -1,
-1, 47, 5, 6, 7, 8, 9, 10, 11, 12, 40, -1, -1, -1, 1, -1, -1, 47, 5, 6,
13, 14, 15, 16, 17, 18, 19, 20, 21, -1, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
23, 24, 25, 26, 27, -1, -1, 30, -1, -1, 17, 18, 19, 20, 21, -1, 23, 24, 25, 26,
-1, -1, -1, 36, -1, -1, -1, 40, -1, -1, 27, -1, -1, 30, -1, -1, -1, -1, 35, -1,
-1, -1, -1, 46, -1, 48, 5, 6, 7, 8, -1, -1, -1, 40, -1, -1, -1, 1, -1, -1,
9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 47, 5, 6, 7, 8, 9, 10, 11, 12, 13,
19, 20, 21, -1, 23, 24, 25, 26, 27, -1, 14, 15, 16, 17, 18, 19, 20, 21, -1, 23,
-1, 30, -1, -1, -1, -1, 35, -1, -1, -1, 24, 25, 26, 27, -1, -1, 30, -1, -1, -1,
-1, 40, 5, 6, 7, 8, 9, 10, 11, 12, -1, 35, -1, -1, -1, -1, 40, -1, -1, -1,
13, 14, 15, 16, 17, 18, 19, 20, 21, -1, -1, -1, -1, 47, 5, 6, 7, 8, 9, 10,
23, 24, 25, 26, 27, -1, -1, 30, -1, -1, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
6, 7, 8, 9, 10, -1, 12, 40, 14, 15, 21, -1, 23, 24, 25, 26, 27, -1, -1, 30,
-1, 17, 18, 19, -1, 21, -1, 23, 24, 25, -1, -1, -1, -1, -1, 36, -1, -1, -1, 40,
26, 27, -1, -1, 30, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 46, -1, 48, 5, 6,
-1, -1, -1, -1, 40 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
17, 18, 19, 20, 21, -1, 23, 24, 25, 26,
27, -1, -1, 30, -1, -1, -1, -1, -1, -1,
-1, -1, -1, 40, -1, -1, -1, -1, -1, -1,
47, 5, 6, 7, 8, 9, 10, 11, 12, 13,
14, 15, 16, 17, 18, 19, 20, 21, -1, 23,
24, 25, 26, 27, -1, -1, 30, -1, -1, -1,
-1, 35, -1, -1, -1, -1, 40, 5, 6, 7,
8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
18, 19, 20, 21, -1, 23, 24, 25, 26, 27,
-1, -1, 30, -1, -1, -1, -1, -1, -1, -1,
-1, -1, 40
}; };
/* -*-C-*- Note some compilers choke on comments on `#line' lines. */ /* -*-C-*- Note some compilers choke on comments on `#line' lines. */
#line 3 "/usr/lib/bison.simple" #line 3 "/usr/lib/bison.simple"
......
#!/bin/sh
# Generates a small Makefile used in the root of the output
# directory, to allow make to be started from there.
# The Makefile also allow for more convinient build of external modules
# Usage
# $1 - Kernel src directory
# $2 - Output directory
# $3 - version
# $4 - patchlevel
cat << EOF
# Automatically generated by $0: don't edit
VERSION = $3
PATCHLEVEL = $4
KERNELSRC := $1
KERNELOUTPUT := $2
MAKEFLAGS += --no-print-directory
all:
\$(MAKE) -C \$(KERNELSRC) O=\$(KERNELOUTPUT)
%::
\$(MAKE) -C \$(KERNELSRC) O=\$(KERNELOUTPUT) \$@
EOF
host-progs := modpost mk_elfconfig
always := $(host-progs) empty.o
modpost-objs := modpost.o file2alias.o sumversion.o
# dependencies on generated files need to be listed explicitly
$(obj)/modpost.o $(obj)/file2alias.o $(obj)/sumversion.o: $(obj)/elfconfig.h
quiet_cmd_elfconfig = MKELF $@
cmd_elfconfig = $(obj)/mk_elfconfig $(ARCH) < $< > $@
$(obj)/elfconfig.h: $(obj)/empty.o $(obj)/mk_elfconfig FORCE
$(call if_changed,elfconfig)
targets += elfconfig.h
...@@ -27,7 +27,7 @@ typedef unsigned char __u8; ...@@ -27,7 +27,7 @@ typedef unsigned char __u8;
/* Big exception to the "don't include kernel headers into userspace, which /* Big exception to the "don't include kernel headers into userspace, which
* even potentially has different endianness and word sizes, since * even potentially has different endianness and word sizes, since
* we handle those differences explicitly below */ * we handle those differences explicitly below */
#include "../include/linux/mod_devicetable.h" #include "../../include/linux/mod_devicetable.h"
#define ADD(str, sep, cond, field) \ #define ADD(str, sep, cond, field) \
do { \ do { \
......
...@@ -31,9 +31,10 @@ KERNELPATH := kernel-$(subst -,,$(KERNELRELEASE)) ...@@ -31,9 +31,10 @@ KERNELPATH := kernel-$(subst -,,$(KERNELRELEASE))
MKSPEC := $(srctree)/scripts/package/mkspec MKSPEC := $(srctree)/scripts/package/mkspec
PREV := set -e; cd ..; PREV := set -e; cd ..;
# rpm-pkg
.PHONY: rpm-pkg rpm .PHONY: rpm-pkg rpm
$(objtree)/kernel.spec: $(MKSPEC) $(objtree)/kernel.spec: $(MKSPEC) $(srctree)/Makefile
$(CONFIG_SHELL) $(MKSPEC) > $@ $(CONFIG_SHELL) $(MKSPEC) > $@
rpm-pkg rpm: $(objtree)/kernel.spec rpm-pkg rpm: $(objtree)/kernel.spec
...@@ -52,6 +53,22 @@ rpm-pkg rpm: $(objtree)/kernel.spec ...@@ -52,6 +53,22 @@ rpm-pkg rpm: $(objtree)/kernel.spec
clean-rule += rm -f $(objtree)/kernel.spec clean-rule += rm -f $(objtree)/kernel.spec
# binrpm-pkg
.PHONY: binrpm-pkg
$(objtree)/binkernel.spec: $(MKSPEC) $(srctree)/Makefile
$(CONFIG_SHELL) $(MKSPEC) prebuilt > $@
binrpm-pkg: $(objtree)/binkernel.spec
$(MAKE)
set -e; \
$(CONFIG_SHELL) $(srctree)/scripts/mkversion > $(objtree)/.tmp_version
set -e; \
mv -f $(objtree)/.tmp_version $(objtree)/.version
$(RPM) --define "_builddir $(srctree)" --target $(UTS_MACHINE) -bb $<
clean-rule += rm -f $(objtree)/binkernel.spec
# Deb target # Deb target
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
# #
...@@ -67,5 +84,6 @@ clean-rule += && rm -rf $(objtree)/debian/ ...@@ -67,5 +84,6 @@ clean-rule += && rm -rf $(objtree)/debian/
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
help: help:
@echo ' rpm-pkg - Build the kernel as an RPM package' @echo ' rpm-pkg - Build the kernel as an RPM package'
@echo ' binrpm-pkg - Build an rpm package containing the compiled kernel & modules'
@echo ' deb-pkg - Build the kernel as an deb package' @echo ' deb-pkg - Build the kernel as an deb package'
...@@ -9,6 +9,13 @@ ...@@ -9,6 +9,13 @@
# Patched for non-x86 by Opencon (L) 2002 <opencon@rio.skydome.net> # Patched for non-x86 by Opencon (L) 2002 <opencon@rio.skydome.net>
# #
# how we were called determines which rpms we build and how we build them
if [ "$1" = "prebuilt" ]; then
PREBUILT=true
else
PREBUILT=false
fi
# starting to output the spec # starting to output the spec
if [ "`grep CONFIG_DRM=y .config | cut -f2 -d\=`" = "y" ]; then if [ "`grep CONFIG_DRM=y .config | cut -f2 -d\=`" = "y" ]; then
PROVIDES=kernel-drm PROVIDES=kernel-drm
...@@ -26,8 +33,12 @@ echo "License: GPL" ...@@ -26,8 +33,12 @@ echo "License: GPL"
echo "Group: System Environment/Kernel" echo "Group: System Environment/Kernel"
echo "Vendor: The Linux Community" echo "Vendor: The Linux Community"
echo "URL: http://www.kernel.org" echo "URL: http://www.kernel.org"
if ! $PREBUILT; then
echo -n "Source: kernel-$VERSION.$PATCHLEVEL.$SUBLEVEL" echo -n "Source: kernel-$VERSION.$PATCHLEVEL.$SUBLEVEL"
echo "$EXTRAVERSION.tar.gz" | sed -e "s/-//g" echo "$EXTRAVERSION.tar.gz" | sed -e "s/-//g"
fi
echo "BuildRoot: /var/tmp/%{name}-%{PACKAGE_VERSION}-root" echo "BuildRoot: /var/tmp/%{name}-%{PACKAGE_VERSION}-root"
echo "Provides: $PROVIDES" echo "Provides: $PROVIDES"
echo "%define __spec_install_post /usr/lib/rpm/brp-compress || :" echo "%define __spec_install_post /usr/lib/rpm/brp-compress || :"
...@@ -36,12 +47,20 @@ echo "" ...@@ -36,12 +47,20 @@ echo ""
echo "%description" echo "%description"
echo "The Linux Kernel, the operating system core itself" echo "The Linux Kernel, the operating system core itself"
echo "" echo ""
if ! $PREBUILT; then
echo "%prep" echo "%prep"
echo "%setup -q" echo "%setup -q"
echo "" echo ""
fi
echo "%build" echo "%build"
if ! $PREBUILT; then
echo "make clean && make" echo "make clean && make"
echo "" echo ""
fi
echo "%install" echo "%install"
echo 'mkdir -p $RPM_BUILD_ROOT/boot $RPM_BUILD_ROOT/lib $RPM_BUILD_ROOT/lib/modules' echo 'mkdir -p $RPM_BUILD_ROOT/boot $RPM_BUILD_ROOT/lib $RPM_BUILD_ROOT/lib/modules'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment