[Mesa-dev] [PATCH-RFC] autoconf: add --enable-{dri,glx,osmesa}

Jon TURNEY jon.turney at dronecode.org.uk
Fri Jul 1 12:10:29 PDT 2011


On 30/06/2011 02:48, Chia-I Wu wrote:
> On Sun, Jun 26, 2011 at 10:39 PM, Chia-I Wu <olvaffe at gmail.com> wrote:
>> From: Chia-I Wu <olv at lunarg.com>
>>
>> The idea is that DRI driver, libGL and libOSMesa are libraries that can
>> be independently enabled, yet --with-driver does not allow us to easily
>> do that, if not impossible.  This also matches what
>> --enable-{egl,xorg,d3d1x} do for the respective libraries.
>>
>> There are two libGL providers: Xlib-based and DRI-based.  They cannot
>> coexist.  To be able to choose between them, --enable-xlib-glx is also
>> added.
>>
>> With this commit, --with-driver=dri can be replaced by
>>
>>  $ ./configure --enable-dri --enable-glx --disable-osmesa
>>
>> --with-driver=xlib can be replaced by
>>
>>  $ ./configure --disable-dri --enable-glx --enable-osmesa \
>>                --enable-xlib-glx
>>
>> and --with-driver=osmesa can be replaced by
>>
>>  $ ./configure --disable-dri --disable-glx --enable-osmesa
>>
>> Some combinations that cannot be supported with --with-driver will
>> produce errors at the moment.  But in the future, we would like to
>> support, for example,
>>
>>  $ ./configure --enable-dri --disable-glx --enable-egl
>>  (build libEGL and DRI drivers, but not libGL)
>>
>> Note that this commit still keeps --with-driver for transitional
>> purpose.
> If there is no objection, I'd like to make the change later this week.

This seems like a useful rationalization of the configuration arguments, but
one of your follow up patches to this ("autoconf: fix --disable-glx") has
changed the condition for checking for libdrm from mesadriver=dri &&
driglx_direct=yes to just enable_dri=yes.

This change causes ./configure --with-driver=dri --disable-driglx-direct to
fail when libdrm isn't present, see [1].

(I'll just note that I'd also like to be able to ./configure --with-driver=dri
--with-dri-drivers=swrast without requiring libdrm, as there is no functional
dependency, but it's not possible to build that at the moment without some
patching to untangle a build dependency)

[1]
http://tinderbox.freedesktop.org/builds/2011-07-01-0004/logs/libGL-indirect-only/#configure


More information about the mesa-dev mailing list