source: x/installing/mesa.xml@ 5d51e9d8

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 9.1 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since 5d51e9d8 was 5d51e9d8, checked in by Bruce Dubbs <bdubbs@…>, 4 years ago

Update to mesa-19.3.3.
Update to lxml-4.4.3 (Python Module).

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@22613 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 17.2 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY mesa-download-http "https://mesa.freedesktop.org/archive/mesa-&mesa-version;.tar.xz">
8 <!ENTITY mesa-download-ftp "ftp://ftp.freedesktop.org/pub/mesa/mesa-&mesa-version;.tar.xz">
9 <!ENTITY mesa-md5sum "00010e0bb8f6641276ff6cb3e9386114">
10 <!ENTITY mesa-size "11 MB">
11 <!ENTITY mesa-buildsize "397 MB (with demos and docs), add 204 MB for tests">
12 <!ENTITY mesa-time "2.6 SBU (with parallelism=4, demos, and docs), add 0.4 SBU for tests">
13]>
14
15<sect1 id="mesa" xreflabel="Mesa-&mesa-version;">
16 <?dbhtml filename="mesa.html"?>
17
18 <sect1info>
19 <othername>$LastChangedBy$</othername>
20 <date>$Date$</date>
21 </sect1info>
22
23 <title>Mesa-&mesa-version;</title>
24
25 <indexterm zone="mesa">
26 <primary sortas="a-Mesa">Mesa</primary>
27 </indexterm>
28
29 <sect2 role="package">
30 <title>Introduction to Mesa</title>
31
32 <para>
33 <application>Mesa</application> is an OpenGL compatible 3D graphics
34 library.
35 </para>
36
37 <note>
38 <para>
39 <application>Mesa</application> is updated relatively often. You may
40 want to use the latest available &mesa-major-minor;.x mesa version.
41 </para>
42 </note>
43
44 &lfs90_checked;
45
46 <bridgehead renderas="sect3">Package Information</bridgehead>
47 <itemizedlist spacing="compact">
48 <listitem>
49 <para>
50 Download (HTTP): <ulink url="&mesa-download-http;"/>
51 </para>
52 </listitem>
53 <listitem>
54 <para>
55 Download (FTP): <ulink url="&mesa-download-ftp;"/>
56 </para>
57 </listitem>
58 <listitem>
59 <para>
60 Download MD5 sum: &mesa-md5sum;
61 </para>
62 </listitem>
63 <listitem>
64 <para>
65 Download size: &mesa-size;
66 </para>
67 </listitem>
68 <listitem>
69 <para>
70 Estimated disk space required: &mesa-buildsize;
71 </para>
72 </listitem>
73 <listitem>
74 <para>
75 Estimated build time: &mesa-time;
76 </para>
77 </listitem>
78 </itemizedlist>
79
80 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
81 <itemizedlist spacing="compact">
82 <listitem>
83 <para>
84 Required patch:
85 <ulink
86 url="&patch-root;/mesa-&mesa-version;-fix_svga_vmwgfx_segfaults-1.patch"/>
87 </para>
88 </listitem>
89 <listitem>
90 <para>
91 Recommended patch:
92 <ulink
93 url="&patch-root;/mesa-&mesa-version;-add_xdemos-1.patch"/>
94 (installs 2 demo programs for testing Mesa - not needed if you
95 install the <ulink url="ftp://ftp.freedesktop.org/pub/mesa/demos/">
96 mesa-demos</ulink> package)
97 </para>
98 </listitem>
99 </itemizedlist>
100
101 <bridgehead renderas="sect3">Mesa Dependencies</bridgehead>
102
103 <bridgehead renderas="sect4">Required</bridgehead>
104 <para role="required">
105 <xref linkend="xorg7-lib"/>,
106 <xref linkend="libdrm"/>, and
107 <xref linkend="Mako"/>
108 </para>
109
110 <bridgehead renderas="sect4">Recommended</bridgehead>
111 <para role="recommended">
112
113 <xref role="first" linkend="libva"/> (to provide VA-API support for some
114 gallium drivers, note that there is a circular dependency. You must
115 build <application>libva</application> first without EGL and GLX support,
116 install this package, and rebuild <application>libva</application>),
117 <xref linkend="libvdpau"/> (to build VDPAU drivers),
118 <xref linkend="llvm"/> (required for Gallium3D, nouveau, r300, and radeonsi
119 drivers and for swrast, the software rasterizer which is sometimes referred
120 to as llvmpipe. See <ulink role="nodep"
121 url="http://www.mesa3d.org/systems.html"/> for more information), and
122 <xref linkend="wayland-protocols"/> (required for
123 <xref role="nodep" linkend='plasma5-build'/>,
124 <!-- <xref role="nodep" linkend='lxqt'/>, -->
125 GNOME, and recommended for <xref role="nodep" linkend='gtk3'/>)
126 </para>
127
128 <bridgehead renderas="sect4">Optional</bridgehead>
129 <para role="optional">
130 <xref linkend="libgcrypt"/>,
131 <xref linkend="lm_sensors"/> <!-- for libsensors according to Meson -->,
132 <xref linkend="nettle"/>,
133 <xref linkend="valgrind"/>,
134 <ulink url="ftp://ftp.freedesktop.org/pub/mesa/demos/">mesa-demos</ulink>
135 (provides more than 300 extra demos to test
136 <application>Mesa</application>; this includes the same programs added by
137 the patch above),
138 <ulink url="http://omxil.sourceforge.net/">Bellagio OpenMAX Integration
139 Layer</ulink> (for mobile platforms), and
140 <ulink url="https://github.com/tizonia/tizonia-openmax-il/wiki/Tizonia-OpenMAX-IL/">
141 libtizonia</ulink>
142 </para>
143
144 <note>
145 <para>
146 The instructions below assume that
147 <application>LLVM</application> with the r600/amdgpu and host backends
148 and run-time type information (RTTI - needed for nouveau) are installed.
149 You will need to modify the instructions if you
150 choose not to install all of these. For an explanation of Gallium3D see
151 <ulink url="https://en.wikipedia.org/wiki/Gallium3D"/>.
152 </para>
153 </note>
154
155 <para condition="html" role="usernotes">User Notes:
156 <ulink url="&blfs-wiki;/mesa"/>
157 </para>
158 </sect2>
159
160 <sect2 role="installation">
161 <title>Installation of Mesa</title>
162
163 <para>
164 First, fix a problem when using Xorg with any device that uses the SVGA
165 driver:
166 </para>
167
168<screen><userinput>patch -Np1 -i ../mesa-&mesa-version;-fix_svga_vmwgfx_segfaults-1.patch</userinput></screen>
169
170 <para>
171 If you have downloaded the xdemos patch (needed if testing the Xorg
172 installation per BLFS instructions), apply it by running the following
173 command:
174 </para>
175
176<screen><userinput>patch -Np1 -i ../mesa-&mesa-version;-add_xdemos-1.patch</userinput></screen>
177
178 <!-- Note that freedreno, vc4, and virgl all need special support from
179 libdrm - renodr
180 For me, libdrm does not mention virgl, but mesa accepts it. AFAICS
181 freedreno is for qualcom hardware, libdrm will build for it on suitable
182 systems. VC4 is for the Broadcom VC4 used in the raspberry pi - ken -->
183
184 <para>
185 If <xref linkend="python2"/> is not installed, adjust a script file
186 in test suite to use Python 3:
187 </para>
188
189<screen><userinput>sed '1s@python@&amp;3@' -i bin/symbols-check.py</userinput></screen>
190
191 <note>
192 <para>
193 The measurements above, and the Contents below, are for a full build.
194 Many people will not wish to install drivers they cannot use, so the
195 following paragraphs explain how to limit the drivers, and give an
196 example which can be be reduced or amended as necessary.
197 </para>
198 </note>
199
200 <para>
201 Now, select the drivers you wish to install. For the X86 architecture, the
202 available gallium drivers are auto, <emphasis>or alternatively a choice
203 from</emphasis> i915, nouveau, r300, r600, radeonsi, svga, swrast, and
204 virgl. The latter is recommended if you intend to run the system under
205 <xref linkend="qemu"/>. If you wish to build all available gallium drivers,
206 use 'auto'.
207 </para>
208
209 <para>
210 The (non-gallium) DRI drivers available in X86 are auto, <emphasis>or
211 alternatively a choice from</emphasis> i915, i965, nouveau, r100, r200,
212 and swrast. Use 'auto' to build all available DRI drivers, or use an
213 empty string (DRI_DRIVERS="") if you wish to only build gallium drivers.
214 </para>
215
216 <para>
217 The platforms ("window systems") available for X86 linux are x11, wayland,
218 drm, and surfaceless. By not specifying anything, the meson build-system
219 will build for all these platforms if you have the dependencies, identical
220 to if you had specified '-Dplatforms=auto'.
221 </para>
222
223 <para>
224 Modify the commands below for your desired drivers. The drivers listed
225 below will cover most modern video cards and virtual machines. For help in
226 selecting drivers see <ulink url='http://www.mesa3d.org/systems.html'/>.
227 </para>
228
229 <note>
230 <para>
231 Although the nouveau drivers can be built for both gallium and dri, the
232 i915 driver can only be built for one or the other.
233 </para>
234 </note>
235
236<screen><userinput>GALLIUM_DRV="i915,nouveau,r600,radeonsi,svga,swrast,virgl"
237DRI_DRIVERS="i965,nouveau"</userinput></screen>
238
239 <para>
240 Install <application>Mesa</application> by running the following
241 commands:
242 </para>
243
244<screen><userinput>mkdir build &amp;&amp;
245cd build &amp;&amp;
246
247meson --prefix=$XORG_PREFIX \
248 -Dbuildtype=release \
249 -Ddri-drivers=$DRI_DRIVERS \
250 -Dgallium-drivers=$GALLIUM_DRV \
251 -Dgallium-nine=false \
252 -Dglx=dri \
253 -Dosmesa=gallium \
254 -Dvalgrind=false \
255 .. &amp;&amp;
256
257unset GALLIUM_DRV DRI_DRIVERS &amp;&amp;
258
259ninja</userinput></screen>
260
261 <para>
262 If you built the tests (see 'Command Explanations'), to run them issue:
263 <command>ninja test</command>.
264 </para>
265
266 <para>
267 Now, as the <systemitem class="username">root</systemitem> user:
268 </para>
269
270<screen role="root"><userinput>ninja install</userinput></screen>
271
272 <para>
273 If desired, install the optional documentation by running
274 the following commands as the
275 <systemitem class="username">root</systemitem> user:
276 </para>
277
278<screen role="root"><userinput>install -v -dm755 /usr/share/doc/mesa-&mesa-version; &amp;&amp;
279cp -rfv ../docs/* /usr/share/doc/mesa-&mesa-version;</userinput></screen>
280
281 </sect2>
282
283 <sect2 role="commands">
284 <title>Command Explanations</title>
285
286 <para>
287 <parameter>-Dbuildtype=release</parameter>: This switch ensures a
288 fully-optimized build, and disables debug assertions which will
289 severely slow down the libraries in certain use-cases. Without this
290 switch, build sizes can span into the 2GB range.
291 </para>
292
293 <para>
294 <parameter>-Ddri-drivers="..."</parameter>: This parameter
295 controls which (non-gallium) dri drivers should be built.
296 </para>
297
298 <para>
299 <parameter>-Dgallium-drivers="..."</parameter>: This parameter
300 controls which Gallium3D drivers should be built.
301 </para>
302
303 <para>
304 <option>-Dgallium-nine=true</option>: Setting this option to true will
305 provide support for (MS Windows) games designed for DX9.
306 </para>
307
308 <para>
309 <parameter>-Dosmesa=gallium</parameter>: This switch enables building
310 the <filename class="libraryfile">libOSMesa</filename> library and
311 provides Gallium3D support in it. It requires the swrast gallium driver.
312 </para>
313<!--
314 <para>
315 <parameter>-Dplatforms="..."</parameter>: This parameter
316 controls which platforms EGL will be built for. Available
317 linux X86 platforms are drm, x11, wayland, and surfaceless.
318 </para>
319-->
320 <para>
321 <parameter>-Dvalgrind=false</parameter>: This parameter disables
322 the usage of Valgrind during the build process. Remove this parameter
323 if you have Valgrind installed, and wish to check for memory leaks.
324 </para>
325
326<!--
327 <para>
328 <parameter>- -enable-xa</parameter>: This switch enables building the
329 XA X Acceleration API (Required for VMware 3D Driver).
330 </para>
331
332 <para>
333 <parameter>- -enable-gbm</parameter>: This switch enables building the
334 <application>Mesa</application> Graphics Buffer Manager library.
335 </para>
336 These two seem to be automatic in 19.0 - ken
337
338 <para>
339 <parameter>- -enable-glx-tls</parameter>: This switch enables TLS (Thread Local
340 Storage) support in GLX.
341 </para>
342-->
343 <para>
344 <option>-Dbuild-tests=true</option>: This option will cause the test code
345 to be enabled.
346 </para>
347
348 </sect2>
349
350 <sect2 role="content">
351 <title>Contents</title>
352
353 <segmentedlist>
354 <segtitle>Installed Programs</segtitle>
355 <segtitle>Installed Libraries</segtitle>
356 <segtitle>Installed Directories</segtitle>
357
358 <seglistitem>
359 <seg>
360 glxgears and glxinfo
361 </seg>
362 <seg>
363 <!-- Begin DRI drivers : this is the full set from auto -->
364 d3dadapter9.so, <!-- For Windows games. This is DirectX's Direct3D -->
365 i915_dri.so,
366 i965_dri.so,
367 kms_swrast_dri.so,
368 nouveau_dri.so,
369 nouveau_drv_video.so,
370 nouveau_vieux_dri.so,
371 r200_dri.so,
372 r300_dri.so,
373 r600_dri.so,
374 r600_drv_video.so,
375 radeon_dri.so,
376 radeonsi_dri.so,
377 radeonsi_drv_video.so,
378 swrast_dri.so,
379 virtio_gpu_dri.so,
380 vmwgfx_dri.so
381 <!-- End DRI Drivers -->
382 libEGL.so,
383 libGL.so,
384 libGLESv1_CM.so,
385 libGLESv2.so,
386 libOSMesa.so,
387 libXvMCnouveau.so,
388 libXvMCr600.so,
389 libgbm.so,
390 libglapi.so,
391 <!-- Begin Vulkan drivers -->
392 libvulkan_intel.so,
393 libvulkan_radeon.so,
394 <!-- End Vulkan drivers -->
395 libxatracker.so,
396 <!-- Begin VDPAU drivers -->
397 libvdpau_nouveau.so,
398 libvdpau_r300.so,
399 libvdpau_r600.so, and
400 libvdpau_radeonsi.so
401 <!-- End VDPAU drivers -->
402 </seg>
403 <seg>
404 $XORG_PREFIX/{include/{d3dapater,EGL,GL,GLES,GLES2,GLES3,KHR,vulkan},lib/{d3d,dri,vdpau}}
405 $XORG_PREFIX/share/drirc.d (contains workarounds for various applications,
406 particularly browsers and games)
407 $XORG_PREFIX/share/vulkan/icd.d,
408 and
409 /usr/share/doc/mesa-&mesa-version; (optional)
410 </seg>
411 </seglistitem>
412 </segmentedlist>
413
414 <variablelist>
415 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
416 <?dbfo list-presentation="list"?>
417 <?dbhtml list-presentation="table"?>
418
419 <varlistentry id="glxgears">
420 <term><command>glxgears</command></term>
421 <listitem>
422 <para>
423 is a GL demo useful for troubleshooting graphics
424 problems.
425 </para>
426 <indexterm zone="mesa glxgears">
427 <primary sortas="b-glxgears">glxgears</primary>
428 </indexterm>
429 </listitem>
430 </varlistentry>
431
432 <varlistentry id="glxinfo">
433 <term><command>glxinfo</command></term>
434 <listitem>
435 <para>
436 is a diagnostic program that displays information about the
437 graphics hardware and installed GL libraries.
438 </para>
439 <indexterm zone="mesa glxinfo">
440 <primary sortas="b-glxinfo">glxinfo</primary>
441 </indexterm>
442 </listitem>
443 </varlistentry>
444
445 <varlistentry id="libEGL">
446 <term><filename class="libraryfile">libEGL.so</filename></term>
447 <listitem>
448 <para>
449 provides a native platform graphics interface as
450 defined by the EGL-1.4 specification.
451 </para>
452 <indexterm zone="mesa libEGL">
453 <primary sortas="c-libGL">libEGL.so</primary>
454 </indexterm>
455 </listitem>
456 </varlistentry>
457
458 <varlistentry id="libgbm">
459 <term><filename class="libraryfile">libgbm.so</filename></term>
460 <listitem>
461 <para>
462 is the <application>Mesa</application> Graphics Buffer
463 Manager library.
464 </para>
465 <indexterm zone="mesa libgbm">
466 <primary sortas="c-libgbm">libgbm.so</primary>
467 </indexterm>
468 </listitem>
469 </varlistentry>
470
471 <varlistentry id="libGLESv1_CM">
472 <term><filename class="libraryfile">libGLESv1_CM.so</filename></term>
473 <listitem>
474 <para>
475 is the <application>Mesa</application> OpenGL ES 1.1 library.
476 </para>
477 <indexterm zone="mesa libGLESv1_CM">
478 <primary sortas="c-libGLESv1_CM">libGLESv1_CM.so</primary>
479 </indexterm>
480 </listitem>
481 </varlistentry>
482
483 <varlistentry id="libGLES2">
484 <term><filename class="libraryfile">libGLES2.so</filename></term>
485 <listitem>
486 <para>
487 is the <application>Mesa</application> OpenGL ES 2.0 library.
488 </para>
489 <indexterm zone="mesa libGLES2">
490 <primary sortas="c-libGLES2">libGLES2.so</primary>
491 </indexterm>
492 </listitem>
493 </varlistentry>
494
495 <varlistentry id="libGL">
496 <term><filename class="libraryfile">libGL.so</filename></term>
497 <listitem>
498 <para>
499 is the main <application>Mesa</application> OpenGL library.
500 </para>
501 <indexterm zone="mesa libGL">
502 <primary sortas="c-libGL">libGL.so</primary>
503 </indexterm>
504 </listitem>
505 </varlistentry>
506
507 <varlistentry id="libOSMesa">
508 <term><filename class="libraryfile">libOSMesa.so</filename></term>
509 <listitem>
510 <para>
511 is the <application>Mesa</application> Off-screen Rendering library.
512 </para>
513 <indexterm zone="mesa libOSMesa">
514 <primary sortas="c-libOSMesa">libOSMesa.so</primary>
515 </indexterm>
516 </listitem>
517 </varlistentry>
518
519 </variablelist>
520
521 </sect2>
522
523</sect1>
Note: See TracBrowser for help on using the repository browser.