Makefile.am 6.4 KB
Newer Older
B
Behdad Esfahbod 已提交
1
# Process this file with automake to produce Makefile.in
2

3
NULL =
4 5
SUBDIRS =
DIST_SUBDIRS =
6
BUILT_SOURCES =
B
Behdad Esfahbod 已提交
7
EXTRA_DIST =
8 9 10
CLEANFILES =
DISTCLEANFILES =
MAINTAINERCLEANFILES =
11
DISTCHECK_CONFIGURE_FLAGS = --enable-introspection
12

B
Behdad Esfahbod 已提交
13
# The following warning options are useful for debugging: -Wpadded
14
#AM_CXXFLAGS =
15

B
Behdad Esfahbod 已提交
16
lib_LTLIBRARIES = libharfbuzz.la
17

B
Behdad Esfahbod 已提交
18 19
HBCFLAGS =
HBLIBS =
20
HBSOURCES =  \
21
	hb-atomic-private.hh \
22
	hb-blob.cc \
23
	hb-buffer-private.hh \
B
Behdad Esfahbod 已提交
24
	hb-buffer.cc \
25
	hb-cache-private.hh \
26
	hb-common.cc \
27
	hb-fallback-shape.cc \
28
	hb-font-private.hh \
B
Behdad Esfahbod 已提交
29 30
	hb-font.cc \
	hb-mutex-private.hh \
31
	hb-object-private.hh \
B
Behdad Esfahbod 已提交
32 33
	hb-open-file-private.hh \
	hb-open-type-private.hh \
34
	hb-ot-head-table.hh \
B
Behdad Esfahbod 已提交
35 36
	hb-ot-hhea-table.hh \
	hb-ot-hmtx-table.hh \
37 38
	hb-ot-maxp-table.hh \
	hb-ot-name-table.hh \
39
	hb-ot-tag.cc \
40
	hb-private.hh \
B
Behdad Esfahbod 已提交
41 42
	hb-set-private.hh \
	hb-set.cc \
43
	hb-shape.cc \
44 45 46 47 48 49
	hb-shape-plan-private.hh \
	hb-shape-plan.cc \
	hb-shape-plan.h \
	hb-shaper-list.hh \
	hb-shaper-impl-private.hh \
	hb-shaper-private.hh \
B
Minor  
Behdad Esfahbod 已提交
50
	hb-shaper.cc \
B
Behdad Esfahbod 已提交
51
	hb-tt-font.cc \
52
	hb-unicode-private.hh \
B
Behdad Esfahbod 已提交
53
	hb-unicode.cc \
54
	hb-warning.cc \
B
Behdad Esfahbod 已提交
55 56 57 58 59 60 61
	$(NULL)
HBHEADERS = \
	hb.h \
	hb-blob.h \
	hb-buffer.h \
	hb-common.h \
	hb-font.h \
B
Behdad Esfahbod 已提交
62
	hb-set.h \
B
Behdad Esfahbod 已提交
63 64
	hb-shape.h \
	hb-unicode.h \
65
	hb-version.h \
B
Behdad Esfahbod 已提交
66 67
	$(NULL)

68
if HAVE_OT
B
Behdad Esfahbod 已提交
69
HBSOURCES += \
70
	hb-ot-layout.cc \
71
	hb-ot-layout-common-private.hh \
72 73
	hb-ot-layout-gdef-table.hh \
	hb-ot-layout-gpos-table.hh \
74
	hb-ot-layout-gsubgpos-private.hh \
75
	hb-ot-layout-gsub-table.hh \
76
	hb-ot-layout-private.hh \
B
Behdad Esfahbod 已提交
77
	hb-ot-map.cc \
B
Behdad Esfahbod 已提交
78
	hb-ot-map-private.hh \
79
	hb-ot-shape.cc \
80
	hb-ot-shape-complex-arabic.cc \
81
	hb-ot-shape-complex-arabic-table.hh \
B
Behdad Esfahbod 已提交
82
	hb-ot-shape-complex-indic.cc \
83
	hb-ot-shape-complex-indic-machine.hh \
B
Behdad Esfahbod 已提交
84
	hb-ot-shape-complex-indic-private.hh \
B
Behdad Esfahbod 已提交
85
	hb-ot-shape-complex-indic-table.hh \
B
Minor  
Behdad Esfahbod 已提交
86
	hb-ot-shape-complex-misc.cc \
87
	hb-ot-shape-complex-private.hh \
B
Behdad Esfahbod 已提交
88
	hb-ot-shape-normalize-private.hh \
B
Behdad Esfahbod 已提交
89
	hb-ot-shape-normalize.cc \
B
Behdad Esfahbod 已提交
90 91
	hb-ot-shape-fallback-private.hh \
	hb-ot-shape-fallback.cc \
B
Behdad Esfahbod 已提交
92
	hb-ot-shape-private.hh \
93
	$(NULL)
B
Behdad Esfahbod 已提交
94
HBHEADERS += \
B
Behdad Esfahbod 已提交
95
	hb-ot.h \
96
	hb-ot-layout.h \
97
	hb-ot-tag.h \
98
	$(NULL)
99
endif
100

101
if HAVE_GLIB
B
Behdad Esfahbod 已提交
102
HBCFLAGS += $(GLIB_CFLAGS)
B
Behdad Esfahbod 已提交
103
HBLIBS   += $(GLIB_LIBS)
104 105 106 107 108 109 110
HBSOURCES += hb-glib.cc
HBHEADERS += hb-glib.h
endif

if HAVE_GOBJECT
HBCFLAGS += $(GOBJECT_CFLAGS)
HBLIBS   += $(GOBJECT_LIBS)
B
Behdad Esfahbod 已提交
111 112
HBSOURCES += hb-gobject-structs.cc
nodist_HBSOURCES = hb-gobject-enums.cc
113
HBHEADERS += hb-gobject.h
114 115
BUILT_SOURCES += hb-gobject-enums.cc
EXTRA_DIST += hb-gobject-enums.cc.tmpl
B
Behdad Esfahbod 已提交
116
DISTCLEANFILES += hb-gobject-enums.cc
117 118

hb-gobject-enums.cc: hb-gobject-enums.cc.tmpl $(HBHEADERS)
B
Behdad Esfahbod 已提交
119 120
	$(AM_V_GEN) $(GLIB_MKENUMS) --template $^ > "$@.tmp" && \
	mv "$@.tmp" "$@" || ( $(RM) "@.tmp" && false )
121 122
endif

B
Behdad Esfahbod 已提交
123 124
if HAVE_ICU
HBCFLAGS += $(ICU_CFLAGS)
B
Behdad Esfahbod 已提交
125
HBLIBS   += $(ICU_LIBS)
126 127
HBSOURCES += hb-icu.cc
HBHEADERS += hb-icu.h
B
Behdad Esfahbod 已提交
128 129
endif

B
Behdad Esfahbod 已提交
130 131 132
if HAVE_FREETYPE
HBCFLAGS += $(FREETYPE_CFLAGS)
HBLIBS   += $(FREETYPE_LIBS)
133 134
HBSOURCES += hb-ft.cc
HBHEADERS += hb-ft.h
B
Behdad Esfahbod 已提交
135
endif
B
Behdad Esfahbod 已提交
136

137 138 139
if HAVE_GRAPHITE2
HBCFLAGS += $(GRAPHITE2_CFLAGS)
HBLIBS   += $(GRAPHITE2_LIBS)
140
HBSOURCES += hb-graphite2.cc
141 142 143
HBHEADERS += hb-graphite2.h
endif

144 145 146
if HAVE_UNISCRIBE
HBCFLAGS += $(UNISCRIBE_CFLAGS)
HBLIBS   += $(UNISCRIBE_LIBS)
147
HBSOURCES += hb-uniscribe.cc
148
HBHEADERS += hb-uniscribe.h
149 150
endif

151 152 153
if HAVE_CORETEXT
HBCFLAGS += $(CORETEXT_CFLAGS)
HBLIBS   += $(CORETEXT_LIBS)
154
HBSOURCES += hb-coretext.cc
155 156 157
HBHEADERS += hb-coretext.h
endif

158 159 160 161
if HAVE_HB_OLD
SUBDIRS += hb-old
HBCFLAGS += -I$(srcdir)/hb-old
HBLIBS   += hb-old/libhb-old.la
162
HBSOURCES += hb-old.cc
163 164 165
endif
DIST_SUBDIRS += hb-old

166

B
Behdad Esfahbod 已提交
167 168
# Use a C linker, not C++; Don't link to libstdc++
libharfbuzz_la_LINK = $(LINK) $(libharfbuzz_la_LDFLAGS)
B
Behdad Esfahbod 已提交
169
libharfbuzz_la_SOURCES = $(HBSOURCES) $(HBHEADERS)
B
Behdad Esfahbod 已提交
170
nodist_libharfbuzz_la_SOURCES = $(nodist_HBSOURCES)
B
Behdad Esfahbod 已提交
171
libharfbuzz_la_CPPFLAGS = $(HBCFLAGS)
172
libharfbuzz_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(HB_LIBTOOL_VERSION_INFO) -no-undefined
B
Behdad Esfahbod 已提交
173
libharfbuzz_la_LIBADD = $(HBLIBS)
B
Behdad Esfahbod 已提交
174
pkginclude_HEADERS = $(HBHEADERS)
175
nodist_pkginclude_HEADERS = hb-version.h
176

177 178

GENERATORS = \
B
Behdad Esfahbod 已提交
179
	gen-arabic-table.py \
B
Behdad Esfahbod 已提交
180
	gen-indic-table.py \
181 182 183 184
	$(NULL)

EXTRA_DIST += $(GENERATORS)

185 186 187 188
unicode-tables: arabic-table indic-table

indic-table: gen-indic-table.py IndicSyllabicCategory.txt IndicMatraCategory.txt Blocks.txt
	$(AM_V_GEN) $(builddir)/$^ > hb-ot-shape-complex-indic-table.hh.tmp && \
189
	mv hb-ot-shape-complex-indic-table.hh.tmp $(srcdir)/hb-ot-shape-complex-indic-table.hh || \
190 191
	($(RM) hb-ot-shape-complex-indic-table.hh.tmp; false)

192
arabic-table: gen-arabic-table.py ArabicShaping.txt UnicodeData.txt
193
	$(AM_V_GEN) $(builddir)/$^ > hb-ot-shape-complex-arabic-table.hh.tmp && \
194
	mv hb-ot-shape-complex-arabic-table.hh.tmp $(srcdir)/hb-ot-shape-complex-arabic-table.hh || \
195 196 197 198 199
	($(RM) hb-ot-shape-complex-arabic-table.hh.tmp; false)


.PHONY: unicode-tables arabic-table indic-table

200
BUILT_SOURCES += hb-ot-shape-complex-indic-machine.hh
201
EXTRA_DIST += hb-ot-shape-complex-indic-machine.rl
202
hb-ot-shape-complex-indic-machine.hh: hb-ot-shape-complex-indic-machine.rl
203
	$(AM_V_GEN)$(top_srcdir)/missing --run ragel -e -F1 -o "$@.tmp" "$<" && \
204
	mv "$@.tmp" "$@" || ( $(RM) "$@.tmp" && false )
205

206
noinst_PROGRAMS = main indic test-would-substitute
B
Behdad Esfahbod 已提交
207 208
bin_PROGRAMS =

209
main_SOURCES = main.cc
B
Behdad Esfahbod 已提交
210 211
main_CPPFLAGS = $(HBCFLAGS)
main_LDADD = libharfbuzz.la $(HBLIBS)
B
Behdad Esfahbod 已提交
212

B
Behdad Esfahbod 已提交
213 214 215 216
indic_SOURCES = indic.cc
indic_CPPFLAGS = $(HBCFLAGS)
indic_LDADD = libharfbuzz.la $(HBLIBS)

217 218 219 220
test_would_substitute_SOURCES = test-would-substitute.cc
test_would_substitute_CPPFLAGS = $(HBCFLAGS) $(FREETYPE_CFLAGS)
test_would_substitute_LDADD = libharfbuzz.la $(HBLIBS) $(FREETYPE_LIBS)

B
Behdad Esfahbod 已提交
221
dist_check_SCRIPTS = \
B
Behdad Esfahbod 已提交
222
	check-c-linkage-decls.sh \
223
	check-header-guards.sh \
B
Behdad Esfahbod 已提交
224
	check-includes.sh \
225 226
	check-internal-symbols.sh \
	check-static-inits.sh \
227
	$(NULL)
228 229 230

if HAVE_ICU
else
B
Behdad Esfahbod 已提交
231
dist_check_SCRIPTS += check-libstdc++.sh
232
endif
233

234
TESTS = $(dist_check_SCRIPTS)
B
Behdad Esfahbod 已提交
235 236 237 238 239 240
TESTS_ENVIRONMENT = \
	srcdir="$(srcdir)" \
	MAKE="$(MAKE) $(AM_MAKEFLAGS)" \
	HBSOURCES="$(HBSOURCES)" \
	HBHEADERS="$(HBHEADERS)" \
	$(NULL)
B
Behdad Esfahbod 已提交
241

B
Behdad Esfahbod 已提交
242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262
#-include $(INTROSPECTION_MAKEFILE)
#INTROSPECTION_GIRS = hb-1.0.gir
#INTROSPECTION_SCANNER_ARGS = -I$(srcdir) -n hb --identifier-prefix=hb_
#INTROSPECTION_COMPILER_ARGS = --includedir=$(srcdir)
#
#if HAVE_INTROSPECTION
#
#hb-1.0.gir: libharfbuzz.la
#hb_1_0_gir_INCLUDES = GObject-2.0
#hb_1_0_gir_CFLAGS = $(INCLUDES) $(HBCFLAGS) -DHB_H -DHB_H_IN -DHB_OT_H -DHB_OT_H_IN
#hb_1_0_gir_LIBS = libharfbuzz.la
#hb_1_0_gir_FILES = $(HBHEADERS)
#
#girdir = $(datadir)/gir-1.0
#gir_DATA = $(INTROSPECTION_GIRS)
#
#typelibdir = $(libdir)/girepository-1.0
#typelib_DATA = $(INTROSPECTION_GIRS:.gir=.typelib)
#
#CLEANFILES += $(gir_DATA) $(typelib_DATA)
#endif
263

B
Behdad Esfahbod 已提交
264
-include $(top_srcdir)/git.mk