diff --git a/configure.ac b/configure.ac index 689b6a4c13940b580782bdd66d3339cb804c940c..3ca23ee484c7886972c601c0c3db0d8b8bcc540c 100644 --- a/configure.ac +++ b/configure.ac @@ -70,7 +70,7 @@ if test "x$GCC" = "xyes"; then CXXFLAGS="$CXXFLAGS -Wcast-align" case "$host" in - *-mingw*) + *-*-mingw*) ;; *) # Hide inline methods @@ -86,6 +86,18 @@ if test "x$GCC" = "xyes"; then esac fi +AC_MSG_CHECKING([for native Win32]) +case "$host" in + *-*-mingw*) + hb_os_win32=yes + ;; + *) + hb_os_win32=no + ;; +esac +AC_MSG_RESULT([$hb_os_win32]) +AM_CONDITIONAL(OS_WIN32, test "$hb_os_win32" = "yes") + dnl ========================================================================== have_ot=true diff --git a/src/Makefile.am b/src/Makefile.am index 93879c4db66111b125c1e605a76cc6ecdeeb84ef..d8f7502b8949dde7ecc572ac49344d8b8bc4cd80 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -164,16 +164,36 @@ endif DIST_SUBDIRS += hb-old + +# Put the library together + +if OS_WIN32 +export_symbols = -export-symbols harfbuzz.def +harfbuzz_def_dependency = harfbuzz.def +endif + # Use a C linker, not C++; Don't link to libstdc++ libharfbuzz_la_LINK = $(LINK) $(libharfbuzz_la_LDFLAGS) libharfbuzz_la_SOURCES = $(HBSOURCES) $(HBHEADERS) nodist_libharfbuzz_la_SOURCES = $(nodist_HBSOURCES) libharfbuzz_la_CPPFLAGS = $(HBCFLAGS) -libharfbuzz_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(HB_LIBTOOL_VERSION_INFO) -no-undefined +libharfbuzz_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(HB_LIBTOOL_VERSION_INFO) $(export_symbols) -no-undefined libharfbuzz_la_LIBADD = $(HBLIBS) +libharfbuzz_la_DEPENDENCIES = $(harfbuzz_def_dependency) pkginclude_HEADERS = $(HBHEADERS) nodist_pkginclude_HEADERS = hb-version.h +CLEANFILES += harfbuzz.def +harfbuzz.def: $(HBHEADERS) + $(AM_V_GEN) (echo EXPORTS; \ + (cat $^ || echo 'hb_ERROR ()' ) | \ + $(EGREP) '^hb_.* \(' | \ + sed -e 's/ (.*//' | \ + LANG=C sort; \ + echo LIBRARY libharfbuzz-$(HB_VERSION_MAJOR).dll; \ + ) >"$@.tmp" + @ ! grep -q hb_ERROR "$@.tmp" && mv "$@.tmp" "$@" || ($(RM) "$@"; false) + GENERATORS = \ gen-arabic-table.py \ diff --git a/src/hb-buffer.h b/src/hb-buffer.h index d67cfd630a994e7a2f969bdbe82e4e15162bb503..aebf4821a09888371157ef342497edad791fc4e1 100644 --- a/src/hb-buffer.h +++ b/src/hb-buffer.h @@ -201,8 +201,8 @@ hb_buffer_normalize_glyphs (hb_buffer_t *buffer); /* * NOT IMPLEMENTED -void -hb_buffer_normalize_characters (hb_buffer_t *buffer); + void + hb_buffer_normalize_characters (hb_buffer_t *buffer); */