From 6fbafbc4c9a4bfbe3a18c3458ec3c2e622500035 Mon Sep 17 00:00:00 2001 From: Robin Watts Date: Fri, 29 Jan 2016 15:09:12 +0000 Subject: Update Android build with Harfbuzz --- platform/android/jni/Core.mk | 1 + platform/android/jni/ThirdParty.mk | 44 ++++++++++++++++++++++++++++++++++++-- 2 files changed, 43 insertions(+), 2 deletions(-) diff --git a/platform/android/jni/Core.mk b/platform/android/jni/Core.mk index 4a2b636a..6dcb8f1b 100644 --- a/platform/android/jni/Core.mk +++ b/platform/android/jni/Core.mk @@ -31,6 +31,7 @@ LOCAL_CFLAGS += -DHAVE_OPENSSL endif LOCAL_C_INCLUDES := \ + ../../thirdparty/harfbuzz/src \ ../../thirdparty/jbig2dec \ ../../thirdparty/openjpeg/libopenjpeg \ ../../thirdparty/jpeg \ diff --git a/platform/android/jni/ThirdParty.mk b/platform/android/jni/ThirdParty.mk index b6ba26b6..d7140dfa 100644 --- a/platform/android/jni/ThirdParty.mk +++ b/platform/android/jni/ThirdParty.mk @@ -5,6 +5,8 @@ include $(CLEAR_VARS) MY_ROOT := ../.. LOCAL_C_INCLUDES := \ + ../../include/ \ + ../../thirdparty/harfbuzz/src \ ../../thirdparty/jbig2dec \ ../../thirdparty/openjpeg/libopenjpeg \ ../../thirdparty/jpeg \ @@ -13,13 +15,16 @@ LOCAL_C_INCLUDES := \ ../../thirdparty/freetype/include \ ../../scripts/freetype \ ../../scripts/jpeg \ - ../../scripts/openjpeg \ + ../../scripts/openjpeg LOCAL_CFLAGS := \ -DFT2_BUILD_LIBRARY -DDARWIN_NO_CARBON -DHAVE_STDINT_H \ -DOPJ_HAVE_STDINT_H \ '-DFT_CONFIG_MODULES_H="slimftmodules.h"' \ - '-DFT_CONFIG_OPTIONS_H="slimftoptions.h"' + '-DFT_CONFIG_OPTIONS_H="slimftoptions.h"' \ + -Dhb_malloc_impl=hb_malloc -Dhb_calloc_impl=hb_calloc \ + -Dhb_realloc_impl=hb_realloc -Dhb_free_impl=hb_free \ + -DHAVE_OT -DHAVE_UCDN -DHB_NO_MT ifdef NDK_PROFILER LOCAL_CFLAGS += -pg -DNDK_PROFILER -O2 endif @@ -27,9 +32,44 @@ ifdef MEMENTO LOCAL_CFLAGS += -DMEMENTO -DMEMENTO_LEAKONLY endif +LOCAL_CPP_EXTENSION := .cc + LOCAL_MODULE := mupdfthirdparty LOCAL_SRC_FILES := \ $(MY_ROOT)/thirdparty/mujs/one.c \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-blob.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-buffer.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-buffer-serialize.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-common.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-face.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-fallback-shape.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-font.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ft.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-font.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-layout.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-map.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-arabic.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-default.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-hangul.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-hebrew.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-indic-table.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-indic.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-myanmar.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-thai.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-tibetan.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-use-table.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-complex-use.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-fallback.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape-normalize.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-shape.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ot-tag.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-set.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-shape-plan.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-shape.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-shaper.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-ucdn.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-unicode.cc \ + $(MY_ROOT)/thirdparty/harfbuzz/src/hb-warning.cc \ $(MY_ROOT)/thirdparty/jbig2dec/jbig2.c \ $(MY_ROOT)/thirdparty/jbig2dec/jbig2_arith.c \ $(MY_ROOT)/thirdparty/jbig2dec/jbig2_arith_iaid.c \ -- cgit v1.2.3