[Mesa-dev] [PATCH 3/4] targets/osmesa: limit the amount of exported symbols

Emil Velikov emil.l.velikov at gmail.com
Fri May 9 10:13:51 PDT 2014


ping,

Brian, you seem to be the only person that came near osmesa over the last few
years. Can you take a look at the patch below?

Cheers
Emil

On 02/05/14 22:02, Emil Velikov wrote:
> Explicitly list all the OSMesa* symbols and wildcast the gl*
> ones.
> 
> Cc: Brian Paul <brianp at vmware.com>
> Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
> ---
>  src/gallium/targets/osmesa/Makefile.am |  1 +
>  src/gallium/targets/osmesa/osmesa.sym  | 18 ++++++++++++++++++
>  2 files changed, 19 insertions(+)
>  create mode 100644 src/gallium/targets/osmesa/osmesa.sym
> 
> diff --git a/src/gallium/targets/osmesa/Makefile.am b/src/gallium/targets/osmesa/Makefile.am
> index 067f980..0ec8a26 100644
> --- a/src/gallium/targets/osmesa/Makefile.am
> +++ b/src/gallium/targets/osmesa/Makefile.am
> @@ -45,6 +45,7 @@ lib at OSMESA_LIB@_la_LDFLAGS = \
>  	-module \
>  	-no-undefined \
>  	-version-number @OSMESA_VERSION@ \
> +	-Wl,--version-script=$(top_srcdir)/src/gallium/targets/osmesa/osmesa.sym \
>  	$(GC_SECTIONS) \
>  	$(LD_NO_UNDEFINED)
>  
> diff --git a/src/gallium/targets/osmesa/osmesa.sym b/src/gallium/targets/osmesa/osmesa.sym
> new file mode 100644
> index 0000000..b8230e0
> --- /dev/null
> +++ b/src/gallium/targets/osmesa/osmesa.sym
> @@ -0,0 +1,18 @@
> +{
> +	global:
> +		OSMesaColorClamp;
> +		OSMesaCreateContext;
> +		OSMesaCreateContextExt;
> +		OSMesaDestroyContext;
> +		OSMesaGetColorBuffer;
> +		OSMesaGetCurrentContext;
> +		OSMesaGetDepthBuffer;
> +		OSMesaGetIntegerv;
> +		OSMesaGetProcAddress;
> +		OSMesaMakeCurrent;
> +		OSMesaPixelStore;
> +		OSMesaPostprocess;
> +		gl*;
> +	local:
> +		*;
> +};
> 



More information about the mesa-dev mailing list