[subset] Build hb-subset into separate libharfbuzz-subset.so

This commit is contained in:
Behdad Esfahbod 2018-02-04 20:18:52 -05:00
parent eac20e4595
commit ae39fc8171
3 changed files with 27 additions and 6 deletions

View File

@ -27,9 +27,7 @@ HBNONPCLIBS =
HBDEPS =
HBSOURCES = $(HB_BASE_sources)
HBSOURCES += $(HB_BASE_RAGEL_GENERATED_sources)
HBSOURCES += $(HB_SUBSET_sources)
HBHEADERS = $(HB_BASE_headers)
HBHEADERS += $(HB_SUBSET_headers)
HBNODISTHEADERS = $(HB_NODIST_headers)
if HAVE_OT
@ -137,6 +135,15 @@ pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = harfbuzz.pc
EXTRA_DIST += harfbuzz.pc.in
lib_LTLIBRARIES += libharfbuzz-subset.la
libharfbuzz_subset_la_SOURCES = $(HB_SUBSET_sources)
libharfbuzz_subset_la_CPPFLAGS = $(libharfbuzz_la_CPPFLAGS)
libharfbuzz_subset_la_LDFLAGS = $(libharfbuzz_la_LDFLAGS)
libharfbuzz_subset_la_LIBADD = libharfbuzz.la
pkginclude_HEADERS += $(HB_SUBSET_headers)
pkgconfig_DATA += harfbuzz-subset.pc
EXTRA_DIST += harfbuzz-subset.pc.in
FUZZING_CPPFLAGS = \
-DHB_NDEBUG \
-DHB_MAX_NESTING_LEVEL=3 \
@ -166,8 +173,8 @@ HBHEADERS += $(HB_ICU_headers)
else
lib_LTLIBRARIES += libharfbuzz-icu.la
libharfbuzz_icu_la_SOURCES = $(HB_ICU_sources)
libharfbuzz_icu_la_CPPFLAGS = $(ICU_CFLAGS)
libharfbuzz_icu_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(HB_LIBTOOL_VERSION_INFO) -no-undefined
libharfbuzz_icu_la_CPPFLAGS = $(libharfbuzz_la_CPPFLAGS) $(ICU_CFLAGS)
libharfbuzz_icu_la_LDFLAGS = $(libharfbuzz_la_LDFLAGS)
libharfbuzz_icu_la_LIBADD = $(ICU_LIBS) libharfbuzz.la
pkginclude_HEADERS += $(HB_ICU_headers)
pkgconfig_DATA += harfbuzz-icu.pc
@ -179,8 +186,8 @@ if HAVE_GOBJECT
lib_LTLIBRARIES += libharfbuzz-gobject.la
libharfbuzz_gobject_la_SOURCES = $(HB_GOBJECT_sources)
nodist_libharfbuzz_gobject_la_SOURCES = $(HB_GOBJECT_ENUM_sources)
libharfbuzz_gobject_la_CPPFLAGS = $(GOBJECT_CFLAGS)
libharfbuzz_gobject_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(HB_LIBTOOL_VERSION_INFO) -no-undefined
libharfbuzz_gobject_la_CPPFLAGS = $(libharfbuzz_la_CPPFLAGS) $(GOBJECT_CFLAGS)
libharfbuzz_gobject_la_LDFLAGS = $(libharfbuzz_la_LDFLAGS)
libharfbuzz_gobject_la_LIBADD = $(GOBJECT_LIBS) libharfbuzz.la
pkginclude_HEADERS += $(HB_GOBJECT_headers)
nodist_pkginclude_HEADERS += $(HB_GOBJECT_ENUM_headers)

12
src/harfbuzz-subset.pc.in Normal file
View File

@ -0,0 +1,12 @@
prefix=%prefix%
exec_prefix=%exec_prefix%
libdir=%libdir%
includedir=%includedir%
Name: harfbuzz
Description: HarfBuzz font subsetter
Version: %VERSION%
Requires: harfbuzz
Libs: -L${libdir} -lharfbuzz-subset
Cflags: -I${includedir}/harfbuzz

View File

@ -47,6 +47,8 @@ hb_shape_SOURCES = $(HB_SHAPE_sources)
bin_PROGRAMS += hb-shape
hb_subset_SOURCES = $(HB_SUBSET_sources)
hb_subset_SOURCES = $(HB_SUBSET_sources)
hb_subset_LDADD = $(LDADD) $(top_builddir)/src/libharfbuzz-subset.la
bin_PROGRAMS += hb-subset
if HAVE_OT