diff options
author | Ray Donnelly <mingw.android@gmail.com> | 2015-12-08 23:17:06 (GMT) |
---|---|---|
committer | Ray Donnelly <mingw.android@gmail.com> | 2016-01-03 15:53:09 (GMT) |
commit | 24d17220a1a11410c980c784b729f4466ab11f3b (patch) | |
tree | e88b6615312b6321aeb595070ba8846a2547d980 /scripts/build | |
parent | 644522fcd0e1788ba2d03630c19835ea617e452d (diff) |
libelf: Cygwin fix for UNC paths
If destdir was / and prefix began with /
then we would attempt to install libelf
to a path beginning with // which is a
UNC path on Cygwin. This is generally
incorrect.
Signed-off-by: Ray Donnelly <mingw.android@gmail.com>
Diffstat (limited to 'scripts/build')
-rw-r--r-- | scripts/build/companion_libs/200-libelf.sh | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/scripts/build/companion_libs/200-libelf.sh b/scripts/build/companion_libs/200-libelf.sh index 58aa315..529bba2 100644 --- a/scripts/build/companion_libs/200-libelf.sh +++ b/scripts/build/companion_libs/200-libelf.sh @@ -135,6 +135,13 @@ do_libelf_backend() { CT_DoExecLog ALL ${make} CT_DoLog EXTRA "Installing libelf" + + # Guard against $destdir$prefix == // + # which is a UNC path on Cygwin/MSYS2 + if [[ ${destdir} == / ]] && [[ ${prefix} == /* ]]; then + destdir= + fi + CT_DoExecLog ALL ${make} instroot="${destdir}" install } |