[Buildroot] [PATCH 1/1] package/pkg-generic.mk: add --delete to rsync

Thomas Petazzoni thomas.petazzoni at free-electrons.com
Sun Oct 12 16:26:00 UTC 2014


Dear Alvaro G. M,

On Fri, 10 Oct 2014 11:14:47 +0200, Alvaro G. M wrote:
> When a source overriden package is built and then its source code is modified
> and rebuilt with make package-rebuild, it is needed for the build directory
> to contain exactly the same source that is in the original directory,
> so rsync must not only copy missing files, but also remove those that existed
> previously but now don't.
> 
> Signed-off-by: Alvaro G. M <alvaro.gamez at hazent.com>
> ---
>  package/pkg-generic.mk | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

The fact that adding --delete would delete all object/generated files
makes this patch really not usable, as it basically kills completely
the entire purpose of OVERRIDE_SRCDIR + make <foo>-rebuild. We think
that the small advantage brought by this patch is largely outweighed by
the major inconvenience it causes. The build system of most packages is
reasonable, and will not take into account random source files hanging
around. If the build system of your package is so broken that it builds
random files by just building *.c or *.cpp, then it's really the build
system that should be fixed.

Since there is no way to distinguish the files to remove from the files
to keep, we prefer to keep them all, in order to keep its usefulness to
'make <foo>-rebuild'.

As a consequence, we've marked the patch as Rejected in our patch
tracking system.

Best regards,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com



More information about the buildroot mailing list