[Mesa-dev] [PATCH] gallium makefiles: use -export-symbols-regex for building dri drivers

Emil Velikov emil.l.velikov at gmail.com
Tue Feb 11 07:24:56 PST 2014


On 11/02/14 15:17, Christian König wrote:
> Am 11.02.2014 15:55, schrieb Maarten Lankhorst:
>> Hide most symbols, except radeon_drm_winsys_create.
>> As a side effect, it ought to fix bug 73200 on radeon.
>>
>> Signed-off-by: Maarten Lankhorst <maarten.lankhorst at canonical.com>
> 
> I think Emil Velikov wanted to remove "-export-symbols-regex", but I'm
> fine with any method as long as it works correctly.
> 
Seems like we'll need to keep the symbol restrictions due to llvm :'(

Maarten can you please use version script.

Thanks
-Emil

[1] Ulrich Drepper's paper http://people.redhat.com/drepper/dsohowto.pdf

> So this patch is: Reviewed-by: Christian König <christian.koenig at amd.com>
> 
>> ---
>> diff --git a/src/gallium/Automake.inc b/src/gallium/Automake.inc
>> index 1e4a34f..b70b940 100644
>> --- a/src/gallium/Automake.inc
>> +++ b/src/gallium/Automake.inc
>> @@ -51,12 +51,14 @@ GALLIUM_VIDEO_CFLAGS = \
>>      $(VISIBILITY_CFLAGS)
>>
>>
>> -# TODO: add -export-symbols-regex
>> +DRI_EXPORTS ?= '^(__dri2ConfigOptions|__driDriverExtensions.*)$$'
>> +
>>  GALLIUM_DRI_LINKER_FLAGS = \
>>      -module \
>>      -avoid-version \
>> +    -export-symbols-regex $(DRI_EXPORTS) \
>>      -shared \
>> -    -Wl,-Bsymbolic
>> +    -no-undefined
>>
>>  GALLIUM_VDPAU_LINKER_FLAGS = \
>>      -module \
>> diff --git a/src/gallium/targets/r300/dri/Makefile.am
>> b/src/gallium/targets/r300/dri/Makefile.am
>> index d6d8f2d..a2ae263 100644
>> --- a/src/gallium/targets/r300/dri/Makefile.am
>> +++ b/src/gallium/targets/r300/dri/Makefile.am
>> @@ -20,6 +20,7 @@
>>  # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
>>  # DEALINGS IN THE SOFTWARE.
>>
>> +DRI_EXPORTS =
>> '^(__dri2ConfigOptions|__driDriverExtensions.*|radeon_drm_winsys_create)$$'
>>
>>  include $(top_srcdir)/src/gallium/Automake.inc
>>
>>  AM_CFLAGS = \
>> diff --git a/src/gallium/targets/r600/dri/Makefile.am
>> b/src/gallium/targets/r600/dri/Makefile.am
>> index 42db72f..374b2ce 100644
>> --- a/src/gallium/targets/r600/dri/Makefile.am
>> +++ b/src/gallium/targets/r600/dri/Makefile.am
>> @@ -20,6 +20,7 @@
>>  # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
>>  # DEALINGS IN THE SOFTWARE.
>>
>> +DRI_EXPORTS =
>> '^(__dri2ConfigOptions|__driDriverExtensions.*|radeon_drm_winsys_create)$$'
>>
>>  include $(top_srcdir)/src/gallium/Automake.inc
>>
>>  AM_CFLAGS = \
>> diff --git a/src/gallium/targets/radeonsi/dri/Makefile.am
>> b/src/gallium/targets/radeonsi/dri/Makefile.am
>> index 2c1a58d..79ce23f 100644
>> --- a/src/gallium/targets/radeonsi/dri/Makefile.am
>> +++ b/src/gallium/targets/radeonsi/dri/Makefile.am
>> @@ -20,6 +20,7 @@
>>  # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
>>  # DEALINGS IN THE SOFTWARE.
>>
>> +DRI_EXPORTS =
>> '^(__dri2ConfigOptions|__driDriverExtensions.*|radeon_drm_winsys_create)$$'
>>
>>  include $(top_srcdir)/src/gallium/Automake.inc
>>
>>  AM_CFLAGS = \
>>
> 



More information about the mesa-dev mailing list