summaryrefslogtreecommitdiff
path: root/external/graphite/StaticLibrary_graphite.mk
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@collabora.com>2019-04-11 21:17:43 +0200
committerJan Holesovsky <kendy@collabora.com>2019-06-05 22:19:34 +0200
commit3f358c1f29102a6a6e548e555b18086faebb6196 (patch)
treeec6699a1b00e25f00116f5eb7d3a8e9baa5abdbe /external/graphite/StaticLibrary_graphite.mk
parentae94f1d1b441068a1baba31eef1549ae895180ba (diff)
graphite: Force optimization on Android.
The Pass.cpp triggers an infinite loop in clang when not optimizing (ie. with the debugging buildls), at least with this version: > ~/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin/clang++ --version Android (5058415 based on r339409) clang version 8.0.2 (https://android.googlesource.com/toolchain/clang 40173bab62ec746213857d083c0e8b0abb568790) (https://android.googlesource.com/toolchain/llvm 7a6618d69e7e8111e1d49dc9e7813767c5ca756a) (based on LLVM 8.0.2svn) Target: x86_64-unknown-linux-gnu Thread model: posix InstalledDir: /local/home/kendy/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/linux-x86_64/bin Change-Id: Ib4984f8838fc733be6da4e24eb10915d3efbf79e
Diffstat (limited to 'external/graphite/StaticLibrary_graphite.mk')
-rw-r--r--external/graphite/StaticLibrary_graphite.mk9
1 files changed, 9 insertions, 0 deletions
diff --git a/external/graphite/StaticLibrary_graphite.mk b/external/graphite/StaticLibrary_graphite.mk
index 8c16482ba11b..75d1fe84071b 100644
--- a/external/graphite/StaticLibrary_graphite.mk
+++ b/external/graphite/StaticLibrary_graphite.mk
@@ -32,6 +32,15 @@ $(eval $(call gb_StaticLibrary_add_cxxflags,graphite,\
endif
endif
+ifeq ($(OS),ANDROID)
+# Force optimizations on Android, because otherwise Pass.cpp triggers an
+# infinite loop in clang, at least in this version:
+# Android (5058415 based on r339409) clang version 8.0.2 (https://android.googlesource.com/toolchain/clang 40173bab62ec746213857d083c0e8b0abb568790) (https://android.googlesource.com/toolchain/llvm 7a6618d69e7e8111e1d49dc9e7813767c5ca756a) (based on LLVM 8.0.2svn)
+$(eval $(call gb_StaticLibrary_add_cxxflags,graphite,\
+ -Os \
+))
+endif
+
$(eval $(call gb_StaticLibrary_set_generated_cxx_suffix,graphite,cpp))
$(eval $(call gb_StaticLibrary_add_generated_exception_objects,graphite,\