[kernel] r14008 - dists/trunk/linux-2.6/debian

Bastian Blank waldi at alioth.debian.org
Sat Jul 25 10:05:34 UTC 2009


Author: waldi
Date: Sat Jul 25 10:05:31 2009
New Revision: 14008

Log:
debian/rules
- Cleanup variables.
- Remove usage of directory creations rules.

Modified:
   dists/trunk/linux-2.6/debian/rules

Modified: dists/trunk/linux-2.6/debian/rules
==============================================================================
--- dists/trunk/linux-2.6/debian/rules	Sat Jul 25 09:07:08 2009	(r14007)
+++ dists/trunk/linux-2.6/debian/rules	Sat Jul 25 10:05:31 2009	(r14008)
@@ -1,24 +1,23 @@
 #!/usr/bin/make -f
-#
-# Generally nothing needs to be modified below this line
-#
+
 SHELL    := sh -e
-DEB_HOST_ARCH  := $(shell dpkg-architecture -qDEB_HOST_ARCH)
-DEB_BUILD_ARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH)
-SOURCE   := $(shell dpkg-parsechangelog | sed -ne 's,^Source: *\(.*\)$$,\1,p')
-VERSION_DEBIAN := $(shell dpkg-parsechangelog | sed -ne 's,^Version: *\(.*\)$$,\1,p')
-VERSION  := $(shell echo "$(VERSION_DEBIAN)" | sed -e 's,-[^-]*$$,,')
-VERSION_DEBIAN_BINNMU := $(shell echo "$(VERSION_DEBIAN)" | sed -ne 's,.*\+b\(.*\)$$,\1,p')
+DEB_HOST_ARCH := $(shell dpkg-architecture -qDEB_HOST_ARCH)
+SOURCE := $(shell dpkg-parsechangelog | sed -ne 's,^Source: *\(.*\)$$,\1,p')
+VERSION := $(shell dpkg-parsechangelog | sed -ne 's,^Version: *\(.*\)$$,\1,p')
+VERSION_UPSTREAM := $(shell echo "$(VERSION)" | sed -e 's,-[^-]*$$,,')
+VERSION_BINNMU := $(shell echo "$(VERSION)" | sed -ne 's,.*\+b\(.*\)$$,\1,p')
 
 include debian/rules.defs
 
+stamp = [ -d $(dir $@) ] || mkdir $(dir $@); touch $@
+
 source: debian/control $(STAMPS_DIR)/source-base
-$(STAMPS_DIR)/source-base: $(BUILD_DIR) $(STAMPS_DIR)
+$(STAMPS_DIR)/source-base:
 	dh_testdir
 	$(MAKE) -f debian/rules.gen source_$(DEB_HOST_ARCH)
-	touch $@
+	@$(stamp)
 
-source-all: debian/control $(BUILD_DIR) $(STAMPS_DIR)
+source-all: debian/control
 	dh_testdir
 	$(MAKE) -f debian/rules.gen source
 
@@ -26,19 +25,16 @@
 $(STAMPS_DIR)/setup-base: $(STAMPS_DIR)/source-base
 	dh_testdir
 	$(MAKE) -f debian/rules.gen setup_$(DEB_HOST_ARCH)
-	touch $@
+	@$(stamp)
 
 build: debian/control $(STAMPS_DIR)/build-base
 $(STAMPS_DIR)/build-base: $(STAMPS_DIR)/setup-base
 	dh_testdir
 	$(MAKE) -f debian/rules.gen build_$(DEB_HOST_ARCH)
-	touch $@
-
-$(BUILD_DIR) $(STAMPS_DIR):
-	@[ -d $@ ] || mkdir $@
+	@$(stamp)
 
-DIR_ORIG = ../orig/$(SOURCE)-$(VERSION)
-TAR_ORIG_NAME = $(SOURCE)_$(VERSION).orig.tar.gz
+DIR_ORIG = ../orig/$(SOURCE)-$(VERSION_UPSTREAM)
+TAR_ORIG_NAME = $(SOURCE)_$(VERSION_UPSTREAM).orig.tar.gz
 TAR_ORIG = $(firstword $(wildcard ../$(TAR_ORIG_NAME)) $(wildcard ../orig/$(TAR_ORIG_NAME)))
 
 orig: $(DIR_ORIG)
@@ -76,7 +72,7 @@
 debian/control debian/rules.gen: debian/bin/gencontrol.py $(CONTROL_FILES)
 ifeq ($(wildcard debian/control.md5sum),)
 	$(MAKE) -f debian/rules debian/control-real
-else ifeq ($(VERSION_DEBIAN_BINNMU),)
+else ifeq ($(VERSION_BINNMU),)
 	md5sum --check debian/control.md5sum --status || \
 		$(MAKE) -f debian/rules debian/control-real
 else



More information about the Kernel-svn-changes mailing list