From patchwork Wed Sep 12 13:57:13 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Tunnicliffe X-Patchwork-Id: 11353 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id B48C223F22 for ; Wed, 12 Sep 2012 13:57:16 +0000 (UTC) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by fiordland.canonical.com (Postfix) with ESMTP id F03503EF93C3 for ; Wed, 12 Sep 2012 13:57:15 +0000 (UTC) Received: by ieak11 with SMTP id k11so2884017iea.11 for ; Wed, 12 Sep 2012 06:57:15 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf :content-type:mime-version:x-launchpad-project:x-launchpad-branch :x-launchpad-message-rationale:x-launchpad-branch-revision-number :x-launchpad-notification-type:to:from:subject:message-id:date :reply-to:sender:errors-to:precedence:x-generated-by :x-launchpad-hash:x-gm-message-state; bh=sjwyL8WwZ/f22T759iWpbbTTpOcHYO+loZe1zEiimpE=; b=Y55E6ASwW51jDtxnZ3qHB+w/xfoP2S5HwosKFOqOMJvD3p/TpjXYDmT0vscArb8cG9 HaHoV9hoPA9cmNMoTqwXJ+D+Lp6DBK7hyMnEItiy3UKi6nnQlaeyPV2dVwbaKn21aU4r IpVOyPRDN64Tj75NAVzF1X9h4fwXKmG+svGEf3WzUFM/4FfjX2sYtYdxktBrrOxkCwEj DrTOsmJGIa0zwcH160jX/2ASYfZzAYXIMPJmQpvkQD3Bq48vjXnPT/WCokak6Y4nDgyW ZSr29ojrFlADEaoe4I+h/YKncCSLcTeFdxQXyDswGNHeutwH6UzM2CJizKTaknldhzny RqEw== Received: by 10.50.207.106 with SMTP id lv10mr21447734igc.0.1347458235289; Wed, 12 Sep 2012 06:57:15 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.50.184.232 with SMTP id ex8csp71712igc; Wed, 12 Sep 2012 06:57:14 -0700 (PDT) Received: by 10.216.241.200 with SMTP id g50mr6379253wer.79.1347458233818; Wed, 12 Sep 2012 06:57:13 -0700 (PDT) Received: from indium.canonical.com (indium.canonical.com. [91.189.90.7]) by mx.google.com with ESMTPS id ds5si11516543wib.15.2012.09.12.06.57.13 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 12 Sep 2012 06:57:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.7 as permitted sender) client-ip=91.189.90.7; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.7 as permitted sender) smtp.mail=bounces@canonical.com Received: from ackee.canonical.com ([91.189.89.26]) by indium.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1TBnRJ-0004V0-3g for ; Wed, 12 Sep 2012 13:57:13 +0000 Received: from ackee.canonical.com (localhost [127.0.0.1]) by ackee.canonical.com (Postfix) with ESMTP id 1035EE04F4 for ; Wed, 12 Sep 2012 13:57:13 +0000 (UTC) MIME-Version: 1.0 X-Launchpad-Project: linaro-image-tools X-Launchpad-Branch: ~linaro-image-tools/linaro-image-tools/trunk X-Launchpad-Message-Rationale: Subscriber X-Launchpad-Branch-Revision-Number: 561 X-Launchpad-Notification-Type: branch-revision To: Linaro Patch Tracker From: noreply@launchpad.net Subject: [Branch ~linaro-image-tools/linaro-image-tools/trunk] Rev 561: Fix V2 style hwpack layout with V3 config file Message-Id: <20120912135713.26423.79899.launchpad@ackee.canonical.com> Date: Wed, 12 Sep 2012 13:57:13 -0000 Reply-To: noreply@launchpad.net Sender: bounces@canonical.com Errors-To: bounces@canonical.com Precedence: bulk X-Generated-By: Launchpad (canonical.com); Revision="15936"; Instance="launchpad-lazr.conf" X-Launchpad-Hash: ce8cb898433298706739d85f0bcb01df4435ac6d X-Gm-Message-State: ALoCoQmNLO7sBHA9rfnlnlYE/Uplz8w4F5KTCRwIki9/WKM28EB1H5H5hQ+trrNSHKZ1lgx7k/w8 Merge authors: James Tunnicliffe (dooferlad) Related merge proposals: https://code.launchpad.net/~dooferlad/linaro-image-tools/fix-bootloader-file-fallback/+merge/123927 proposed by: James Tunnicliffe (dooferlad) review: Approve - Deepti B. Kalakeri (deeptik) ------------------------------------------------------------ revno: 561 [merge] committer: James Tunnicliffe branch nick: linaro-image-tools timestamp: Wed 2012-09-12 14:56:06 +0100 message: Fix V2 style hwpack layout with V3 config file modified: linaro_image_tools/media_create/boards.py --- lp:linaro-image-tools https://code.launchpad.net/~linaro-image-tools/linaro-image-tools/trunk You are subscribed to branch lp:linaro-image-tools. To unsubscribe from this branch go to https://code.launchpad.net/~linaro-image-tools/linaro-image-tools/trunk/+edit-subscription === modified file 'linaro_image_tools/media_create/boards.py' --- linaro_image_tools/media_create/boards.py 2012-09-10 17:50:26 +0000 +++ linaro_image_tools/media_create/boards.py 2012-09-12 10:51:00 +0000 @@ -245,7 +245,12 @@ keys = keys[1:] for f in file_names: - f = os.path.join(base_path, f) + # Check that the base path is needed. If the file doesn't exist, + # try without it (this provides fallback to V2 style directory + # layouts with a V3 config). + path_inc_board_and_bootloader = os.path.join(base_path, f) + if path_inc_board_and_bootloader in hwpack_tarfile.getnames(): + f = path_inc_board_and_bootloader hwpack_tarfile.extract(f, self.tempdir) f = os.path.join(self.tempdir, f) out_files.append(f)