"Good enough to build broken i386 packages" commit.

Everything is more or less in place, need to audit
the build procedure for individual arches and put
in the remaining bits and pieces.

svn path=/branches/kernel-image-2.6.11/; revision=3113
This commit is contained in:
Jurij Smakov 2005-05-15 05:30:44 +00:00
parent 93519f0dce
commit 7cf165867d
3 changed files with 1455 additions and 24 deletions

11
README
View File

@ -4,11 +4,12 @@ All the config files live in the arch subdirectory. The config
file for a particular subarch is constructed by concatenating
the following files (any of them can be missing):
arch/config.common - architecture-independent config file
arch/<arch>/config.common - subarch-independent config file
for a particular architecture
arch<arch>/config.<subarch> - subarch-specific config file.
arch/config.common - architecture-independent config file
arch/<arch>/config.common - subarch-independent config file
for a particular architecture
arch/<arch>/config.<subarch> - subarch-specific config file.
arch/<arch>/config.default - the arch-specific config file used
to build the kernel-headers.
It is possible to avoid the inclusion of the arch-independent
config file (handy for the transitional period) by setting the
include_common_config variable to 'no' in arch/<arch>/Makefile.inc.

1419
arch/i386/config.default Normal file

File diff suppressed because it is too large Load Diff

49
debian/rules vendored
View File

@ -4,11 +4,12 @@
#
version := 2.6.11
abiname := 1
ktver := 2
ktver := 4
kbuildver := 2.6-3
#
# Generally nothing needs to be modified below this line
#
SHELL := sh -e
debver := $(version)-$(abiname)
uver := $(subst .,_,$(version))
debnum := -$(abiname)
@ -16,12 +17,13 @@ bpkg := kernel-build-$(debver)
kdir := kernel-source-$(version)
kbpkg := kernel-kbuild-$(kbuildver)
kpatch := /usr/src/kernel-patches/all/$(version)/apply/debian
export DEBIAN_SRCTOP := $(CURDIR)/$(kdir)
export DEBIAN_UPSTREAM_VERSION := $(version)
DEBIAN_SRCTOP := $(CURDIR)/$(kdir)
DEBIAN_UPSTREAM_VERSION := $(version)
ifeq (,$(DEB_HOST_ARCH))
DEB_HOST_ARCH := $(shell dpkg-architecture -qDEB_HOST_ARCH)
DEB_BUILD_ARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH)
endif
export version debnum DEBIAN_SRCTOP DEBIAN_UPSTREAM_VERSION
#
# The CROSS variable is only used on sparc to call
# the correct 'strip' binary on the kernel-image.
@ -33,9 +35,11 @@ endif
karch := $(DEB_HOST_ARCH)
controls := $(wildcard arch/*/control.in)
default := arch/$(karch)/config.default
configs := $(notdir $(wildcard arch/$(karch)/config.*))
configs := $(filter-out config.common config.default, $(configs))
ifndef flavours
flavours := $(filter-out common, $(patsubst config.%,%,$(configs)))
flavours := $(patsubst config.%,%,$(configs))
endif
-include arch/$(karch)/Makefile.inc
@ -72,8 +76,6 @@ ifndef headers_dirs
endif
#
# Problems:
# * What to do with default config?
# TODO:
# * Check that make oldconfig does not actually
# change the config file. If it does, something
@ -112,10 +114,17 @@ build-stamp: unpack-stamp
touch build-stamp
clean:
dh_testdir
rm -f *-stamp header-install config.*
rm -rf $(kdir) build-* install-* bin/touch.orig
dh_clean
#
# Problems:
# * Due to some reason i386 build runs some debhelper
# commands on the kernel-headers package, as if
# building it manually. I thought make-kpkg was supposed
# to take care of it.
#
binary-indep: build
#
# Problems:
@ -137,8 +146,8 @@ binary-arch: build
cd install-$$i; \
$(kpkg_image_cmd); \
cd ..; \
cat install-$$i/debian/files >> debian/files \
rm -rf install-$$i
cat install-$$i/debian/files >> debian/files; \
rm -rf install-$$i ; \
done
mv *.deb ..
@ -193,13 +202,15 @@ debian/control:
sed 's/^Package:/\n&/g' > debian/control
$(kdir):
@echo -n "Unpacking kernel source $(version) ..."
@tar jxf /usr/src/kernel-source-$(version).tar.bz2
@cd $(kdir) && $(kpatch) $(version)-$(ktver)
@mkdir -p $(kdir)/debian
@cp debian/changelog $(kdir)/debian
@cp debian/control $(kdir)/debian
@cp debian/copyright $(kdir)/debian
@touch $(kdir)/debian/official
@install post-install $(kdir)/debian
@echo " done."
dh_testdir
tar jxf /usr/src/kernel-source-$(version).tar.bz2
cd $(kdir) && $(kpatch) $(version)-$(ktver)
mkdir -p $(kdir)/debian
cp debian/changelog $(kdir)/debian
cp debian/control $(kdir)/debian
cp debian/copyright $(kdir)/debian
cp $(default) $(kdir)/.config
touch $(kdir)/debian/official
install post-install $(kdir)/debian
.PHONY: clean build unpack binary-indep binary-arch binary