Bug 34455

Summary: sed in mesa Makefile: expanded PC_LIB_PRIV might contain comma
Product: Mesa Reporter: Дилян Палаузов <dilyan.palauzov>
Component: OtherAssignee: mesa-dev
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium    
Version: 7.10   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Дилян Палаузов 2011-02-18 10:23:40 UTC
In Mesa-7.10.0, src/mesa/Makefile contains

osmesa_pcedit = sed \
        $(pcedit) \
        -e 's,@OSMESA_LIB@,$(OSMESA_LIB),' \
        -e 's,@OSMESA_PC_REQ@,$(OSMESA_PC_REQ),' \
        -e 's,@OSMESA_PC_LIB_PRIV@,$(OSMESA_PC_LIB_PRIV),'

In my case:

OSMESA_PC_LIB_PRIV is expanded to -lm -lpthread  -ldl -Wl,-rpath,/usr/lib64 -L/usr/lib64 -ltalloc

which leads to the sed expression:

sed ... -e 's,@OSMESA_PC_LIB_PRIV@,-lm -lpthread  -ldl -Wl,-rpath,/usr/lib64 -L/usr/lib64 -ltalloc  ,' osmesa.pc.in > osmesa.pc

This sed expression has unforeseen commas and is therefore invalid.

I suggest replacing the comma in the Makefile with some other symbol, e.g. %

The same applies for the generation of src/mesa/gl.pc,  which produces -e 's,@GL_PC_LIB_PRIV@,-lm -lpthread -Wl,-rpath,/usr/lib64 -L/usr/lib64 -ltalloc  ,'.

The same applies for the generation of ./src/egl/main/egl.pc .
Comment 1 Matt Turner 2012-09-27 23:19:49 UTC
This is long since fixed.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.