Use a export-file for Windows builds

Apparently even that doesn't make check-internal-symbols.sh happy with
mingw32.  Going to disable that for DLLs again, but hopefully the
export-file is doing *something*.
This commit is contained in:
Behdad Esfahbod 2012-08-08 17:16:01 -04:00
parent f8751cf8e0
commit 560d68af81
3 changed files with 36 additions and 4 deletions

View File

@ -70,7 +70,7 @@ if test "x$GCC" = "xyes"; then
CXXFLAGS="$CXXFLAGS -Wcast-align" CXXFLAGS="$CXXFLAGS -Wcast-align"
case "$host" in case "$host" in
*-mingw*) *-*-mingw*)
;; ;;
*) *)
# Hide inline methods # Hide inline methods
@ -86,6 +86,18 @@ if test "x$GCC" = "xyes"; then
esac esac
fi 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 ========================================================================== dnl ==========================================================================
have_ot=true have_ot=true

View File

@ -164,16 +164,36 @@ endif
DIST_SUBDIRS += hb-old 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++ # Use a C linker, not C++; Don't link to libstdc++
libharfbuzz_la_LINK = $(LINK) $(libharfbuzz_la_LDFLAGS) libharfbuzz_la_LINK = $(LINK) $(libharfbuzz_la_LDFLAGS)
libharfbuzz_la_SOURCES = $(HBSOURCES) $(HBHEADERS) libharfbuzz_la_SOURCES = $(HBSOURCES) $(HBHEADERS)
nodist_libharfbuzz_la_SOURCES = $(nodist_HBSOURCES) nodist_libharfbuzz_la_SOURCES = $(nodist_HBSOURCES)
libharfbuzz_la_CPPFLAGS = $(HBCFLAGS) 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_LIBADD = $(HBLIBS)
libharfbuzz_la_DEPENDENCIES = $(harfbuzz_def_dependency)
pkginclude_HEADERS = $(HBHEADERS) pkginclude_HEADERS = $(HBHEADERS)
nodist_pkginclude_HEADERS = hb-version.h 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 = \ GENERATORS = \
gen-arabic-table.py \ gen-arabic-table.py \

View File

@ -201,8 +201,8 @@ hb_buffer_normalize_glyphs (hb_buffer_t *buffer);
/* /*
* NOT IMPLEMENTED * NOT IMPLEMENTED
void void
hb_buffer_normalize_characters (hb_buffer_t *buffer); hb_buffer_normalize_characters (hb_buffer_t *buffer);
*/ */