<div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div class="Wj3C7c"><br>
><br>
>><br>
>> >><br>
>> >> How are you building mesa? Are you using ./configure or are you using<br>
>> >> "make linux-dri" or something like that? What platform is this on? Is<br>
>> >> libGL being linked to libXdamage?<br>
>> ><br>
>> > That was the problem. libGL was pointing to /usr/lib/libXdamage. My X<br>
>> > stuff<br>
>> > is all under "modular".<br>
>> > But including option --x-includes and --x-libraries when configuring<br>
>> > mesa<br>
>> > still makes libGL.so point<br>
>> > to /usr/lib/. What option should i use for using the X includes and libs<br>
>> > under "modular" which was<br>
>> > populated when building X.<br>
>><br>
>> Are you setting PKG_CONFIG_PATH? Mesa will first try to find the X<br>
>> libraries through pkg-config, which will be true for you since you're<br>
>> building for Xorg. If you aren't putting $youdirectory/lib/pkgconfig<br>
>> at the front of PKG_CONFIG_PATH, pkg-config will only search in the<br>
>> system paths, /lib and /usr/lib. Read docs/autoconf.html in the mesa<br>
>> tree.<br>
><br>
> Yes, PKG_CONFIG_PATH was set. After using --x-include, --x-libs option and<br>
> a make clean, the problem is now fixed.  I guess this can be made simpler<br>
> :-)<br>
<br>
</div></div>You shouldn't need to pass --x-includes at all. Does configure fail if<br>
you don't pass those options? Does it pick up the correct xdamage?<br>
</blockquote><div><br>I tried all possible combinations and here is my conclusion<br><br>1) configure needs PKG_CONFIG_PATH to be set. Otherwise it can't find some of the libraries<br>2) As you say, no other options to configure are needed. But the compilation fails for me when it<br>
   comes to xdemos. Though LibGL.so refers to libXdamage, the linker picks it up from /usr/lib.<br>   If i set LD_LIBRARY_PATH in addition, then it works fine. <br><br>-mohan<br> <br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
--<br>
<font color="#888888">Dan<br>
</font></blockquote></div><br>