<p>On Jun 1, 2012 12:13 PM, "Brad King" <<a href="mailto:brad.king@kitware.com">brad.king@kitware.com</a>> wrote:<br>
><br>
> Teach 'configure' to read the default GL_LIB, GLU_LIB, and OSMESA_LIB<br>
> values from the environment. This allows one to mangle the library<br>
> names (without also mangling the symbol names) to make them distinct<br>
> from other GL libraries on the system.<br>
> ---<br>
><br>
> On 06/01/2012 10:06 AM, Brian Paul wrote:<br>
> > You should transition to using autoconf<br>
><br>
> One feature I used in the pure-make build system was to create a custom<br>
> configs/current to set GL_LIB, GLU_LIB, and OSMESA_LIB to have a "Mesa"<br>
> prefix. This helps ensure that VTK both builds and runs against my<br>
> nightly Mesa build regardless of what other "GL" libraries appear in<br>
> the dynamic loader's search path. With this patch I can run<br>
><br>
> $ GL_LIB=MesaGL GLU_LIB=MesaGLU OSMESA_LIB=MesaOSMesa ./autogen.sh ...<br>
><br>
> to build with custom library names. Please review.<br>
><br>
> Thanks,<br>
> -Brad<br>
><br>
> <a href="http://configure.ac">configure.ac</a> | 17 ++++++++++-------<br>
> 1 file changed, 10 insertions(+), 7 deletions(-)<br>
><br>
> diff --git a/<a href="http://configure.ac">configure.ac</a> b/<a href="http://configure.ac">configure.ac</a><br>
> index 9fb8149..7f6ba96 100644<br>
> --- a/<a href="http://configure.ac">configure.ac</a><br>
> +++ b/<a href="http://configure.ac">configure.ac</a><br>
> @@ -355,6 +355,12 @@ else<br>
> LIB_EXTENSION='so' ;;<br>
> esac<br>
> fi<br>
> +AC_ARG_VAR([GL_LIB],[name of GL library @<:@default=GL@:>@])<br>
> +AC_ARG_VAR([GLU_LIB],[name of GLU library @<:@default=GLU@:>@])<br>
> +AC_ARG_VAR([OSMESA_LIB],[name of OSMesa library @<:@default=OSMesa@:>@])<br>
> +GL_LIB="${GL_LIB-GL}"<br>
> +GLU_LIB="${GLU_LIB-GLU}"<br>
> +OSMESA_LIB="${OSMESA_LIB-OSMesa}"</p>
<p>I don't think this part is necessary. AC_ARG_VAR does this already. The rest makes sense though.</p>
<p>Dan</p>