Fixed the generation of config files for all
cases. Minor corrections to the documentation. svn path=/branches/kernel-image-2.6.11/; revision=3198
This commit is contained in:
parent
32599383b3
commit
af95f5e28d
7
README
7
README
|
@ -28,8 +28,6 @@ For architecture without subarches:
|
||||||
|
|
||||||
For architecture with subarches:
|
For architecture with subarches:
|
||||||
|
|
||||||
y concatenating:
|
|
||||||
|
|
||||||
arch/config.common
|
arch/config.common
|
||||||
arch/<arch>/config.common
|
arch/<arch>/config.common
|
||||||
arch/<arch>/<subarch>/config.common
|
arch/<arch>/<subarch>/config.common
|
||||||
|
@ -89,8 +87,9 @@ this file include the setting of the following variables:
|
||||||
|
|
||||||
include_common_config
|
include_common_config
|
||||||
|
|
||||||
Setting it to 'no' will prevent the common kernel config from being
|
Setting it to 'no' (without quotes) will prevent the common kernel
|
||||||
included for this particular architecture. Typical usage:
|
config from being included for this particular architecture.
|
||||||
|
Typical usage:
|
||||||
|
|
||||||
include_common_config := no
|
include_common_config := no
|
||||||
|
|
||||||
|
|
2
TODO
2
TODO
|
@ -11,5 +11,3 @@ Major TODO items remaining:
|
||||||
|
|
||||||
* Various remaining kludges (stripping and sparc32/sparc64 stuff on sparc,
|
* Various remaining kludges (stripping and sparc32/sparc64 stuff on sparc,
|
||||||
for example).
|
for example).
|
||||||
|
|
||||||
* Config file generation for arches with subarches is probably broken.
|
|
||||||
|
|
|
@ -20,17 +20,20 @@ ifeq (,$(DEB_HOST_ARCH))
|
||||||
endif
|
endif
|
||||||
export version debnum DEBIAN_UPSTREAM_VERSION
|
export version debnum DEBIAN_UPSTREAM_VERSION
|
||||||
|
|
||||||
karch := $(DEB_HOST_ARCH)
|
karch := $(DEB_HOST_ARCH)
|
||||||
|
#
|
||||||
|
# Build the list of common config files to be included
|
||||||
|
#
|
||||||
ifeq ($(subarch),none)
|
ifeq ($(subarch),none)
|
||||||
basedir := arch/$(karch)
|
basedir := arch/$(karch)
|
||||||
else
|
else
|
||||||
basedir := arch/$(karch)/$(subarch)
|
basedir := arch/$(karch)/$(subarch)
|
||||||
endif
|
endif
|
||||||
default := $(basedir)/config.default
|
default := $(basedir)/config.default
|
||||||
configs := $(notdir $(wildcard $(basedir)/config.*))
|
configs := $(notdir $(wildcard $(basedir)/config.*))
|
||||||
configs := $(filter-out config.common config.default, $(configs))
|
configs := $(filter-out config.common config.default, $(configs))
|
||||||
tkdir := kernel-source-$(version)
|
tkdir := kernel-source-$(version)
|
||||||
kdir := kernel-source-$(version)-$(subarch)
|
kdir := kernel-source-$(version)-$(subarch)
|
||||||
ifndef flavours
|
ifndef flavours
|
||||||
flavours := $(patsubst config.%,%,$(configs))
|
flavours := $(patsubst config.%,%,$(configs))
|
||||||
endif
|
endif
|
||||||
|
@ -68,7 +71,10 @@ kpkg_headers_cmd += kernel-headers
|
||||||
ifndef headers_dirs
|
ifndef headers_dirs
|
||||||
headers_dirs = $(karch)
|
headers_dirs = $(karch)
|
||||||
endif
|
endif
|
||||||
|
ifneq (no,$(include_common_config))
|
||||||
|
ccommon := arch/config.common
|
||||||
|
endif
|
||||||
|
ccommon += arch/$(karch)/config.common arch/$(karch)/$(subarch)/config.common
|
||||||
#
|
#
|
||||||
# TODO:
|
# TODO:
|
||||||
# * Check that make oldconfig does not actually
|
# * Check that make oldconfig does not actually
|
||||||
|
@ -136,7 +142,10 @@ header-install-$(subarch): header-install.in
|
||||||
-e 's,@headers_extra@,$(headers_extra),g' \
|
-e 's,@headers_extra@,$(headers_extra),g' \
|
||||||
header-install.in > header-install-$(subarch)
|
header-install.in > header-install-$(subarch)
|
||||||
chmod u+x header-install-$(subarch)
|
chmod u+x header-install-$(subarch)
|
||||||
|
#
|
||||||
|
# The way to make the correct package names is to make a
|
||||||
|
# subarch-specific post-install script...
|
||||||
|
#
|
||||||
post-install: post-install.in
|
post-install: post-install.in
|
||||||
sed -e 's,@initrd_modules@,$(initrd_modules),' \
|
sed -e 's,@initrd_modules@,$(initrd_modules),' \
|
||||||
post-install.in > post-install
|
post-install.in > post-install
|
||||||
|
@ -147,25 +156,18 @@ post-install: post-install.in
|
||||||
# and subarch specific one (arch/$(karch)/config.subarch).
|
# and subarch specific one (arch/$(karch)/config.subarch).
|
||||||
# It is possible to avoid the inclusion of the arch-indep
|
# It is possible to avoid the inclusion of the arch-indep
|
||||||
# config file by setting include_common_config = no in the
|
# config file by setting include_common_config = no in the
|
||||||
# arch/$(karch)/Makefile.inc. Absense of any of the above
|
# arch/$(karch)/Makefile.inc.
|
||||||
# files is ignored.
|
|
||||||
#
|
#
|
||||||
config.%:
|
config.%:
|
||||||
@echo -n "Generating configuration file $@ ..."
|
@echo "Generating configuration file $@:"
|
||||||
arch='$(basedir)/config.common'; \
|
rm -f $@
|
||||||
subarch='$(basedir)/$@'; \
|
for i in $(ccommon); do \
|
||||||
include=''; \
|
if [ -f $${i} ]; then \
|
||||||
if [ '$(include_common_config)' != 'no' ]; then \
|
cat $${i} >> $@; \
|
||||||
include='arch/config.common'; \
|
fi; \
|
||||||
fi; \
|
done
|
||||||
if [ -f "$${arch}" ]; then \
|
# Flavour config file must be present
|
||||||
include="$${include} $${arch}"; \
|
cat $(basedir)/$@ >> $@
|
||||||
fi; \
|
|
||||||
if [ -f "$${subarch}" ]; then \
|
|
||||||
include="$${include} $${subarch}"; \
|
|
||||||
fi; \
|
|
||||||
cat $${include} > $@
|
|
||||||
@echo " done."
|
|
||||||
#
|
#
|
||||||
# TODO: subarch specific patches
|
# TODO: subarch specific patches
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in New Issue