toolchain helpers: introduce function relpath_prefix
authorThomas De Schampheleire <thomas.de_schampheleire@nokia.com>
Tue, 7 Feb 2017 21:56:42 +0000 (22:56 +0100)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Wed, 5 Apr 2017 19:27:33 +0000 (21:27 +0200)
commita2596422d762eeb7902b62821d4c7a26fa1f958b
tree5b918e8e2f2f6b93a4b813f990a29483c2a15dea
parentba6bac138331cea449592f877e558f84176a70bf
toolchain helpers: introduce function relpath_prefix

The helper function copy_toolchain_sysroot has some logic to transform a
path into a number of '../' components based on the depth of that path.

As this same logic will be needed in another place in a subsequent patch,
extract it into a separate helper relpath_prefix.

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