[kernel] r5976 - in dists/trunk/linux-2.6/debian: . arch bin

Bastian Blank waldi at costa.debian.org
Mon Feb 27 18:07:22 UTC 2006


Author: waldi
Date: Mon Feb 27 18:07:20 2006
New Revision: 5976

Modified:
   dists/trunk/linux-2.6/debian/arch/defines
   dists/trunk/linux-2.6/debian/bin/gencontrol.py
   dists/trunk/linux-2.6/debian/rules.real
Log:
* debian/arch/defines: Set image type.
* debian/bin/gencontrol.py: Don't supply a default value for the image type.
* debian/rules.real: Support plain images.


Modified: dists/trunk/linux-2.6/debian/arch/defines
==============================================================================
--- dists/trunk/linux-2.6/debian/arch/defines	(original)
+++ dists/trunk/linux-2.6/debian/arch/defines	Mon Feb 27 18:07:20 2006
@@ -15,6 +15,7 @@
  s390
  sparc
 image-ramdisk-generators: yaird initramfs-tools
+type: kernel-package
 
 [mips]
 available: False

Modified: dists/trunk/linux-2.6/debian/bin/gencontrol.py
==============================================================================
--- dists/trunk/linux-2.6/debian/bin/gencontrol.py	(original)
+++ dists/trunk/linux-2.6/debian/bin/gencontrol.py	Mon Feb 27 18:07:20 2006
@@ -77,7 +77,6 @@
 
     def do_flavour_makeflags(self, makeflags, arch, subarch, flavour):
         config_entry = self.config.merge('base', arch, subarch, flavour)
-        makeflags['TYPE'] = 'kernel-package'
         for i in (
             ('compiler', 'COMPILER'),
             ('kernel-arch', 'KERNEL_ARCH'),

Modified: dists/trunk/linux-2.6/debian/rules.real
==============================================================================
--- dists/trunk/linux-2.6/debian/rules.real	(original)
+++ dists/trunk/linux-2.6/debian/rules.real	Mon Feb 27 18:07:20 2006
@@ -56,15 +56,15 @@
 # Targets
 #
 binary-arch-subarch: install-header-$(ARCH)-$(SUBARCH)
-binary-arch-flavour: install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR) install-header-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
+binary-arch-flavour: install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE) install-header-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
 
 binary-indep: install-doc install-patch install-source install-tree
 
-build: $(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
+build: $(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE)
 
 setup-arch: $(STAMPS_DIR)/source
 setup-subarch:
-setup-flavour: $(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
+setup-flavour: $(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE)
 
 #
 # Generates the kernel config file for a subarch by merging
@@ -119,20 +119,35 @@
 # that in this file it should be always placed *before* the
 # build-$(subarch)-% target, which creates the build directory.
 #
-$(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR): DIR=$(BUILD_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
-$(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR): $(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
+$(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): DIR=$(BUILD_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
+
+$(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-kernel-package: $(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE)
 	cd '$(DIR)'; $(setup_env) PATH='$(CURDIR)/build:$(CURDIR)/bin:$(PATH)' $(kpkg_image) build
 	touch '$@'
 
-$(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR): SOURCE_DIR=$(BUILD_DIR)/source-$(ARCH)-$(SUBARCH)
-$(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR): DIR=$(BUILD_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
-$(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR): $(BUILD_DIR)/config.$(ARCH)-$(SUBARCH)-$(FLAVOUR) $(STAMPS_DIR)/source-$(ARCH)-$(SUBARCH)
+$(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-plain: $(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE)
+	cd '$(DIR)'; $(setup_env) make ARCH=$(KERNEL_ARCH)
+	touch '$@'
+
+$(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): SOURCE_DIR=$(BUILD_DIR)/source-$(ARCH)-$(SUBARCH)
+$(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): DIR=$(BUILD_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
+
+$(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-kernel-package: $(BUILD_DIR)/config.$(ARCH)-$(SUBARCH)-$(FLAVOUR) $(STAMPS_DIR)/source-$(ARCH)-$(SUBARCH)
 	rm -rf '$(DIR)'
 	cp -al '$(SOURCE_DIR)' '$(DIR)'
 	cp '$<' '$(DIR)/.config'
 	cd '$(DIR)'; $(setup_env) $(kpkg_image) configure
 	touch '$@'
 
+$(STAMPS_DIR)/setup-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-plain: $(BUILD_DIR)/config.$(ARCH)-$(SUBARCH)-$(FLAVOUR) $(STAMPS_DIR)/source-$(ARCH)-$(SUBARCH)
+	rm -rf '$(DIR)'
+	cp -al '$(SOURCE_DIR)' '$(DIR)'
+	cp '$<' '$(DIR)/.config'
+	# TODO
+	echo '$(KPKG_ABINAME)$(LOCALVERSION)' > '$(DIR)/localversion'
+	cd '$(DIR)'; $(setup_env) make prepare ARCH=$(KERNEL_ARCH)
+	touch '$@'
+
 install-base:
 	dh_installchangelogs
 	dh_installdocs
@@ -170,24 +185,6 @@
 	dh_clean -d -k
 	$(MAKE) -f debian/rules.real install-base
 
-install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR): SOURCE_DIR=$(BUILD_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
-install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR): DIR=$(BUILD_DIR)/$@
-install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR): $(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
-	rm -rf '$(DIR)'
-	cp -al '$(SOURCE_DIR)' '$(DIR)'
-ifdef IMAGE_POSTPROC
-#	Install the postproc script into the hook directory
-	install -d '$(DIR)/debian/image.d'
-	install 'debian/bin/$(IMAGE_POSTPROC)' '$(DIR)/debian/image.d'
-endif
-	cd '$(DIR)'; $(setup_env) $(kpkg_image) kernel-image
-	cat '$(DIR)/debian/files' >> debian/files
-	@for i in $$(awk '{ print $$1; }' '$(DIR)/debian/files'); do	\
-	  echo "mv \"$(BUILD_DIR)/$$i\" ..";				\
-	  mv "$(BUILD_DIR)/$$i" ..;					\
-	done
-	rm -rf '$(DIR)'
-
 install-header-$(ARCH)-$(SUBARCH): PACKAGE_NAME = linux-headers-$(VERSION)-$(ABINAME)$(LOCALVERSION_HEADERS)
 install-header-$(ARCH)-$(SUBARCH): DH_OPTIONS = -p$(PACKAGE_NAME)
 install-header-$(ARCH)-$(SUBARCH): BASE_DIR = /usr/src/$(PACKAGE_NAME)
@@ -226,7 +223,7 @@
 install-header-$(ARCH)-$(SUBARCH)-$(FLAVOUR): REF_DIR = $(BUILD_DIR)/source-$(ARCH)-$(SUBARCH)
 install-header-$(ARCH)-$(SUBARCH)-$(FLAVOUR): PACKAGE_DIR = $(CURDIR)/debian/$(PACKAGE_NAME)
 install-header-$(ARCH)-$(SUBARCH)-$(FLAVOUR): DIR = $(PACKAGE_DIR)/$(BASE_DIR)
-install-header-$(ARCH)-$(SUBARCH)-$(FLAVOUR): $(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
+install-header-$(ARCH)-$(SUBARCH)-$(FLAVOUR): $(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE)
 	dh_testdir
 	dh_testroot
 	dh_clean -k -d
@@ -300,6 +297,38 @@
 	dh_python $(DH_OPTIONS) -V 2.4 /usr/src/linux-headers-$(VERSION)/lib/python
 	$(MAKE) -f debian/rules.real install-base DH_OPTIONS='$(DH_OPTIONS)'
 
+install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): REAL_VERSION = $(VERSION)-$(ABINAME)$(LOCALVERSION)
+install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): PACKAGE_NAME = linux-image-$(REAL_VERSION)
+install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): PACKAGE_DIR = $(CURDIR)/debian/$(PACKAGE_NAME)
+install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): SOURCE_DIR=$(BUILD_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)
+install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): DIR=$(BUILD_DIR)/$@
+install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE): DH_OPTIONS = -p$(PACKAGE_NAME)
+
+install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-kernel-package: $(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE)
+	rm -rf '$(DIR)'
+	cp -al '$(SOURCE_DIR)' '$(DIR)'
+ifdef IMAGE_POSTPROC
+#	Install the postproc script into the hook directory
+	install -d '$(DIR)/debian/image.d'
+	install 'debian/bin/$(IMAGE_POSTPROC)' '$(DIR)/debian/image.d'
+endif
+	cd '$(DIR)'; $(setup_env) $(kpkg_image) kernel-image
+	cat '$(DIR)/debian/files' >> debian/files
+	@for i in $$(awk '{ print $$1; }' '$(DIR)/debian/files'); do	\
+	  echo "mv \"$(BUILD_DIR)/$$i\" ..";				\
+	  mv "$(BUILD_DIR)/$$i" ..;					\
+	done
+	rm -rf '$(DIR)'
+
+install-image-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-plain: $(STAMPS_DIR)/build-$(ARCH)-$(SUBARCH)-$(FLAVOUR)-$(TYPE)
+	dh_testdir
+	dh_testroot
+	dh_clean -d -k
+	dh_installdirs 'boot'
+	cp '$(SOURCE_DIR)/vmlinuz' $(PACKAGE_DIR)/boot/vmlinuz-$(VERSION)-$(ABINAME)$(LOCALVERSION)
+	cd '$(SOURCE_DIR)'; $(setup_env) make modules_install ARCH=$(KERNEL_ARCH) INSTALL_MOD_PATH=$(PACKAGE_DIR)
+	$(MAKE) -f debian/rules.real install-base DH_OPTIONS='$(DH_OPTIONS)'
+
 install-patch: PACKAGE = linux-patch-debian-$(VERSION)
 install-patch: pbase := /usr/src/kernel-patches/all/$(SOURCE_UPSTREAM)
 install-patch: pfull := debian/$(PACKAGE)$(pbase)



More information about the Kernel-svn-changes mailing list