Browse Source

fix sysroot detection for android toolchains

clang don't know gcc's print-sysroot-parameter, so have to set it manually
pull/51/head
WXbet 4 years ago
committed by GitHub
parent
commit
f136c9871e
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      support/functions/_toolchain

2
support/functions/_toolchain

@ -211,7 +211,7 @@ _toolchain_check(){
[ ${#_realcompiler} -gt 4 ] && compilername="$_realcompiler" [ ${#_realcompiler} -gt 4 ] && compilername="$_realcompiler"
version=$("./$compilername" -dumpversion) version=$("./$compilername" -dumpversion)
machine=$("./$compilername" -dumpmachine) machine=$("./$compilername" -dumpmachine)
sr=$("./$compilername" -print-sysroot 2>/dev/null) [ "$_androidndkdir" == "1" ] && sr="$tcdir/$1/sysroot" || sr=$("./$compilername" -print-sysroot 2>/dev/null)
sysroot=${sr#"$tcdir/$1/bin/../"} sysroot=${sr#"$tcdir/$1/bin/../"}
compilerpath=$(realpath ./$compilername) compilerpath=$(realpath ./$compilername)
printf "$w_l GCC Version :$y_l $version\n" printf "$w_l GCC Version :$y_l $version\n"

Loading…
Cancel
Save