toolchain-external: clarify rsync excludes in copy_toolchain_sysroot
authorThomas De Schampheleire <thomas.de_schampheleire@nokia.com>
Tue, 7 Feb 2017 21:56:40 +0000 (22:56 +0100)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Wed, 5 Apr 2017 19:09:39 +0000 (21:09 +0200)
commit367f4abcf9f56787b57cdd231e57fa7ac718cd2d
treef4ab9ba17bc6e7ca18ea60676de9e9070e574d7d
parenta4c4cecd87851bdb3cbd4803a94df7602b102c42
toolchain-external: clarify rsync excludes in copy_toolchain_sysroot

The copy_toolchain_sysroot helper features a complex rsync loop that copies
various directories from the extracted toolchain to the staging directory.
The complexity mainly stems from the fact that we support multilib toolchain
tarballs but only copy one of the multilib variants into staging.

Increase understandability of this logic by explicitly restricting the
rsync excludes to the iteration of the for loop they are relevant for.
Additionally, update the function comment.

Note: all attempts to reduce duplication between both rsync while keeping
things nice and readable failed. One has to be extremely careful regarding
line continuation, indentation, and single vs double quoting. In the end, a
split up rsync seemed most clean.

Signed-off-by: Thomas De Schampheleire <thomas.de_schampheleire@nokia.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
toolchain/helpers.mk