Require fontconfig >= 2.8 and change its guard macro name
FcConfigAppFontAddFile() that we use is only available since 2.8, so check for at least this version of the library in configure. Also change the macro guarding its use to the more semantically appropriate "wxHAVE" rather than "wxUSE" and make it more precise by adding "2_8_0" suffix to it.
This commit is contained in:
parent
ed655bfcde
commit
3158a46ce7
2
configure
vendored
2
configure
vendored
@ -22550,7 +22550,7 @@ else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
|
||||
$as_echo "yes" >&6; }
|
||||
|
||||
$as_echo "#define wxUSE_FONTCONFIG 1" >>confdefs.h
|
||||
$as_echo "#define wxHAVE_FONTCONFIG_2_8_0 1" >>confdefs.h
|
||||
|
||||
CXXFLAGS="$FONTCONFIG_CFLAGS $CXXFLAGS"
|
||||
GUI_TK_LIBRARY="$GUI_TK_LIBRARY $FONTCONFIG_LIBS"
|
||||
|
@ -2963,13 +2963,13 @@ libraries returned by 'pkg-config gtk+-2.0 --libs' or 'gtk-config
|
||||
dnl fi
|
||||
fi
|
||||
|
||||
PKG_CHECK_MODULES(FONTCONFIG, [fontconfig],
|
||||
PKG_CHECK_MODULES(FONTCONFIG, [fontconfig >= 2.8.0],
|
||||
[
|
||||
AC_DEFINE(wxUSE_FONTCONFIG)
|
||||
AC_DEFINE(wxHAVE_FONTCONFIG_2_8_0)
|
||||
CXXFLAGS="$FONTCONFIG_CFLAGS $CXXFLAGS"
|
||||
GUI_TK_LIBRARY="$GUI_TK_LIBRARY $FONTCONFIG_LIBS"
|
||||
],
|
||||
[AC_MSG_WARN([fontconfig library not found, run-time font loading won't be supported by wxFont])])
|
||||
[AC_MSG_WARN([fontconfig library not found or too old, run-time font loading won't be supported by wxFont])])
|
||||
fi
|
||||
|
||||
if test "$wxUSE_DFB" = 1; then
|
||||
|
@ -118,7 +118,7 @@ private:
|
||||
wxDECLARE_DYNAMIC_CLASS(wxFont);
|
||||
};
|
||||
|
||||
#if wxUSE_FONTCONFIG
|
||||
#ifdef wxHAVE_FONTCONFIG_2_8_0
|
||||
#define wxHAS_PRIVATE_FONTS 1
|
||||
#endif
|
||||
|
||||
|
@ -836,7 +836,7 @@
|
||||
/*
|
||||
* Use FontConfig library for private fonts support in wxFont.
|
||||
*/
|
||||
#define wxUSE_FONTCONFIG 0
|
||||
#undef wxHAVE_FONTCONFIG_2_8_0
|
||||
/*
|
||||
* Use GTK print for printing under GTK+ 2.10+
|
||||
*/
|
||||
|
@ -906,9 +906,9 @@ typedef pid_t GPid;
|
||||
* Use FontConfig library for private fonts support in wxFont.
|
||||
*/
|
||||
#ifdef VMS_GTK2
|
||||
#define wxUSE_FONTCONFIG 1
|
||||
#define wxHAVE_FONTCONFIG_2_8_0 1
|
||||
#else
|
||||
#define wxUSE_FONTCONFIG 0
|
||||
#undef wxHAVE_FONTCONFIG_2_8_0
|
||||
#endif
|
||||
/*
|
||||
* Use GTK print for printing under GTK+ 2.10+
|
||||
|
Loading…
Reference in New Issue
Block a user