From: Clark Laughlin Subject: [PATCH v2] mkdeb: correctly map package architectures for x86 and ARM Date: Wed, 12 Nov 2014 09:38:48 -0600 Message-ID: <1415806728-28484-1-git-send-email-clark.laughlin@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XoZyc-0000f1-77 for xen-devel@lists.xenproject.org; Wed, 12 Nov 2014 15:36:58 +0000 Received: by mail-oi0-f46.google.com with SMTP id g201so8730816oib.19 for ; Wed, 12 Nov 2014 07:36:54 -0800 (PST) List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xenproject.org Cc: Clark Laughlin List-Id: xen-devel@lists.xenproject.org mkdeb previously set the package architecture to be 'amd64' for anything other than XEN_TARGET_ARCH=x86_32. This patch attempts to correctly map the architecture from GNU names to debian names for x86 and ARM architectures, or otherwise, defaults it to the value in XEN_TARGET_ARCH. Signed-off-by: Clark Laughlin --- Changed since v1: corrected commit message / subject --- tools/misc/mkdeb | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/tools/misc/mkdeb b/tools/misc/mkdeb index 3bbf881..4d14d9e 100644 --- a/tools/misc/mkdeb +++ b/tools/misc/mkdeb @@ -13,11 +13,16 @@ fi cd $1 version=$2 -if test "$XEN_TARGET_ARCH" = "x86_32"; then - arch=i386 -else - arch=amd64 -fi + +# map the architecture, if necessary +arch=$XEN_TARGET_ARCH +case "$XEN_TARGET_ARCH" in + x86_32) arch=i386 ;; + i686) arch=i386 ;; + x86_64) arch=amd64 ;; + arm32) arch=armhf ;; + aarch64) arch=arm64 ;; +esac # Prepare the directory to package cd dist -- 1.9.1