Skip to contentSkip to conversation

how to clean up everything but the toolchain

Buildroot Sven Neumann 3 participants 4 messages Oct 1, 2009

lore
Share & tools
lore
#0 lore raw

Hi,

we are using buildroot to build a number of projects for the same platform. Currently we do this simply by changing the .config file. In order for the build to work after changing the .config file, we remove the project_build_arm, build_arm and toolchain_build_arm directories. So basically we are doing a full rebuild, including the toolchain. We could save a lot of CPU cycles if we could reuse the toolchain build. However I found that if I remove the build_arm directory, but not the toolchain_build_arm directory, things will break. So I wonder if there is an easy solution to this. Perhaps a make target that we didn't discover yet?

Sven

#1 lore raw

Le Thu, 01 Oct 2009 10:04:33 +0200,
Sven Neumann <[email protected]> a ?crit :

Quoted 10 lines

we are using buildroot to build a number of projects for the same platform. Currently we do this simply by changing the .config file. In order for the build to work after changing the .config file, we remove the project_build_arm, build_arm and toolchain_build_arm directories. So basically we are doing a full rebuild, including the toolchain. We could save a lot of CPU cycles if we could reuse the toolchain build. However I found that if I remove the build_arm directory, but not the toolchain_build_arm directory, things will break. So I wonder if there is an easy solution to this. Perhaps a make target that we didn't discover yet?

This is something we should definitely support, but I'm not sure yet how to achieve that. At least of the mandatory component is to be able to cleanly remove packages from the staging/ and target/ directories. And this requires a global infrastructure used by all packages (like Makefile.autotools.in, but more generic). I've started working on this, but it will take some time (fairly complex + limited free time).

However, what I'm doing currently is that I use external toolchains (that's the reason for which I improved a little the external toolchain support in Buildroot). Toolchain is generated once for all with Crosstool-ng, and then Buildroot is only used to build the root filesystem.

Sincerly,

Thomas

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers and embedded Linux development,
consulting, training and support.
http://free-electrons.com
#2 lore raw
In reply to Sven Neumann
Quoted 12 lines · Sven Neumann

Hi,

we are using buildroot to build a number of projects for the same platform. Currently we do this simply by changing the .config file. In order for the build to work after changing the .config file, we remove the project_build_arm, build_arm and toolchain_build_arm directories. So basically we are doing a full rebuild, including the toolchain. We could save a lot of CPU cycles if we could reuse the toolchain build. However I found that if I remove the build_arm directory, but not the toolchain_build_arm directory, things will break. So I wonder if there is an easy solution to this. Perhaps a make target that we didn't discover yet?

I have found it sufficient to remove build_arm and project_build_arm. Some stuff in the toolchain still gets rebuilt but not as much as a full rebuild.

#3 lore raw
Quoted 3 lines · Will Newton

I have found it sufficient to remove build_arm and project_build_arm. Some stuff in the toolchain still gets rebuilt but not as much as a full rebuild.

I found that the build will fail if I do that. Might be specific to our setup though.

Sven