From patchwork Mon Apr 4 20:45:39 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Guilherme Salgado X-Patchwork-Id: 901 Return-Path: Delivered-To: unknown Received: from imap.gmail.com (74.125.159.109) by localhost6.localdomain6 with IMAP4-SSL; 08 Jun 2011 14:47:12 -0000 Delivered-To: patches@linaro.org Received: by 10.68.42.132 with SMTP id o4cs74072pbl; Mon, 4 Apr 2011 13:45:43 -0700 (PDT) Received: by 10.227.182.135 with SMTP id cc7mr7782754wbb.91.1301949941631; Mon, 04 Apr 2011 13:45:41 -0700 (PDT) Received: from adelie.canonical.com (adelie.canonical.com [91.189.90.139]) by mx.google.com with ESMTP id l8si10734764wbg.147.2011.04.04.13.45.40; Mon, 04 Apr 2011 13:45:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.139 as permitted sender) client-ip=91.189.90.139; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.139 as permitted sender) smtp.mail=bounces@canonical.com Received: from loganberry.canonical.com ([91.189.90.37]) by adelie.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1Q6qeZ-0003hD-HS for ; Mon, 04 Apr 2011 20:45:39 +0000 Received: from loganberry.canonical.com (localhost [127.0.0.1]) by loganberry.canonical.com (Postfix) with ESMTP id 1017E2E8914 for ; Mon, 4 Apr 2011 20:45:39 +0000 (UTC) MIME-Version: 1.0 X-Launchpad-Project: linaro-image-tools X-Launchpad-Branch: ~linaro-maintainers/linaro-image-tools/trunk X-Launchpad-Message-Rationale: Subscriber X-Launchpad-Branch-Revision-Number: 309 X-Launchpad-Notification-Type: branch-revision To: Linaro Patch Tracker From: noreply@launchpad.net Subject: [Branch ~linaro-maintainers/linaro-image-tools/trunk] Rev 309: Unbreak generation of vexpress images Message-Id: <20110404204539.10794.78346.launchpad@loganberry.canonical.com> Date: Mon, 04 Apr 2011 20:45:39 -0000 Reply-To: noreply@launchpad.net Sender: bounces@canonical.com Errors-To: bounces@canonical.com Precedence: bulk X-Generated-By: Launchpad (canonical.com); Revision="12734"; Instance="initZopeless config overlay" X-Launchpad-Hash: bd3c6260ec3c04f5c0550196c400505ddda6a0b7 Merge authors: Matt Waddel (mwaddel) Related merge proposals: https://code.launchpad.net/~mwaddel/linaro-image-tools/null-string-vexpress/+merge/56028 proposed by: Matt Waddel (mwaddel) review: Approve - Guilherme Salgado (salgado) ------------------------------------------------------------ revno: 309 [merge] fixes bug(s): https://launchpad.net/bugs/745286 committer: Guilherme Salgado branch nick: trunk timestamp: Mon 2011-04-04 17:31:27 -0300 message: Unbreak generation of vexpress images modified: linaro_image_tools/media_create/boards.py linaro_image_tools/media_create/tests/test_media_create.py --- lp:linaro-image-tools https://code.launchpad.net/~linaro-maintainers/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-maintainers/linaro-image-tools/trunk/+edit-subscription === modified file 'linaro_image_tools/media_create/boards.py' --- linaro_image_tools/media_create/boards.py 2011-04-01 14:18:41 +0000 +++ linaro_image_tools/media_create/boards.py 2011-04-04 16:22:10 +0000 @@ -250,16 +250,15 @@ @classmethod def make_boot_files(cls, uboot_parts_dir, is_live, is_lowmem, consoles, - chroot_dir, rootfs_uuid, boot_dir, boot_script_path, - boot_device_or_file): + chroot_dir, rootfs_uuid, boot_dir, boot_device_or_file): boot_env = cls._get_boot_env(is_live, is_lowmem, consoles, rootfs_uuid) cls._make_boot_files( - uboot_parts_dir, boot_env, chroot_dir, boot_dir, boot_script_path, + uboot_parts_dir, boot_env, chroot_dir, boot_dir, boot_device_or_file) @classmethod def _make_boot_files(cls, uboot_parts_dir, boot_env, chroot_dir, boot_dir, - boot_script_path, boot_device_or_file): + boot_device_or_file): """Make the necessary boot files for this board. This is usually board-specific so ought to be defined in every @@ -287,11 +286,9 @@ cmd_runner.run( ['cp', '-v', uboot_bin, boot_disk], as_root=True).wait() - boot_script_path = os.path.join(boot_disk, cls.boot_script) - cls.make_boot_files( uboot_parts_dir, is_live, is_lowmem, consoles, chroot_dir, - rootfs_uuid, boot_disk, boot_script_path, boot_device_or_file) + rootfs_uuid, boot_disk, boot_device_or_file) cmd_runner.run(['sync']).wait() try: @@ -346,23 +343,23 @@ @classmethod def make_boot_files(cls, uboot_parts_dir, is_live, is_lowmem, consoles, - chroot_dir, rootfs_uuid, boot_dir, boot_script_path, - boot_device_or_file): + chroot_dir, rootfs_uuid, boot_dir, boot_device_or_file): # XXX: This is also part of our temporary hack to fix bug 697824; we # need to call set_appropriate_serial_tty() before doing anything that # may use cls.serial_tty. cls.set_appropriate_serial_tty(chroot_dir) super(OmapConfig, cls).make_boot_files( uboot_parts_dir, is_live, is_lowmem, consoles, chroot_dir, - rootfs_uuid, boot_dir, boot_script_path, boot_device_or_file) + rootfs_uuid, boot_dir, boot_device_or_file) @classmethod def _make_boot_files(cls, uboot_parts_dir, boot_env, chroot_dir, boot_dir, - boot_script_path, boot_device_or_file): + boot_device_or_file): install_omap_boot_loader(chroot_dir, boot_dir) make_uImage( cls.load_addr, uboot_parts_dir, cls.kernel_suffix, boot_dir) make_uInitrd(uboot_parts_dir, cls.kernel_suffix, boot_dir) + boot_script_path = os.path.join(boot_dir, cls.boot_script) make_boot_script(boot_env, boot_script_path) make_boot_ini(boot_script_path, boot_dir) @@ -414,10 +411,11 @@ @classmethod def _make_boot_files(cls, uboot_parts_dir, boot_env, chroot_dir, boot_dir, - boot_script_path, boot_device_or_file): + boot_device_or_file): make_uImage( cls.load_addr, uboot_parts_dir, cls.kernel_suffix, boot_dir) make_uInitrd(uboot_parts_dir, cls.kernel_suffix, boot_dir) + boot_script_path = os.path.join(boot_dir, cls.boot_script) make_boot_script(boot_env, boot_script_path) make_boot_ini(boot_script_path, boot_dir) @@ -440,10 +438,11 @@ @classmethod def _make_boot_files(cls, uboot_parts_dir, boot_env, chroot_dir, boot_dir, - boot_script_path, boot_device_or_file): + boot_device_or_file): make_uImage( cls.load_addr, uboot_parts_dir, cls.kernel_suffix, boot_dir) make_uInitrd(uboot_parts_dir, cls.kernel_suffix, boot_dir) + boot_script_path = os.path.join(boot_dir, cls.boot_script) make_boot_script(boot_env, boot_script_path) @@ -485,13 +484,14 @@ @classmethod def _make_boot_files(cls, uboot_parts_dir, boot_env, chroot_dir, boot_dir, - boot_script_path, boot_device_or_file): + boot_device_or_file): uboot_file = os.path.join( chroot_dir, 'usr', 'lib', 'u-boot', cls.uboot_flavor, 'u-boot.imx') install_mx5_boot_loader(uboot_file, boot_device_or_file) make_uImage( cls.load_addr, uboot_parts_dir, cls.kernel_suffix, boot_dir) make_uInitrd(uboot_parts_dir, cls.kernel_suffix, boot_dir) + boot_script_path = os.path.join(boot_dir, cls.boot_script) make_boot_script(boot_env, boot_script_path) @@ -542,7 +542,7 @@ @classmethod def _make_boot_files(cls, uboot_parts_dir, boot_env, chroot_dir, boot_dir, - boot_script_path, boot_device_or_file): + boot_device_or_file): make_uImage( cls.load_addr, uboot_parts_dir, cls.kernel_suffix, boot_dir) make_uInitrd(uboot_parts_dir, cls.kernel_suffix, boot_dir) @@ -604,7 +604,7 @@ @classmethod def _make_boot_files(cls, uboot_parts_dir, boot_env, chroot_dir, boot_dir, - boot_script_path, boot_device_or_file): + boot_device_or_file): uboot_file = os.path.join( chroot_dir, 'usr', 'lib', 'u-boot', 'smdkv310', 'u-boot.v310') install_smdkv310_boot_loader(uboot_file, boot_device_or_file) @@ -623,6 +623,7 @@ # unused at the moment once FAT support enabled for the # Samsung u-boot this can be used bug 727978 + #boot_script_path = os.path.join(boot_dir, cls.boot_script) #make_boot_script(boot_env, boot_script_path) === modified file 'linaro_image_tools/media_create/tests/test_media_create.py' --- linaro_image_tools/media_create/tests/test_media_create.py 2011-03-29 13:28:38 +0000 +++ linaro_image_tools/media_create/tests/test_media_create.py 2011-04-04 20:13:55 +0000 @@ -170,7 +170,7 @@ classmethod(set_appropriate_serial_tty_mock))) def make_boot_files(self, config): - config.make_boot_files('', False, False, [], '', '', '', '', '') + config.make_boot_files('', False, False, [], '', '', '', '') def test_vexpress_steps(self): self.make_boot_files(boards.VexpressConfig) @@ -278,7 +278,7 @@ # we're only interested in ensuring that OmapConfig.make_boot_files() # calls set_appropriate_serial_tty(). board_configs['beagle'].make_boot_files( - None, None, None, None, None, None, None, None, None) + None, None, None, None, None, None, None, None) self.assertTrue( self.set_appropriate_serial_tty_called, "make_boot_files didn't call set_appropriate_serial_tty") @@ -928,10 +928,10 @@ expected_args = ( 'chroot_dir/boot', False, False, [], 'chroot_dir', 'rootfs_uuid', - 'boot_disk', 'boot_disk/boot_script', 'boot_device_or_file') + 'boot_disk', 'boot_device_or_file') expected_args_live = ( 'chroot_dir/casper', True, False, [], 'chroot_dir', 'rootfs_uuid', - 'boot_disk', 'boot_disk/boot_script', 'boot_device_or_file') + 'boot_disk', 'boot_device_or_file') expected_calls = [ 'mkdir -p boot_disk', '%s mount boot_partition boot_disk' % sudo_args,