freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft-devel] [freetype-2.9.1] FT_Init_FreeType is missing with cc on S


From: suzuki toshiya
Subject: Re: [ft-devel] [freetype-2.9.1] FT_Init_FreeType is missing with cc on Solaris x64
Date: Thu, 03 May 2018 22:07:30 +0900
User-agent: Mozilla-Thunderbird 2.0.0.24 (X11/20100329)

Dear Alexei,

>> Does it define __GNUC__? Does it undestand __attribute__(( visibility(
>> "default" ) ))?
> 
> Q1) __GNUC__
> Maybe No.

Oh, Oh. I found my misunderstanding.

ftconfig.h does like this:

#if defined( _WIN32 ) && ( defined( _DLL ) || defined( DLL_EXPORT ) )
#define FT_EXPORT( x )  __declspec( dllexport )  x
#elif defined( __GNUC__ ) && __GNUC__ >= 4
#define FT_EXPORT( x )  __attribute__(( visibility( "default" ) ))  x
#elif defined( __cplusplus )
#define FT_EXPORT( x )  extern "C"  x
#else
#define FT_EXPORT( x )  extern  x
#endif

Thus, attribute visibility is only enabled for GCC >= 4.

Comparing with configure.raw, I guess you assumed that
-fvisibility is GCC-specific feature?

# I should remind, such kind of linker-related technologies
# in GNU toolchains are heavily inspired by Solaris, maybe
# in Drepper's era.


suzuki toshiya wrote:
> Alexei Podtelezhnikov wrote:
>> On Thu, May 3, 2018 at 8:31 AM, suzuki toshiya
>> <address@hidden> wrote:
>>> Dear Kanazawa-san,
>>>
>>> Hmm, it looks good... why Oracle cc hides all symbols...?
>>>
>> because it accepts -fvisibility=hidden, wh ich is a GNUC. Now two questions:
>> Does it define __GNUC__? Does it undestand __attribute__(( visibility(
>> "default" ) ))?
> 
> Q1) __GNUC__
> Maybe No.
> 
> Q2) __attribute__((visibility(xxx))
> Yes, according to the online help.
> https://docs.oracle.com/cd/E18659_01/html/821-1384/gjzke.html
> 
> Regards,
> mpsuzuki
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]