Allow for inclusion of arch scripts

svn path=/dists/trunk/linux-kbuild-2.6/; revision=15237
This commit is contained in:
Ben Hutchings 2010-02-20 05:01:37 +00:00
parent b3d0268826
commit bb601e3c9a
1 changed files with 17 additions and 2 deletions

19
debian/rules.real vendored
View File

@ -1,5 +1,20 @@
export DH_OPTIONS
DEB_BUILD_ARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH)
KERNEL_ARCH := $(DEB_BUILD_ARCH)
ifneq ($(filter amd64 i386,$(DEB_BUILD_ARCH)),)
KERNEL_ARCH := x86
endif
ifneq ($(filter armeb armel,$(DEB_BUILD_ARCH)),)
KERNEL_ARCH := arm
endif
ifeq (hppa,$(DEB_BUILD_ARCH))
KERNEL_ARCH := parisc
endif
ifeq (mipsel,$(DEB_BUILD_ARCH))
KERNEL_ARCH := mips
endif
include debian/rules.defs
binary-arch: install-kbuild
@ -12,7 +27,7 @@ $(STAMPS_DIR)/build:
rm -rf '$(DIR)'
mkdir -p '$(DIR)'
cp -al $(SOURCE_FILES) '$(DIR)'
$(MAKE) -C $(DIR) top_srcdir=$(CURDIR)
$(MAKE) -C $(DIR) top_srcdir=$(CURDIR) SRCARCH=$(KERNEL_ARCH)
touch '$@'
install-kbuild: PACKAGE_NAME = linux-kbuild-$(VERSION)
@ -24,7 +39,7 @@ install-kbuild: $(STAMPS_DIR)/build
dh_testdir
dh_testroot
dh_clean -k -d
$(MAKE) -C $(SOURCE_DIR) install prefix=$(DIR) top_srcdir=$(CURDIR)
$(MAKE) -C $(SOURCE_DIR) install prefix=$(DIR) top_srcdir=$(CURDIR) SRCARCH=$(KERNEL_ARCH)
dh_link $(BASE_DIR) /usr/src/$(PACKAGE_NAME)
dh_installchangelogs
dh_installdocs