blob: 654f0e0fc616f278b70936f047d06c5839fa5a98 [file] [log] [blame]
Behdad Esfahbod94afeb62012-12-21 11:54:50 -05001##
2## Copyright (C) 2012 The Android Open Source Project
3##
4## Licensed under the Apache License, Version 2.0 (the "License");
5## you may not use this file except in compliance with the License.
6## You may obtain a copy of the License at
7##
8## http://www.apache.org/licenses/LICENSE-2.0
9##
10## Unless required by applicable law or agreed to in writing, software
11## distributed under the License is distributed on an "AS IS" BASIS,
12## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13## See the License for the specific language governing permissions and
14## limitations under the License.
15##
16
Behdad Esfahbod96b80e92014-07-11 17:00:12 -040017#############################################################
18# Note:
19#
20# This file is used to build HarfBuzz within the Android
21# platform itself. If you need to compile HarfBuzz to
22# ship with your Android NDK app, you can use the autotools
23# build system to do so. To do that you need to install a
24# "standalone" toolchain with the NDK, eg:
25#
26# ndk/build/tools/make-standalone-toolchain.sh \
27# --platform=android-18 \
28# --install-dir=/prefix
29#
30# Set PLATFORM_PREFIX eng var to that prefix and make sure
31# the cross-compile tools from PLATFORM_PREFIX are in path.
32# Configure and install HarfBuzz:
33#
34# ./configure --host=arm-linux-androideabi \
35# --prefix=$PLATFORM_PREFIX \
36# --enable-static \
37# --with-freetype \
38# PKG_CONFIG_LIBDIR=$PLATFORM_PREFIX/lib/pkgconfig
39# make install
40#
41# You can first build FreeType the same way:
42#
43# ./configure --host=arm-linux-androideabi \
44# --prefix=$PLATFORM_PREFIX \
45# --enable-static \
46# --without-png \
47# PKG_CONFIG_LIBDIR=$PLATFORM_PREFIX/lib/pkgconfig
48# make install
49#
50
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050051LOCAL_PATH:= $(call my-dir)
52
M1cha2a2b5b82013-09-30 08:55:52 +000053HARFBUZZ_SRC_FILES = \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050054 src/hb-blob.cc \
Behdad Esfahbodd3e14aa2013-02-27 11:06:36 -050055 src/hb-buffer-serialize.cc \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050056 src/hb-buffer.cc \
57 src/hb-common.cc \
Behdad Esfahbod2e3a07a2013-08-26 18:49:07 -040058 src/hb-face.cc \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050059 src/hb-font.cc \
60 src/hb-ot-tag.cc \
61 src/hb-set.cc \
62 src/hb-shape.cc \
63 src/hb-shape-plan.cc \
64 src/hb-shaper.cc \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050065 src/hb-unicode.cc \
66 src/hb-warning.cc \
Behdad Esfahbod9d4ede32014-07-09 16:19:55 -040067 src/hb-ot-font.cc \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050068 src/hb-ot-layout.cc \
69 src/hb-ot-map.cc \
70 src/hb-ot-shape.cc \
71 src/hb-ot-shape-complex-arabic.cc \
72 src/hb-ot-shape-complex-default.cc \
Behdad Esfahbod9d4ede32014-07-09 16:19:55 -040073 src/hb-ot-shape-complex-hangul.cc \
74 src/hb-ot-shape-complex-hebrew.cc \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050075 src/hb-ot-shape-complex-indic.cc \
Behdad Esfahbod1edc6b92013-02-26 15:01:45 -050076 src/hb-ot-shape-complex-indic-table.cc \
77 src/hb-ot-shape-complex-myanmar.cc \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050078 src/hb-ot-shape-complex-thai.cc \
Behdad Esfahbod9d4ede32014-07-09 16:19:55 -040079 src/hb-ot-shape-complex-tibetan.cc \
Behdad Esfahbodd1044152015-08-18 17:33:34 +010080 src/hb-ot-shape-complex-use.cc \
81 src/hb-ot-shape-complex-use-table.cc \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050082 src/hb-ot-shape-normalize.cc \
Behdad Esfahbod9d4ede32014-07-09 16:19:55 -040083 src/hb-ot-shape-fallback.cc \
84 $(NULL)
M1cha2a2b5b82013-09-30 08:55:52 +000085
86#############################################################
Behdad Esfahbod7e1ab1f2014-07-09 16:13:40 -040087# build the harfbuzz shared library
M1cha2a2b5b82013-09-30 08:55:52 +000088#
M1cha2a2b5b82013-09-30 08:55:52 +000089include $(CLEAR_VARS)
M1cha2a2b5b82013-09-30 08:55:52 +000090LOCAL_ARM_MODE := arm
M1cha2a2b5b82013-09-30 08:55:52 +000091LOCAL_MODULE_TAGS := optional
M1cha2a2b5b82013-09-30 08:55:52 +000092LOCAL_SRC_FILES:= \
93 $(HARFBUZZ_SRC_FILES) \
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050094 src/hb-icu.cc
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050095LOCAL_CPP_EXTENSION := .cc
Behdad Esfahbod94afeb62012-12-21 11:54:50 -050096LOCAL_SHARED_LIBRARIES := \
Behdad Esfahbodab281962014-07-09 18:18:06 -040097 libcutils \
98 libicuuc \
99 libicui18n \
100 libutils \
101 liblog
Behdad Esfahbod94afeb62012-12-21 11:54:50 -0500102LOCAL_C_INCLUDES += \
Behdad Esfahbod3d1a6662015-01-05 14:43:13 -0800103 $(LOCAL_PATH)/src
Behdad Esfahbod7cfd6cc2016-02-24 12:30:57 +0900104LOCAL_CFLAGS += -DHB_NO_MT -DHAVE_OT -DHAVE_ICU -DHAVE_ICU_BUILTIN \
105 -Wno-unused-parameter -Wno-missing-field-initializers
Behdad Esfahbod94afeb62012-12-21 11:54:50 -0500106LOCAL_MODULE:= libharfbuzz_ng
Behdad Esfahbod94afeb62012-12-21 11:54:50 -0500107include $(BUILD_SHARED_LIBRARY)