diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2019-05-17 06:56:07 +0200 |
---|---|---|
committer | Michael Olbrich <m.olbrich@pengutronix.de> | 2019-05-17 06:56:10 +0200 |
commit | bf823c8e7e7b4c8bcbc363f320979cf36929558d (patch) | |
tree | b6883b6ebbbd65535e3f74b2c22327e69b1fb270 /bin/ptxdist | |
parent | 2f3ab69844bf3d62a31704b6b5efba7576b52781 (diff) | |
download | ptxdist-bf823c8e7e7b4c8bcbc363f320979cf36929558d.tar.gz ptxdist-bf823c8e7e7b4c8bcbc363f320979cf36929558d.tar.xz |
ptxdist: allow overwriting wrapper scripts in the BSP
This makes it possible to overwrite individual wrapper scripts in the BSP.
Copy the files instead of using symlinks now. This is necessary to find
libwrapper.sh by resolving all links.
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Diffstat (limited to 'bin/ptxdist')
-rwxr-xr-x | bin/ptxdist | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/bin/ptxdist b/bin/ptxdist index ddcbef195..03d6a37ff 100755 --- a/bin/ptxdist +++ b/bin/ptxdist @@ -610,6 +610,8 @@ check_compiler() { mkdir -p -- "${wrapper_dir}/real" || ptxd_bailout "cannot create dir: '${wrapper_dir}/real'" + ptxd_replace_copy_from_path PTXDIST_PATH \ + scripts/wrapper/libwrapper.sh "${wrapper_dir}/libwrapper.sh" for cc_ptr in \ PTXCONF_SETUP_HOST_CPP \ @@ -653,7 +655,8 @@ check_compiler() { esac ptxd_replace_link "${cc_abs}" "${wrapper_dir}/real/${cc_default}" && - ptxd_replace_link "${SCRIPTSDIR}/wrapper/host-${cc_default}-wrapper" "${wrapper_dir}/${cc_default}" && + ptxd_replace_copy_from_path PTXDIST_PATH "scripts/wrapper/host-${cc_default}-wrapper" \ + "${wrapper_dir}/${cc_default}" && if [ -n "${cc_alternate}" ]; then ptxd_replace_link "${cc_default}" "${wrapper_dir}/${cc_alternate}" && @@ -771,7 +774,8 @@ check_compiler() { ptxd_replace_link "${toolchain}" "${PTXDIST_PLATFORMDIR}/selected_toolchain" && for cc in gcc g++ cpp ld gdb; do ptxd_replace_link "${toolchain}/${compiler_prefix}${cc}" "${wrapper_dir}/real/${compiler_prefix}${cc}" && - ptxd_replace_link "${SCRIPTSDIR}/wrapper/${cc}-wrapper" "${wrapper_dir}/${compiler_prefix}${cc}" + ptxd_replace_copy_from_path PTXDIST_PATH "scripts/wrapper/${cc}-wrapper" \ + "${wrapper_dir}/${compiler_prefix}${cc}" done && for tool in "${toolchain}/${compiler_prefix}"* ; do local toolname="$(basename "${tool}")" |