mirror of
git://git.sv.nongnu.org/freetype/freetype2.git
synced 2026-01-19 04:52:09 +00:00
[autofit] Really fix handling of RTLD_DEFAULT.
This commit actually implements what commit 43ec023e1a describes.
* src/autofit/ft-hb.c (FT_RTLD_FLAGS): New macro for `dlopen`; it uses
`RTLD_GLOBAL` only if `RTLD_DEFAULT` is available.
This commit is contained in:
committed by
Werner Lemberg
parent
738905b34b
commit
3ccc27dc52
@@ -101,8 +101,11 @@
|
||||
#else /* !_WIN32 */
|
||||
|
||||
# ifdef RTLD_DEFAULT
|
||||
# define FT_RTLD_FLAGS RTLD_LAZY | RTLD_GLOBAL
|
||||
lib = RTLD_DEFAULT;
|
||||
version_atleast = DLSYM( lib, hb_version_atleast );
|
||||
# else
|
||||
# define FT_RTLD_FLAGS RTLD_LAZY
|
||||
# endif
|
||||
|
||||
if ( !version_atleast )
|
||||
@@ -116,7 +119,7 @@
|
||||
* variables, and closing the library will cause them to be
|
||||
* invalidated.
|
||||
*/
|
||||
lib = dlopen( FT_LIBHARFBUZZ, RTLD_LAZY | RTLD_GLOBAL );
|
||||
lib = dlopen( FT_LIBHARFBUZZ, FT_RTLD_FLAGS );
|
||||
if ( !lib )
|
||||
goto Fail;
|
||||
version_atleast = DLSYM( lib, hb_version_atleast );
|
||||
|
||||
Reference in New Issue
Block a user