[U-Boot] [RFC PATCH] tools: get-toolchais: a tool to get cross-tools for all architectures

Joe Hershberger joe.hershberger at gmail.com
Fri May 15 21:52:06 CEST 2015


Hi Masahiro-san,

On Fri, May 15, 2015 at 6:01 AM, Masahiro Yamada
<yamada.masahiro at socionext.com> wrote:
> When we send patches, we are supposed to test them by build utilities
> such as MAKEALL, buildman.  When we want to test global changes, the
> first hurdle is, I think, to collect toolchains for all the architectures.
>
> We have some documents about build utilities, but I have not seen any
> official information about how to get the suitable cross-tools.
> Of course, it is possible to build them from sources, but it is not
> necessarily feasible.
>
> Fortunately, the kernel.org site provides us pre-built toolchains, but
> some architectures are missing.  Also, some boards fail to build with
> the kernel.org tools.  We sometimes see, "where can I get the compiler
> for this architecture?" things on the ML.  We should be able to prepare
> cross-compilers more easily.
>
> It is true that buildman provides --fetch-arch option for downloading
> kernel.org toolchains, but it does not have access to others.  And what
> we really want to know is most likely how to get compilers for such minor
> architectures as kernel.org does not provide.

Maybe just integrate this into buildman? Or remove it from buildman?
In buildman has the benefit that it updates buildman's config to know
how to find the compiler.

> This tool intends to be more generic design without hard-coding such
> kernel.org things.
>
> To achieve that, this tool consists of two files:
> Python script (this file) and the database file containing URLs of tarballs.
>
> We just need to update the latter when new version compilers are released
> (or better compilers are found.)  The file is in the form of RFC 822 for
> easier editing.

Any reason not to just maintain this list on the wiki. It seem this is
the primary issue for everyone... not figuring out how to download or
extract the toolchain.

> The script only uses Python libraries, not relies on external programs
> although it displays wget-like log when downloading tarballs.  :-)

It seems like using wget would be more appropriate. Why reinvent the wheel?

> This is RFC because I am thinking it can be more brushed up.
> If the basis idea is OK, I will improve code, add more comments.
>
> Note this script is written in Python 3 and only works on Python 3.3
> or later.  I do not think it is too much limitation, but some popular
> distributions under support might include older version.  For example,
> looks like Ubuntu 12.04 LTS is shipped with Python 3.2.

Why not write it in something that exists everywhere? If it's just for
downloading tool-chains, seems it should be easy to make it python 2.6
compatible.

> Signed-off-by: Masahiro Yamada <yamada.masahiro at socionext.com>

Cheers,
-Joe


More information about the U-Boot mailing list