[OpenWrt-Devel] project: build speed-up with binary injection
john at phrozen.org
Thu Sep 13 00:45:58 EDT 2018
On 12/09/18 23:15, Etienne Champetier wrote:
> Hi Pieter,
> Le mer. 12 sept. 2018 à 15:20, Pieter Smith <pieter at boesman.nl> a écrit :
>> Hi all,
>> I would like to extend the OpenWRT build system to allow a substantial
>> speed-up with optional pre-built binary injection. The goal is to
>> perform the full distro build including toolchain in less than 10 min
>> for the product that we develop.
>> My proposal is to augment the build so that build results can optionally
>> be published of fetched. Locally compiled build results can be published
>> for potential fetch and injection on future builds by other developers
>> or build slaves.
>> Above all the implementation should guarantee repeatability and
>> consistency. A fetch and inject speed up will only be allowed if it does
>> not violate this requirement.
>> So far I have come up with the idea to guarantee this by publishing
>> build results under a strong hash (sha1 or better). The hash is
>> based on the source state of what needs to be built, and the hashes of
>> all dependencies and configuration leading up to that (Something similar
>> to what git does to calculate a commit id).
>> If the calculated hash for what has to be built can be fetched and
>> injected, consistency is guaranteed and the speedup is safe. If the
>> calculated hash has not been built before, the build step is performed
>> and the result is published under the calculated hash.
>> Can anyone comment on the above?
>> Pieter Smith
>> P.S. If I missed something existing that can already achieve some of the
>> build speed-up, please let me know.
> Never tried it myself, but have you tried ccache ?
>> openwrt-devel mailing list
>> openwrt-devel at lists.openwrt.org
> openwrt-devel mailing list
> openwrt-devel at lists.openwrt.org
Look at the image builder it uses pre-built ipks to generate images in
less than 30s. if you have a custom ipk, you can build it using the SDK.
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
More information about the openwrt-devel