From patchwork Wed Mar 16 00:30:13 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Lo=C3=AFc_Minier?= X-Patchwork-Id: 87131 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from chlorine.canonical.com (chlorine.canonical.com [91.189.94.204]) by ozlabs.org (Postfix) with ESMTP id 60902B6FFE for ; Wed, 16 Mar 2011 11:30:49 +1100 (EST) Received: from localhost ([127.0.0.1] helo=chlorine.canonical.com) by chlorine.canonical.com with esmtp (Exim 4.71) (envelope-from ) id 1PzedM-0001QI-Ea; Wed, 16 Mar 2011 00:30:40 +0000 Received: from pig2.dooz.org ([88.191.118.219]) by chlorine.canonical.com with esmtp (Exim 4.71) (envelope-from ) id 1PzedK-0001Pz-9w for kernel-team@lists.ubuntu.com; Wed, 16 Mar 2011 00:30:38 +0000 Received: from bee.dooz.org (serris.dooz.org [88.166.229.232]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "bee.dooz.org", Issuer "CA Cert Signing Authority" (verified OK)) by pig2.dooz.org (Postfix) with ESMTPS id B9B55C0022; Wed, 16 Mar 2011 00:30:41 +0000 (UTC) Received: by bee.dooz.org (Postfix, from userid 1000) id A9A45137C; Wed, 16 Mar 2011 01:30:30 +0100 (CET) From: =?UTF-8?q?Lo=C3=AFc=20Minier?= To: kernel-team@lists.ubuntu.com Subject: [PATCH 1/6] UBUNTU: Support arch= cross-compilation for any arch Date: Wed, 16 Mar 2011 01:30:13 +0100 Message-Id: <1300235418-19872-2-git-send-email-loic.minier@linaro.org> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1300235418-19872-1-git-send-email-loic.minier@linaro.org> References: <1300235418-19872-1-git-send-email-loic.minier@linaro.org> MIME-Version: 1.0 Cc: =?UTF-8?q?Lo=C3=AFc=20Minier?= X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.13 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kernel-team-bounces@lists.ubuntu.com Errors-To: kernel-team-bounces@lists.ubuntu.com Use "dpkg-architecture -a$(arch) -qDEB_HOST_GNU_TYPE" to compute CROSS_COMPILE when calling debian/rules arch=foo instead of harcoding support for only armel / arm-linux-gnueabi. Signed-off-by: Loïc Minier --- debian/rules.d/0-common-vars.mk | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/debian/rules.d/0-common-vars.mk b/debian/rules.d/0-common-vars.mk index c6e10aa..f6930cb 100644 --- a/debian/rules.d/0-common-vars.mk +++ b/debian/rules.d/0-common-vars.mk @@ -108,9 +108,7 @@ DEB_BUILD_ARCH = $(shell dpkg-architecture -qDEB_BUILD_ARCH) # arch := $(DEB_HOST_ARCH) ifneq ($(arch),$(DEB_HOST_ARCH)) - ifeq ($(arch),armel) - CROSS_COMPILE ?= arm-linux-gnueabi- - endif + CROSS_COMPILE ?= $(shell dpkg-architecture -a$(arch) -qDEB_HOST_GNU_TYPE -f 2>/dev/null)- endif #