From: Trevor Woerner <trevor.woerner@linaro.org>
To: "Burton, Ross" <ross.burton@intel.com>
Cc: "yocto@yoctoproject.org" <yocto@yoctoproject.org>
Subject: Re: inherit setuptools
Date: Sat, 22 Mar 2014 17:07:29 -0400 [thread overview]
Message-ID: <532DFB91.2030403@linaro.org> (raw)
In-Reply-To: <CAJTo0LYruhkg+c5KOae410SQkV0sRH-h05Y+gL73i1zYfsh0cw@mail.gmail.com>
On 03/22/14 15:45, Burton, Ross wrote:
> On 22 March 2014 11:01, Trevor Woerner <trevor.woerner@linaro.org> wrote:
>> | Traceback (most recent call last):
>> | File
>> "/SSD/build/fsl/build-wandboard-dual/tmp/sysroots/x86_64-linux/usr/bin/bmaptool",
>> line 65, in <module>
>> | from bmaptools import BmapCreate, BmapCopy, BmapHelpers, TransRead
>> | ImportError: No module named bmaptools
> That's interesting because as can be seen in your listing, there *is*
> a module called bmaptools. Does bmap do anything "clever" (read:
> stupid) before it does that import?
Oh wow, you're right. The "bmaptools" python script which is installed
"by-hand" simply does:
#!/usr/bin/python
# EASY-INSTALL-SCRIPT: 'bmap-tools==3.2','bmaptool'
__requires__ = 'bmap-tools==3.2'
import pkg_resources
pkg_resources.run_script('bmap-tools==3.2', 'bmaptool')
Whereas the one installed by using OE looks more like a regular python
script. It's starts with:
#!/usr/bin/env python
[...snip...]
VERSION = "3.2"
import argparse
import sys
import os
import stat
import time
import logging
import tempfile
import traceback
import shutil
import io
from bmaptools import BmapCreate, BmapCopy, BmapHelpers, TransRead
class NamedFile(object):
[...snip...]
And if my understanding of "inherit setuptools" is correct, this class
explicitly circumvents the use of easy-install. (?)
> And FWIW, I didn't get much out of bmap when I tried it because of how
> our images were constructed: all of the sparse segments disappeared
> when a whole-disk image was created. I got a much better win by using
> USB 3: around 10 seconds to write a gigabyte+ image to a stick...
Interesting.
By default an image created by OE will be just slightly larger than what
is required. So a core-image-minimal will be just ~80MB, most of the
empty space is removed, and the image can be dd'ed onto a microSD card
quickly. But unless I partition the device (for example, 4GB microSD
card) myself, the resulting image will only see ~80MB of disk space.
When I force the build to generate a 4GB image (to load into a 4GB
microSD card and have the remaining space available) using dd takes
almost 50 minutes. Using bmap to load the same image onto the same 4GB
card takes under 15 minutes.
So yes, there's no win if you're just burning the image that comes out
of the build, because these images only contain the useful parts. But
the images which come out of the build only create a partition that is
slightly larger than the used space, leaving the rest of the device
unusable (unless you partition it yourself).
Or is there some trick I'm missing?
next prev parent reply other threads:[~2014-03-22 21:07 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-22 11:01 inherit setuptools Trevor Woerner
2014-03-22 19:45 ` Burton, Ross
2014-03-22 21:07 ` Trevor Woerner [this message]
2014-03-25 16:08 ` Trevor Woerner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=532DFB91.2030403@linaro.org \
--to=trevor.woerner@linaro.org \
--cc=ross.burton@intel.com \
--cc=yocto@yoctoproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.