[PATCH app, driver, libs 0/43] Replace deprecated Automake INCLUDES variable

Alan Coopersmith Alan.Coopersmith at Sun.COM
Mon Mar 22 07:52:10 PDT 2010


Gaetan Nadon wrote:
> On Fri, 2010-03-19 at 13:53 -0700, Alan Coopersmith wrote:
>> Gaetan Nadon wrote:
>> > The server sticks -fvisibility compiler flag in the pkg Cflags which
>> > does not help while 99% of pkg-config files on my distro are compiler
>> > flags free.
>>
>> Which is probably a bug in itself - I end up removing @symbol_visibility@
>> from xorg-server.pc.in when building our packages, since we support both
>> gcc & Sun Studio, and they take different flags for that option.
>>
> 
> I tend to agree, providing compiler flags such as this one is pushing
> the "convenience" envelop. This flag should be specified in the driver
> module, but it is significant work. There is no facility to specify a
> portable compiler flag. In this particular case, it could be supplied
> through a server macro and included in each driver makefile.

Yes, the visibility cflags should probably have been added to xorg-macros
(since it's useful for libraries as well as driver modules) and the macro
added to the drivers.

> As a side note, it looks like the server config handles the SUN compilers.
> 
> AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"])
> if test x$SUNCC = xyes; then
>     VISIBILITY_CFLAGS="-xldscope=hidden"
> else
>     have_visibility=no
> fi

Yes, so if I build the X server with Sun compilers and don't patch out that
section, no one can build drivers with gcc (including me, which is why I found
this, since some of the drivers I build cannot be built with Sun compilers and
must use gcc).

-- 
	-Alan Coopersmith-           alan.coopersmith at sun.com
	 Oracle Solaris Platform Engineering: X Window System



More information about the xorg-devel mailing list