diff options
author | kyechou | 2020-12-26 16:10:51 -0600 |
---|---|---|
committer | kyechou | 2020-12-26 16:10:51 -0600 |
commit | 6dc075a89093879d809ce66b8d825bf56de305c8 (patch) | |
tree | e2a8691f63526e68666db6a790d33813cf03e3cd /00-cxx-common-0.1.1.patch | |
parent | 31d5a40606aaa2d15cbcb02dfd33a4f46edb775c (diff) | |
download | aur-6dc075a89093879d809ce66b8d825bf56de305c8.tar.gz |
Use clang as the default compiler and fix the protoc permission issue
Diffstat (limited to '00-cxx-common-0.1.1.patch')
-rw-r--r-- | 00-cxx-common-0.1.1.patch | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/00-cxx-common-0.1.1.patch b/00-cxx-common-0.1.1.patch new file mode 100644 index 000000000000..c2bad224bdae --- /dev/null +++ b/00-cxx-common-0.1.1.patch @@ -0,0 +1,25 @@ +diff --git a/build_dependencies.sh b/build_dependencies.sh +index 11b16ba..1229009 100755 +--- a/build_dependencies.sh ++++ b/build_dependencies.sh +@@ -73,12 +73,20 @@ msg " " "$@" + cd "${repo_dir}" + ( + set -x ++ ++ if type clang >/dev/null 2>&1; then ++ export CC="${CC:-$(which clang)}" ++ export CXX="${CXX:-$(which clang++)}" ++ fi ++ + # TODO: Better way to remove all unspecified packages that we're about to + # install for specified triplet? Need this because different LLVM versions + # conflict when installed at the same time + rm -rf "${vcpkg_dir:?}/installed" || true + "${vcpkg_dir}/vcpkg" install "${extra_vcpkg_args[@]}" '@overlays.txt' '@dependencies.txt' "$@" + "${vcpkg_dir}/vcpkg" upgrade "${extra_vcpkg_args[@]}" '@overlays.txt' --no-dry-run ++ ++ find "${vcpkg_dir}"/installed/*/tools/protobuf/ -type f -exec chmod 755 {} + + ) + ) + |