toolchain-external: strip trailing slash from autogenerated FOO_SITE
authorLuca Ceresoli <luca@lucaceresoli.net>
Sat, 3 Oct 2015 17:22:16 +0000 (19:22 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sun, 4 Oct 2015 14:46:11 +0000 (15:46 +0100)
commite4624fce8a7ff26dc232901c2b45b49ea6a52662
tree49a97d62a43d1a642d28b550d58d81ef462e0a4d
parentb82ea7e22ec4a64ff29f549dd6ff4f276f8b7c22
toolchain-external: strip trailing slash from autogenerated FOO_SITE

Trailing slashes are going to be declared illegal from FOO_SITE
variables.

But Buildroot internally generates such a variable when using a custom
external toolchain (i.e. BR2_TOOLCHAIN_EXTERNAL_CUSTOM). This is
because TOOLCHAIN_EXTERNAL_SITE is set to
$(dir $(call qstrip,$(BR2_TOOLCHAIN_EXTERNAL_URL))), and $(dir)
leaves a trailing slash.

Fix it using patsubst, just like linux and the bootloaders do.

Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Reported-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Arnout Vandecappelle <arnout@mind.be>
Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
toolchain/toolchain-external/toolchain-external.mk