[ab4fdfc] | 1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
[6732c094] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[868c7c2] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[c0a8c0dc] | 7 | <!ENTITY mesa-download-http "https://mesa.freedesktop.org/archive/mesa-&mesa-version;.tar.xz">
|
---|
[e1e58be] | 8 | <!ENTITY mesa-download-ftp " ">
|
---|
[46c84cd1] | 9 | <!ENTITY mesa-md5sum "0f4de2192e63b438637b98937ac85a10">
|
---|
[b8b314f5] | 10 | <!ENTITY mesa-size "28 MB">
|
---|
[15df65cd] | 11 | <!ENTITY mesa-buildsize "825 MB (with docs, add 496 MB for tests)">
|
---|
| 12 | <!ENTITY mesa-time "4.1 SBU (with docs; add 1.4 SBU for tests; both with parallelism=4)">
|
---|
[868c7c2] | 13 | ]>
|
---|
| 14 |
|
---|
[7a395d1] | 15 | <sect1 id="mesa" xreflabel="Mesa-&mesa-version;">
|
---|
| 16 | <?dbhtml filename="mesa.html"?>
|
---|
[868c7c2] | 17 |
|
---|
[7a395d1] | 18 | <title>Mesa-&mesa-version;</title>
|
---|
[868c7c2] | 19 |
|
---|
[7a395d1] | 20 | <indexterm zone="mesa">
|
---|
| 21 | <primary sortas="a-Mesa">Mesa</primary>
|
---|
[868c7c2] | 22 | </indexterm>
|
---|
| 23 |
|
---|
| 24 | <sect2 role="package">
|
---|
[7a395d1] | 25 | <title>Introduction to Mesa</title>
|
---|
[868c7c2] | 26 |
|
---|
[eb425b4] | 27 | <para>
|
---|
| 28 | <application>Mesa</application> is an OpenGL compatible 3D graphics
|
---|
| 29 | library.
|
---|
| 30 | </para>
|
---|
[868c7c2] | 31 |
|
---|
[fdcf97c7] | 32 | <note>
|
---|
| 33 | <para>
|
---|
| 34 | <application>Mesa</application> is updated relatively often. You may
|
---|
| 35 | want to use the latest available &mesa-major-minor;.x mesa version.
|
---|
| 36 | </para>
|
---|
| 37 | </note>
|
---|
| 38 |
|
---|
[d4dc5bae] | 39 | &lfs122_checked;
|
---|
[ca0c29cc] | 40 |
|
---|
[868c7c2] | 41 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 42 | <itemizedlist spacing="compact">
|
---|
| 43 | <listitem>
|
---|
[de938a4e] | 44 | <para>
|
---|
[7a395d1] | 45 | Download (HTTP): <ulink url="&mesa-download-http;"/>
|
---|
[de938a4e] | 46 | </para>
|
---|
[868c7c2] | 47 | </listitem>
|
---|
| 48 | <listitem>
|
---|
[de938a4e] | 49 | <para>
|
---|
[7a395d1] | 50 | Download (FTP): <ulink url="&mesa-download-ftp;"/>
|
---|
[de938a4e] | 51 | </para>
|
---|
[868c7c2] | 52 | </listitem>
|
---|
| 53 | <listitem>
|
---|
[de938a4e] | 54 | <para>
|
---|
[7a395d1] | 55 | Download MD5 sum: &mesa-md5sum;
|
---|
[de938a4e] | 56 | </para>
|
---|
[868c7c2] | 57 | </listitem>
|
---|
| 58 | <listitem>
|
---|
[de938a4e] | 59 | <para>
|
---|
[7a395d1] | 60 | Download size: &mesa-size;
|
---|
[de938a4e] | 61 | </para>
|
---|
[868c7c2] | 62 | </listitem>
|
---|
| 63 | <listitem>
|
---|
[de938a4e] | 64 | <para>
|
---|
[7a395d1] | 65 | Estimated disk space required: &mesa-buildsize;
|
---|
[de938a4e] | 66 | </para>
|
---|
[868c7c2] | 67 | </listitem>
|
---|
| 68 | <listitem>
|
---|
[de938a4e] | 69 | <para>
|
---|
[7a395d1] | 70 | Estimated build time: &mesa-time;
|
---|
[de938a4e] | 71 | </para>
|
---|
[868c7c2] | 72 | </listitem>
|
---|
| 73 | </itemizedlist>
|
---|
[1334c9a] | 74 |
|
---|
[625079b6] | 75 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
[a07e9eb] | 76 | <itemizedlist spacing="compact">
|
---|
[ab75b52] | 77 | <!-- 9 Apr 23. Change to unversioned patch since it never changes. -->
|
---|
[a07e9eb] | 78 | <listitem>
|
---|
[eb425b4] | 79 | <para>
|
---|
| 80 | Recommended patch:
|
---|
[3edc406] | 81 | <ulink url="&patch-root;/mesa-add_xdemos-2.patch"/>
|
---|
[7a395d1] | 82 | (installs 2 demo programs for testing Mesa - not needed if you
|
---|
[713981db] | 83 | install the <ulink url="https://archive.mesa3d.org/demos/">
|
---|
[39dd48b] | 84 | mesa-demos</ulink> package)
|
---|
[ace536a] | 85 | </para>
|
---|
[eeb29511] | 86 | </listitem>
|
---|
| 87 | </itemizedlist>
|
---|
[1334c9a] | 88 |
|
---|
[7a395d1] | 89 | <bridgehead renderas="sect3">Mesa Dependencies</bridgehead>
|
---|
[868c7c2] | 90 |
|
---|
| 91 | <bridgehead renderas="sect4">Required</bridgehead>
|
---|
[7b74537e] | 92 | <para role="required">
|
---|
[df343952] | 93 | <xref linkend="xorg7-lib"/>,
|
---|
[e2aae21f] | 94 | <xref linkend="libdrm"/>, and
|
---|
| 95 | <xref linkend="Mako"/>
|
---|
[eb425b4] | 96 | </para>
|
---|
[868c7c2] | 97 |
|
---|
[606dfd4] | 98 | <bridgehead renderas="sect4">Recommended</bridgehead>
|
---|
[eb425b4] | 99 | <para role="recommended">
|
---|
[d2f50ba] | 100 |
|
---|
[c833c06] | 101 | <itemizedlist spacing="compact">
|
---|
| 102 | <listitem>
|
---|
| 103 | <para>
|
---|
[6749017] | 104 | <xref linkend="glslang"/> (required for Vulkan support)
|
---|
[c833c06] | 105 | </para>
|
---|
| 106 | </listitem>
|
---|
| 107 | <listitem>
|
---|
| 108 | <para>
|
---|
| 109 | <xref linkend="libva"/> (to provide VA-API support for some
|
---|
| 110 | gallium drivers. Note that there is a circular dependency.
|
---|
| 111 | You must build <application>libva</application> first without
|
---|
| 112 | mesa's EGL and GLX support, install this package, and rebuild
|
---|
| 113 | <application>libva</application>)
|
---|
| 114 | </para>
|
---|
| 115 | </listitem>
|
---|
| 116 | <listitem>
|
---|
| 117 | <para>
|
---|
| 118 | <xref linkend="libvdpau"/> (to build VDPAU drivers)
|
---|
| 119 | </para>
|
---|
| 120 | </listitem>
|
---|
| 121 | <listitem>
|
---|
| 122 | <para>
|
---|
| 123 | <xref linkend="llvm"/> (required for the r300, r600, and radeonsi
|
---|
| 124 | drivers, and the LLVMpipe software rasterizer which can make the
|
---|
| 125 | swrast driver much faster)
|
---|
| 126 | </para>
|
---|
| 127 | </listitem>
|
---|
| 128 | <listitem>
|
---|
| 129 | <para>
|
---|
| 130 | <xref linkend="wayland-protocols"/> (required for
|
---|
| 131 | <xref role="nodep" linkend='plasma-build'/>,
|
---|
| 132 | GNOME, and recommended for
|
---|
| 133 | <xref role="nodep" linkend='gtk3'/>)
|
---|
| 134 | </para>
|
---|
| 135 | </listitem>
|
---|
[b8b314f5] | 136 | <listitem>
|
---|
| 137 | <para>
|
---|
[68df8455] | 138 | <xref linkend="libclc"/> (required for the Intel iris
|
---|
| 139 | gallium driver)
|
---|
| 140 | </para>
|
---|
| 141 | </listitem>
|
---|
[6749017] | 142 | <listitem>
|
---|
| 143 | <para>
|
---|
| 144 | <xref linkend="vulkan-loader"/> (required for the Zink
|
---|
| 145 | gallium driver)
|
---|
| 146 | </para>
|
---|
| 147 | </listitem>
|
---|
[68df8455] | 148 | <listitem>
|
---|
| 149 | <para>
|
---|
| 150 | <xref linkend="ply"/> (required for the Intel vulkan driver)
|
---|
[b8b314f5] | 151 | </para>
|
---|
| 152 | </listitem>
|
---|
| 153 | <listitem>
|
---|
| 154 | <para>
|
---|
| 155 | <xref linkend="cbindgen"/> and <xref linkend="rust-bindgen"/>
|
---|
[68df8455] | 156 | (required for the Nouveau Vulkan driver)
|
---|
[b8b314f5] | 157 | </para>
|
---|
| 158 | </listitem>
|
---|
[c833c06] | 159 | </itemizedlist>
|
---|
[606dfd4] | 160 | </para>
|
---|
[60bcf481] | 161 |
|
---|
[87a677a] | 162 | <note>
|
---|
| 163 | <para>
|
---|
| 164 | <emphasis role="bold">Choosing Mesa Drivers</emphasis>
|
---|
| 165 | </para>
|
---|
| 166 |
|
---|
| 167 | <para>
|
---|
| 168 | In the instructions below, all the available drivers are built. That
|
---|
| 169 | will almost always work. However, it is not efficient. Depending on
|
---|
| 170 | your video hardware, you probably need only specific drivers.
|
---|
| 171 | </para>
|
---|
| 172 |
|
---|
| 173 | <para>
|
---|
| 174 | The first thing you need to know is which type of video device you
|
---|
[de36458] | 175 | have. In some cases it is built into the CPU. In others it is a
|
---|
[87a677a] | 176 | separate PCI card. In either case you can tell what video hardware you
|
---|
[68df8455] | 177 | have by installing <xref linkend='pciutils'/> and running:
|
---|
[87a677a] | 178 | </para>
|
---|
| 179 |
|
---|
[68df8455] | 180 | <screen role='nodump'><userinput>lspci | grep VGA</userinput></screen>
|
---|
[87a677a] | 181 |
|
---|
| 182 | <para>
|
---|
| 183 | The video device is most likely one of three families: AMD, Intel, or
|
---|
[68df8455] | 184 | Nvidia. See the Command Explanations for
|
---|
| 185 | <parameter>-D gallium-drivers=auto</parameter> below to
|
---|
[87a677a] | 186 | see what options are available for your specific video hardware (or
|
---|
| 187 | emulated video hardware). You should probably add the swrast option as
|
---|
| 188 | a backup driver.
|
---|
| 189 | </para>
|
---|
| 190 |
|
---|
| 191 | <para>
|
---|
| 192 | For 'platforms' you can select x11 and/or wayland. Note that in BLFS
|
---|
| 193 | currently only Gnome and KDE can use wayland. If you are not going to
|
---|
| 194 | use one of those desktop environments then you probably only want x11.
|
---|
| 195 | </para>
|
---|
| 196 |
|
---|
| 197 | <para>
|
---|
| 198 | For 'vulkan-drivers' you may want to limit the selection to your
|
---|
| 199 | current hardware. These drivers are used by some specific applications.
|
---|
| 200 |
|
---|
| 201 | For example, ffmpeg (including ffplay) will use Vulkan instead of
|
---|
| 202 | OpenGL for rendering video on the GPU. If you do not want to do this
|
---|
| 203 | you may or may not want to install them.
|
---|
[68df8455] | 204 | See the Command Explanations for
|
---|
| 205 | <parameter>-D vulkan-drivers=auto</parameter> below to
|
---|
| 206 | see what options are available for your specific video hardware (or
|
---|
| 207 | emulated video hardware). You should probably add the swrast option
|
---|
| 208 | as a backup driver unless you don't need Vulkan at all.
|
---|
[87a677a] | 209 | </para>
|
---|
| 210 | </note>
|
---|
| 211 |
|
---|
[07584d8] | 212 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
| 213 | <para role="optional">
|
---|
[57bcce9] | 214 | <xref linkend="libgcrypt"/>,
|
---|
[751dd1e] | 215 | <xref linkend="libunwind"/>,
|
---|
[b4d0b5a] | 216 | <xref linkend="lm_sensors"/> <!-- for libsensors according to Meson -->,
|
---|
[57bcce9] | 217 | <xref linkend="nettle"/>,
|
---|
[b4d0b5a] | 218 | <xref linkend="valgrind"/>,
|
---|
[9dc1c31] | 219 | <ulink url="https://archive.mesa3d.org/demos/">mesa-demos</ulink>
|
---|
[1cdb1f7] | 220 | (provides more than 300 extra demos to test
|
---|
[973dabe9] | 221 | <application>Mesa</application>; this includes the same programs added by
|
---|
[b4d0b5a] | 222 | the patch above),
|
---|
[17aa21c] | 223 | <ulink url="https://omxil.sourceforge.net/">Bellagio OpenMAX Integration
|
---|
[e929885e] | 224 | Layer</ulink> (for mobile platforms), and
|
---|
| 225 | <!--<ulink url="https://github.com/KhronosGroup/glslang">glslang</ulink>
|
---|
| 226 | (for vulkan drivers),-->
|
---|
[b4d0b5a] | 227 | <ulink url="https://github.com/tizonia/tizonia-openmax-il/wiki/Tizonia-OpenMAX-IL/">
|
---|
[e929885e] | 228 | libtizonia</ulink>,
|
---|
| 229 | <!-- <ulink url="https://github.com/KhronosGroup/Vulkan-Loader">Vulkan-Loader</ulink> -->
|
---|
[07584d8] | 230 | </para>
|
---|
[bee072a] | 231 | <!--
|
---|
[9065a56b] | 232 | <note>
|
---|
[fd2f9a2] | 233 | <para>
|
---|
[e4fbb24] | 234 | The instructions below assume that
|
---|
[d2f50ba] | 235 | <application>LLVM</application> with the r600/amdgpu and host backends
|
---|
| 236 | and run-time type information (RTTI - needed for nouveau) are installed.
|
---|
| 237 | You will need to modify the instructions if you
|
---|
| 238 | choose not to install all of these. For an explanation of Gallium3D see
|
---|
[e83a3bb] | 239 | <ulink url="https://en.wikipedia.org/wiki/Gallium3D"/>.
|
---|
[fd2f9a2] | 240 | </para>
|
---|
[9065a56b] | 241 | </note>
|
---|
[bee072a] | 242 | -->
|
---|
[0f256d6] | 243 |
|
---|
| 244 | &build-use-internet;
|
---|
| 245 |
|
---|
[868c7c2] | 246 | </sect2>
|
---|
| 247 |
|
---|
[797182d] | 248 | <sect2 role="kernel" id="mesa-kernel"
|
---|
| 249 | xreflabel='Mesa Kernel Configuration'>
|
---|
[2c92dada] | 250 | <title>Kernel Configuration</title>
|
---|
| 251 |
|
---|
| 252 | <para>
|
---|
| 253 | Enable the following options in the kernel configuration and
|
---|
| 254 | recompile the kernel if necessary:
|
---|
| 255 | </para>
|
---|
| 256 |
|
---|
[5ca8d70] | 257 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
| 258 | href="mesa-kernel.xml"/>
|
---|
[2c92dada] | 259 |
|
---|
| 260 | <note>
|
---|
| 261 | <para>
|
---|
| 262 | The corresponding Mesa Gallium3D driver name is provided as the
|
---|
| 263 | comment for the configuration entries. If you don't know the name
|
---|
| 264 | of the Mesa Gallium3D driver for your GPU, see <xref
|
---|
| 265 | linkend="mesa-gallium-drivers"/> below.
|
---|
| 266 | </para>
|
---|
| 267 |
|
---|
| 268 | <para>
|
---|
| 269 | <option>CONFIG_DRM_RADEON</option>,
|
---|
| 270 | <option>CONFIG_DRM_AMDGPU</option>,
|
---|
| 271 | <option>CONFIG_DRM_NOUVEAU</option>, and
|
---|
[d4102ce] | 272 | <option>CONFIG_DRM_I915</option> may require firmware.
|
---|
| 273 | See <xref linkend='postlfs-firmware'/> for details.
|
---|
[2c92dada] | 274 | </para>
|
---|
| 275 |
|
---|
| 276 | <para>
|
---|
[d4102ce] | 277 | Selecting <option>CONFIG_DRM_RADEON</option> or
|
---|
| 278 | <option>CONFIG_DRM_AMDGPU</option> as
|
---|
| 279 | <quote><literal>y</literal></quote> is not recommended. If it is, any
|
---|
| 280 | required firmware must be built as a part of the kernel image or the
|
---|
| 281 | initramfs for the driver to function correctly.
|
---|
[2c92dada] | 282 | </para>
|
---|
| 283 |
|
---|
| 284 | <para>
|
---|
| 285 | The sub-entries under <option>CONFIG_DRM_AMDGPU</option> are used
|
---|
[d4102ce] | 286 | to ensure the AMDGPU kernel driver supports all GPUs using the
|
---|
[2c92dada] | 287 | <literal>radeonsi</literal> driver. They are not needed if you
|
---|
[d4102ce] | 288 | won't need <option>CONFIG_DRM_AMDGPU</option> itself. They
|
---|
[2c92dada] | 289 | may be unneeded for some GPU models.
|
---|
| 290 | </para>
|
---|
| 291 |
|
---|
| 292 | <para>
|
---|
| 293 | For <literal>swrast</literal>, <option>CONFIG_DRM_VGEM</option>
|
---|
[797182d] | 294 | is not strictly needed but recommended as an optimization.
|
---|
[2c92dada] | 295 | </para>
|
---|
| 296 | </note>
|
---|
[117b4e9] | 297 | <indexterm zone="mesa mesa-kernel">
|
---|
| 298 | <primary sortas="d-mesa">mesa</primary>
|
---|
| 299 | </indexterm>
|
---|
[2c92dada] | 300 | </sect2>
|
---|
| 301 |
|
---|
[868c7c2] | 302 | <sect2 role="installation">
|
---|
[7a395d1] | 303 | <title>Installation of Mesa</title>
|
---|
[a07e9eb] | 304 | <para>
|
---|
[51c08f3] | 305 | If you have downloaded the xdemos patch (needed if testing the Xorg
|
---|
| 306 | installation per BLFS instructions), apply it by running the following
|
---|
| 307 | command:
|
---|
[a07e9eb] | 308 | </para>
|
---|
| 309 |
|
---|
[ab75b52] | 310 | <!--<screen><userinput>patch -Np1 -i ../mesa-&mesa-version;-add_xdemos-1.patch</userinput></screen>-->
|
---|
[3edc406] | 311 | <screen><userinput>patch -Np1 -i ../mesa-add_xdemos-2.patch</userinput></screen>
|
---|
[1334c9a] | 312 |
|
---|
[054e926] | 313 | <!-- Note that freedreno, vc4, and virgl all need special support from
|
---|
[d2f50ba] | 314 | libdrm - renodr
|
---|
| 315 | For me, libdrm does not mention virgl, but mesa accepts it. AFAICS
|
---|
| 316 | freedreno is for qualcom hardware, libdrm will build for it on suitable
|
---|
| 317 | systems. VC4 is for the Broadcom VC4 used in the raspberry pi - ken -->
|
---|
[bee072a] | 318 | <!--
|
---|
[d2f50ba] | 319 | <note>
|
---|
| 320 | <para>
|
---|
| 321 | The measurements above, and the Contents below, are for a full build.
|
---|
| 322 | Many people will not wish to install drivers they cannot use, so the
|
---|
| 323 | following paragraphs explain how to limit the drivers, and give an
|
---|
| 324 | example which can be be reduced or amended as necessary.
|
---|
| 325 | </para>
|
---|
| 326 | </note>
|
---|
| 327 |
|
---|
[bee072a] | 328 | -->
|
---|
| 329 | <!--
|
---|
[d2f50ba] | 330 | <para>
|
---|
| 331 | The (non-gallium) DRI drivers available in X86 are auto, <emphasis>or
|
---|
| 332 | alternatively a choice from</emphasis> i915, i965, nouveau, r100, r200,
|
---|
| 333 | and swrast. Use 'auto' to build all available DRI drivers, or use an
|
---|
| 334 | empty string (DRI_DRIVERS="") if you wish to only build gallium drivers.
|
---|
| 335 | </para>
|
---|
| 336 |
|
---|
| 337 | <para>
|
---|
| 338 | The platforms ("window systems") available for X86 linux are x11, wayland,
|
---|
[bee072a] | 339 | drm, and surfaceless. By not specifying anything, the meson
|
---|
[17ae4374] | 340 | build-system will build for all these platforms if you have the
|
---|
| 341 | dependencies, identical to if you had specified '-Dplatforms=auto'.
|
---|
[d2f50ba] | 342 | </para>
|
---|
| 343 |
|
---|
| 344 | <para>
|
---|
| 345 | Modify the commands below for your desired drivers. The drivers listed
|
---|
| 346 | below will cover most modern video cards and virtual machines. For help in
|
---|
[c6cb93b] | 347 | selecting drivers see <ulink url="https://docs.mesa3d.org/systems.html"/>.
|
---|
[bee072a] | 348 | -->
|
---|
[ef936e4] | 349 | <!-- these two don't seem to be mentioned in that mesa link -->
|
---|
[bee072a] | 350 | <!--
|
---|
[ef936e4] | 351 | For intel drivers, specify crocus for i965 gen 4 through to haswell, iris
|
---|
| 352 | for broadwell and later.
|
---|
[d2f50ba] | 353 | </para>
|
---|
| 354 |
|
---|
| 355 | <note>
|
---|
| 356 | <para>
|
---|
| 357 | Although the nouveau drivers can be built for both gallium and dri, the
|
---|
| 358 | i915 driver can only be built for one or the other.
|
---|
| 359 | </para>
|
---|
| 360 | </note>
|
---|
| 361 |
|
---|
[ef936e4] | 362 | <screen><userinput>GALLIUM_DRV="crocus,i915,iris,nouveau,r600,radeonsi,svga,swrast,virgl"
|
---|
[d2f50ba] | 363 | DRI_DRIVERS="i965,nouveau"</userinput></screen>
|
---|
[bee072a] | 364 | -->
|
---|
[43149b8] | 365 |
|
---|
[b565745d] | 366 | <!-- https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22021 -->
|
---|
[92202f73] | 367 | <!-- No longer needed
|
---|
[b565745d] | 368 | <para>
|
---|
| 369 | Remove two unneeded references to LLVM headers to avoid a build
|
---|
| 370 | failure with LLVM 17 or later:
|
---|
| 371 | </para>
|
---|
| 372 |
|
---|
| 373 | <screen><userinput>sed '/Scalar.h/d;/Utils.h/d' \
|
---|
| 374 | -i src/gallium/auxiliary/gallivm/lp_bld_init.c</userinput></screen>
|
---|
[92202f73] | 375 | -->
|
---|
[eb425b4] | 376 | <para>
|
---|
[7a395d1] | 377 | Install <application>Mesa</application> by running the following
|
---|
[eb425b4] | 378 | commands:
|
---|
| 379 | </para>
|
---|
[868c7c2] | 380 |
|
---|
[b565745d] | 381 | <screen><userinput>mkdir build &&
|
---|
[b3f053c5] | 382 | cd build &&
|
---|
[a85e5ce] | 383 |
|
---|
[c833c06] | 384 | meson setup .. \
|
---|
| 385 | --prefix=$XORG_PREFIX \
|
---|
| 386 | --buildtype=release \
|
---|
| 387 | -D platforms=x11,wayland \
|
---|
| 388 | -D gallium-drivers=auto \
|
---|
| 389 | -D vulkan-drivers=auto \
|
---|
| 390 | -D valgrind=disabled \
|
---|
| 391 | -D libunwind=disabled &&
|
---|
[f7bc172] | 392 |
|
---|
[b3f053c5] | 393 | ninja</userinput></screen>
|
---|
[868c7c2] | 394 |
|
---|
[b3f053c5] | 395 | <para>
|
---|
[5ba1d98e] | 396 | To test the results, issue:
|
---|
[68df8455] | 397 | <command>meson configure -D build-tests=true && ninja test</command>.
|
---|
[b3f053c5] | 398 | </para>
|
---|
[f7bc172] | 399 | <!-- All 88 tests passed for me for 22.3.3 [pierre]
|
---|
[28818fd3] | 400 | All 90 tests passed for me for 23.1.0 [bdubbs]
|
---|
[b968722] | 401 | 89 Tests passed for me, 1 timeout on 23.1.8 [rahul]
|
---|
[92202f73] | 402 | All 98 tests passed for me for 23.3.1 [bdubbs]
|
---|
[bee072a] | 403 | -->
|
---|
[ef936e4] | 404 |
|
---|
[eb425b4] | 405 | <para>
|
---|
| 406 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 407 | </para>
|
---|
[ff55539b] | 408 |
|
---|
[b3f053c5] | 409 | <screen role="root"><userinput>ninja install</userinput></screen>
|
---|
[a07e9eb] | 410 |
|
---|
[eb425b4] | 411 | <para>
|
---|
[a07e9eb] | 412 | If desired, install the optional documentation by running
|
---|
| 413 | the following commands as the
|
---|
[eb425b4] | 414 | <systemitem class="username">root</systemitem> user:
|
---|
| 415 | </para>
|
---|
[91859cf] | 416 |
|
---|
[3713bc71] | 417 | <screen role="root"
|
---|
[8c25fe7] | 418 | remap="doc"><userinput>cp -rv ../docs -T /usr/share/doc/mesa-&mesa-version;</userinput></screen>
|
---|
[5a883bc4] | 419 |
|
---|
[868c7c2] | 420 | </sect2>
|
---|
| 421 |
|
---|
[a07e9eb] | 422 | <sect2 role="commands">
|
---|
| 423 | <title>Command Explanations</title>
|
---|
[d2f50ba] | 424 |
|
---|
[95e8211] | 425 | <para>
|
---|
[3918112a] | 426 | <parameter>--buildtype=release</parameter>: This switch ensures a
|
---|
[d2f50ba] | 427 | fully-optimized build, and disables debug assertions which will
|
---|
[ec77633] | 428 | severely slow down the libraries in certain use-cases. Without this
|
---|
[3d516cf] | 429 | switch, build sizes can span into the 2 GB range.
|
---|
[95e8211] | 430 | </para>
|
---|
[869bf46b] | 431 |
|
---|
[d2f50ba] | 432 | <para>
|
---|
[2c92dada] | 433 | <anchor id='mesa-gallium-drivers' xreflabel='Mesa Gallium3D Drivers'/>
|
---|
[68df8455] | 434 | <parameter>-D gallium-drivers=auto</parameter>: This parameter
|
---|
[c833c06] | 435 | controls which Gallium3D drivers should be built:
|
---|
| 436 |
|
---|
| 437 | <itemizedlist spacing="compact">
|
---|
| 438 | <listitem>
|
---|
| 439 | <para>
|
---|
| 440 | <literal>auto</literal> selects all Gallium3D drivers available
|
---|
[68df8455] | 441 | for x86. With a comma-separated list, only a subset of these
|
---|
[c833c06] | 442 | drivers will be built. If you precisely know which drivers you
|
---|
[ac1f23de] | 443 | need, you can select them explicitly. For example,
|
---|
[68df8455] | 444 | <option>-D gallium-drivers=radeonsi,iris,swrast</option>.
|
---|
[c833c06] | 445 | </para>
|
---|
| 446 | </listitem>
|
---|
| 447 | <listitem>
|
---|
| 448 | <para>
|
---|
| 449 | <literal>r300</literal> (for ATI Radeon 9000 or Radeon X series)
|
---|
| 450 | </para>
|
---|
| 451 | </listitem>
|
---|
| 452 | <listitem>
|
---|
| 453 | <para>
|
---|
| 454 | <literal>r600</literal> (for AMD/ATI Radeon HD 2000-6000 series)
|
---|
| 455 | </para>
|
---|
| 456 | </listitem>
|
---|
| 457 | <listitem>
|
---|
| 458 | <para>
|
---|
| 459 | <literal>radeonsi</literal> (for AMD Radeon HD 7000 or newer AMD GPU models)
|
---|
| 460 | </para>
|
---|
| 461 | </listitem>
|
---|
| 462 | <listitem>
|
---|
| 463 | <para>
|
---|
[0538ffc] | 464 | <literal>nouveau</literal> (for supported NVIDIA GPUs, they are
|
---|
[c833c06] | 465 | listed as all <quote>3D features</quote> either <quote>DONE</quote> or
|
---|
| 466 | <quote>N/A</quote> in
|
---|
| 467 | <ulink url='https://nouveau.freedesktop.org/FeatureMatrix.html'>the Nouveau
|
---|
| 468 | status page</ulink>)
|
---|
| 469 | </para>
|
---|
| 470 | </listitem>
|
---|
| 471 | <listitem>
|
---|
| 472 | <para>
|
---|
| 473 | <literal>virgl</literal> (for a QEMU virtual GPU
|
---|
| 474 | with <application>virglrender</application> support; note that BLFS
|
---|
| 475 | <xref linkend='qemu'/> is not built with
|
---|
| 476 | <application>virglrender</application>)
|
---|
| 477 | </para>
|
---|
| 478 | </listitem>
|
---|
| 479 | <listitem>
|
---|
| 480 | <para>
|
---|
| 481 | <literal>svga</literal> (for a VMWare virtual GPU)
|
---|
| 482 | </para>
|
---|
| 483 | </listitem>
|
---|
| 484 | <listitem>
|
---|
| 485 | <para>
|
---|
| 486 | <literal>swrast</literal> (using CPU for 3D
|
---|
[ac1f23de] | 487 | rasterization. Note that it's much slower than using a modern
|
---|
[c833c06] | 488 | 3D-capable GPU, so it should be only used if the GPU is not supported
|
---|
| 489 | by other drivers),
|
---|
| 490 | </para>
|
---|
| 491 | </listitem>
|
---|
| 492 | <listitem>
|
---|
| 493 | <para>
|
---|
| 494 | <literal>iris</literal> (for Intel GPUs shipped with Broadwell
|
---|
[68df8455] | 495 | or newer CPUs, or as a dedicated PCIe card)
|
---|
[c833c06] | 496 | </para>
|
---|
| 497 | </listitem>
|
---|
| 498 | <listitem>
|
---|
| 499 | <para>
|
---|
| 500 | <literal>crocus</literal> (for Intel GMA 3000, X3000 series,
|
---|
| 501 | 4000 series, or X4000 series GPUs shipped with chipsets,
|
---|
| 502 | or Intel HD GPUs shipped with pre-Broadwell CPUs)
|
---|
| 503 | </para>
|
---|
| 504 | </listitem>
|
---|
| 505 | <listitem>
|
---|
| 506 | <para>
|
---|
| 507 | <literal>i915</literal> (for Intel GMA 900, 950, 3100, or 3150 GPUs
|
---|
| 508 | shipped with chipsets or Atom D/N 4xx/5xx CPUs)
|
---|
| 509 | </para>
|
---|
| 510 | </listitem>
|
---|
[68df8455] | 511 | <listitem>
|
---|
| 512 | <para>
|
---|
| 513 | <literal>zink</literal> (using Vulkan to implement OpenGL,
|
---|
| 514 | it's not very useful on x86 as at now but it may replace other
|
---|
| 515 | drivers for modern GPU models in the future)
|
---|
| 516 | </para>
|
---|
| 517 | </listitem>
|
---|
| 518 | </itemizedlist>
|
---|
| 519 | </para>
|
---|
| 520 |
|
---|
| 521 | <para>
|
---|
| 522 | <parameter>-D vulkan-drivers=auto</parameter>: This parameter
|
---|
[5844abce] | 523 | controls which Vulkan drivers should be built:
|
---|
[68df8455] | 524 |
|
---|
| 525 | <itemizedlist spacing="compact">
|
---|
| 526 | <listitem>
|
---|
| 527 | <para>
|
---|
| 528 | <literal>auto</literal> selects all Vulkan drivers available
|
---|
| 529 | for x86. With a comma-separated list, only a subset of these
|
---|
| 530 | drivers will be built. If you precisely know which drivers you
|
---|
[ac1f23de] | 531 | need, you can select them explicitly. For example,
|
---|
[3038a588] | 532 | <option>-D vulkan-drivers=amd,nouveau,swrast</option>.
|
---|
[68df8455] | 533 | </para>
|
---|
| 534 | </listitem>
|
---|
| 535 |
|
---|
| 536 | <listitem>
|
---|
| 537 | <para>
|
---|
| 538 | <literal>amd</literal> (for AMD Radeon HD 7730 or newer AMD GPUs)
|
---|
| 539 | </para>
|
---|
| 540 | </listitem>
|
---|
| 541 |
|
---|
| 542 | <listitem>
|
---|
| 543 | <para>
|
---|
| 544 | <literal>intel</literal> (for Intel GPUs shipped with Skylake
|
---|
| 545 | or newer CPUs, or as a dedicated PCIe card)
|
---|
| 546 | </para>
|
---|
| 547 | </listitem>
|
---|
| 548 |
|
---|
| 549 | <listitem>
|
---|
| 550 | <para>
|
---|
| 551 | <literal>intel_hasvk</literal> (for Intel GPUs shipped with
|
---|
| 552 | Ivy Bridge, Haswell, or Broadwell CPUs)
|
---|
| 553 | </para>
|
---|
| 554 | </listitem>
|
---|
| 555 |
|
---|
| 556 | <listitem>
|
---|
| 557 | <para>
|
---|
| 558 | <literal>nouveau</literal> (for GTX 16XX, RTX 20XX, or
|
---|
| 559 | newer NVIDIA GPUs)
|
---|
| 560 | </para>
|
---|
| 561 | </listitem>
|
---|
| 562 |
|
---|
| 563 | <listitem>
|
---|
| 564 | <para>
|
---|
[ac1f23de] | 565 | <literal>swrast</literal> (for using the CPU for 3D rasterization)
|
---|
[68df8455] | 566 | Note that it's much slower than using a modern 3D-capable GPU,
|
---|
| 567 | so it should be only used if the GPU is not supported by other
|
---|
[ac1f23de] | 568 | drivers.
|
---|
[68df8455] | 569 | </para>
|
---|
| 570 | </listitem>
|
---|
[5844abce] | 571 |
|
---|
| 572 | <listitem>
|
---|
| 573 | <para>
|
---|
| 574 | <literal>""</literal> (empty list, use
|
---|
[0538ffc] | 575 | <option>-D vulkan-drivers=""</option> if you've not installed and
|
---|
[5844abce] | 576 | you don't plan to install <xref linkend='vulkan-loader'/>)
|
---|
| 577 | </para>
|
---|
| 578 | </listitem>
|
---|
[c833c06] | 579 | </itemizedlist>
|
---|
[d2f50ba] | 580 | </para>
|
---|
[bee072a] | 581 |
|
---|
[eb425b4] | 582 | <para>
|
---|
[68df8455] | 583 | <parameter>-D platforms=...</parameter>: This parameter
|
---|
[bee072a] | 584 | controls which windowing systems will be supported. Available
|
---|
| 585 | linux platforms are x11 and wayland.
|
---|
[eb425b4] | 586 | </para>
|
---|
[bee072a] | 587 |
|
---|
[2993b2f] | 588 | <para>
|
---|
[68df8455] | 589 | <parameter>-D valgrind=disabled</parameter>: This parameter disables
|
---|
[d2f50ba] | 590 | the usage of Valgrind during the build process. Remove this parameter
|
---|
| 591 | if you have Valgrind installed, and wish to check for memory leaks.
|
---|
[2993b2f] | 592 | </para>
|
---|
| 593 |
|
---|
[42117d4e] | 594 | <para>
|
---|
[68df8455] | 595 | <parameter>-D libunwind=disabled</parameter>: This parameter disables
|
---|
[42117d4e] | 596 | the usage of libunwind.
|
---|
| 597 | </para>
|
---|
| 598 |
|
---|
[a07e9eb] | 599 | <para>
|
---|
[68df8455] | 600 | <command>meson configure -D build-tests=true</command>: This command will
|
---|
| 601 | reconfigure the build to set <option>-D build-tests=true</option>, but
|
---|
[adcccac] | 602 | keep the other options specified in the <command>meson setup</command>
|
---|
| 603 | command unchanged. It allows <command>ninja test</command> to build and
|
---|
| 604 | run unit tests.
|
---|
[b4d0b5a] | 605 | </para>
|
---|
| 606 |
|
---|
[3713bc71] | 607 | <para>
|
---|
[68df8455] | 608 | <option>-D egl-native-platform="..."</option>: This parameter
|
---|
[869bf46b] | 609 | controls which Embedded Graphics Library support will be built. Available
|
---|
| 610 | linux options are auto (default), x11, wayland, surfaceless, and drm.
|
---|
[3713bc71] | 611 | </para>
|
---|
| 612 |
|
---|
[371ff30] | 613 | </sect2>
|
---|
| 614 |
|
---|
[868c7c2] | 615 | <sect2 role="content">
|
---|
| 616 | <title>Contents</title>
|
---|
| 617 |
|
---|
| 618 | <segmentedlist>
|
---|
[1263ab1e] | 619 | <segtitle>Installed Programs</segtitle>
|
---|
[42117d4e] | 620 | <segtitle>Installed Libraries</segtitle><!-- in /usr/lib -->
|
---|
[e929885e] | 621 | <segtitle>Installed DRI Drivers</segtitle><!-- in /usr/lib/dri -->
|
---|
| 622 | <segtitle>Installed VDPAU Drivers</segtitle><!-- in /usr/lib/vdpau -->
|
---|
| 623 | <segtitle>Installed Vulkan Drivers</segtitle><!-- in /usr/lib -->
|
---|
[ba2ac60] | 624 | <segtitle>Installed Directories</segtitle>
|
---|
[868c7c2] | 625 |
|
---|
| 626 | <seglistitem>
|
---|
[eb425b4] | 627 | <seg>
|
---|
[b8b314f5] | 628 | glxgears,
|
---|
| 629 | glxinfo,
|
---|
| 630 | mme_fermi_sim_hw_test, and
|
---|
| 631 | mme_tu104_sim_hw_test
|
---|
[eb425b4] | 632 | </seg>
|
---|
[42117d4e] | 633 | <seg>
|
---|
| 634 | libEGL.so,
|
---|
| 635 | libGL.so,
|
---|
| 636 | libGLESv1_CM.so,
|
---|
| 637 | libGLESv2.so,
|
---|
| 638 | libgbm.so,
|
---|
[7b9b069] | 639 | libglapi.so, and
|
---|
| 640 | libxatracker.so
|
---|
[42117d4e] | 641 | </seg>
|
---|
[eb425b4] | 642 | <seg>
|
---|
[2c92dada] | 643 | <!-- d3dadapter9.so (optional)
|
---|
| 644 | I guess this is useless today, Wine applications use Vulkan
|
---|
| 645 | through libvkd3d, and new games with native Linux support
|
---|
| 646 | likely uses Vulkan directly. -->
|
---|
| 647 | <!-- Begin gallium DRI drivers (*_dri.so) and VA-API drivers
|
---|
| 648 | (*_drv_video.so): this is the full set -->
|
---|
[ef936e4] | 649 | crocus_dri.so,
|
---|
[b3f053c5] | 650 | i915_dri.so,
|
---|
[db480be] | 651 | iris_dri.so,
|
---|
[b3f053c5] | 652 | kms_swrast_dri.so,
|
---|
| 653 | nouveau_dri.so,
|
---|
[d2f50ba] | 654 | nouveau_drv_video.so,
|
---|
[bee072a] | 655 | r300_dri.so,
|
---|
[d2f50ba] | 656 | r600_dri.so,
|
---|
| 657 | r600_drv_video.so,
|
---|
[b3f053c5] | 658 | radeonsi_dri.so,
|
---|
| 659 | radeonsi_drv_video.so,
|
---|
| 660 | swrast_dri.so,
|
---|
[d2f50ba] | 661 | virtio_gpu_dri.so,
|
---|
[b8b314f5] | 662 | virtio_gpu_drv_video.so,
|
---|
| 663 | vmwgfx_dri.so, and
|
---|
| 664 | zink_dri.so
|
---|
[e4fbb24] | 665 | <!-- End DRI Drivers -->
|
---|
[e929885e] | 666 | </seg>
|
---|
| 667 | <seg>
|
---|
[e4fbb24] | 668 | <!-- Begin VDPAU drivers -->
|
---|
[d2f50ba] | 669 | libvdpau_nouveau.so,
|
---|
| 670 | libvdpau_r600.so, and
|
---|
[b3f053c5] | 671 | libvdpau_radeonsi.so
|
---|
[f7bc172] | 672 | libvdpau_virtio_gpu.so
|
---|
[e4fbb24] | 673 | <!-- End VDPAU drivers -->
|
---|
[ef936e4] | 674 | (Many of these drivers are hard-linked).
|
---|
[eb425b4] | 675 | </seg>
|
---|
[e929885e] | 676 | <seg>
|
---|
| 677 | libvulkan_intel_hasvk.so,
|
---|
| 678 | libvulkan_intel.so,
|
---|
[b8b314f5] | 679 | libvulkan_lvp.so,
|
---|
| 680 | libvulkan_nouveau.so, and
|
---|
[e929885e] | 681 | libvulkan_radeon.so
|
---|
| 682 | </seg>
|
---|
[eb425b4] | 683 | <seg>
|
---|
[869bf46b] | 684 | <!-- $XORG_PREFIX/include/GL is installed by xorg-protos -->
|
---|
| 685 | $XORG_PREFIX/{include/{EGL,GLES,GLES2,GLES3,KHR},
|
---|
[bee072a] | 686 | $XORG_PREFIX/lib/{dri,vdpau}},
|
---|
[d2f50ba] | 687 | $XORG_PREFIX/share/drirc.d (contains workarounds for various applications,
|
---|
[f72bfbe1] | 688 | particularly browsers and games),
|
---|
[e929885e] | 689 | $XORG_PREFIX/share/vulkan,
|
---|
[7b9b069] | 690 | and /usr/share/doc/mesa-&mesa-version;
|
---|
[eb425b4] | 691 | </seg>
|
---|
[868c7c2] | 692 | </seglistitem>
|
---|
| 693 | </segmentedlist>
|
---|
[d3ef1e4] | 694 |
|
---|
[4437f63] | 695 | <variablelist>
|
---|
| 696 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 697 | <?dbfo list-presentation="list"?>
|
---|
| 698 | <?dbhtml list-presentation="table"?>
|
---|
| 699 |
|
---|
| 700 | <varlistentry id="glxgears">
|
---|
[eb50ddde] | 701 | <term><command>glxgears</command></term>
|
---|
[4437f63] | 702 | <listitem>
|
---|
[eb425b4] | 703 | <para>
|
---|
| 704 | is a GL demo useful for troubleshooting graphics
|
---|
[4c24eb0a] | 705 | problems
|
---|
[eb425b4] | 706 | </para>
|
---|
[7a395d1] | 707 | <indexterm zone="mesa glxgears">
|
---|
[4437f63] | 708 | <primary sortas="b-glxgears">glxgears</primary>
|
---|
| 709 | </indexterm>
|
---|
| 710 | </listitem>
|
---|
| 711 | </varlistentry>
|
---|
| 712 |
|
---|
| 713 | <varlistentry id="glxinfo">
|
---|
[eb50ddde] | 714 | <term><command>glxinfo</command></term>
|
---|
[4437f63] | 715 | <listitem>
|
---|
[eb425b4] | 716 | <para>
|
---|
| 717 | is a diagnostic program that displays information about the
|
---|
[4c24eb0a] | 718 | graphics hardware and installed GL libraries
|
---|
[eb425b4] | 719 | </para>
|
---|
[7a395d1] | 720 | <indexterm zone="mesa glxinfo">
|
---|
[4437f63] | 721 | <primary sortas="b-glxinfo">glxinfo</primary>
|
---|
| 722 | </indexterm>
|
---|
| 723 | </listitem>
|
---|
| 724 | </varlistentry>
|
---|
| 725 |
|
---|
[25f6d94] | 726 | <varlistentry id="libEGL">
|
---|
[a07e9eb] | 727 | <term><filename class="libraryfile">libEGL.so</filename></term>
|
---|
[25f6d94] | 728 | <listitem>
|
---|
[eb425b4] | 729 | <para>
|
---|
[a07e9eb] | 730 | provides a native platform graphics interface as
|
---|
[4c24eb0a] | 731 | defined by the EGL-1.4 specification
|
---|
[eb425b4] | 732 | </para>
|
---|
[7a395d1] | 733 | <indexterm zone="mesa libEGL">
|
---|
[25f6d94] | 734 | <primary sortas="c-libGL">libEGL.so</primary>
|
---|
| 735 | </indexterm>
|
---|
| 736 | </listitem>
|
---|
| 737 | </varlistentry>
|
---|
| 738 |
|
---|
[a07e9eb] | 739 | <varlistentry id="libgbm">
|
---|
| 740 | <term><filename class="libraryfile">libgbm.so</filename></term>
|
---|
| 741 | <listitem>
|
---|
| 742 | <para>
|
---|
| 743 | is the <application>Mesa</application> Graphics Buffer
|
---|
[4c24eb0a] | 744 | Manager library
|
---|
[a07e9eb] | 745 | </para>
|
---|
[7a395d1] | 746 | <indexterm zone="mesa libgbm">
|
---|
[a07e9eb] | 747 | <primary sortas="c-libgbm">libgbm.so</primary>
|
---|
| 748 | </indexterm>
|
---|
| 749 | </listitem>
|
---|
| 750 | </varlistentry>
|
---|
| 751 |
|
---|
| 752 | <varlistentry id="libGLESv1_CM">
|
---|
| 753 | <term><filename class="libraryfile">libGLESv1_CM.so</filename></term>
|
---|
| 754 | <listitem>
|
---|
| 755 | <para>
|
---|
[4c24eb0a] | 756 | is the <application>Mesa</application> OpenGL ES 1.1 library
|
---|
[a07e9eb] | 757 | </para>
|
---|
[7a395d1] | 758 | <indexterm zone="mesa libGLESv1_CM">
|
---|
[a07e9eb] | 759 | <primary sortas="c-libGLESv1_CM">libGLESv1_CM.so</primary>
|
---|
| 760 | </indexterm>
|
---|
| 761 | </listitem>
|
---|
| 762 | </varlistentry>
|
---|
| 763 |
|
---|
| 764 | <varlistentry id="libGLES2">
|
---|
| 765 | <term><filename class="libraryfile">libGLES2.so</filename></term>
|
---|
| 766 | <listitem>
|
---|
| 767 | <para>
|
---|
[4c24eb0a] | 768 | is the <application>Mesa</application> OpenGL ES 2.0 library
|
---|
[a07e9eb] | 769 | </para>
|
---|
[7a395d1] | 770 | <indexterm zone="mesa libGLES2">
|
---|
[a07e9eb] | 771 | <primary sortas="c-libGLES2">libGLES2.so</primary>
|
---|
| 772 | </indexterm>
|
---|
| 773 | </listitem>
|
---|
| 774 | </varlistentry>
|
---|
| 775 |
|
---|
[ba2ac60] | 776 | <varlistentry id="libGL">
|
---|
[a07e9eb] | 777 | <term><filename class="libraryfile">libGL.so</filename></term>
|
---|
[ba2ac60] | 778 | <listitem>
|
---|
[eb425b4] | 779 | <para>
|
---|
[4c24eb0a] | 780 | is the main <application>Mesa</application> OpenGL library
|
---|
[eb425b4] | 781 | </para>
|
---|
[7a395d1] | 782 | <indexterm zone="mesa libGL">
|
---|
[ba2ac60] | 783 | <primary sortas="c-libGL">libGL.so</primary>
|
---|
| 784 | </indexterm>
|
---|
| 785 | </listitem>
|
---|
| 786 | </varlistentry>
|
---|
[bee072a] | 787 |
|
---|
[4437f63] | 788 | </variablelist>
|
---|
| 789 |
|
---|
[868c7c2] | 790 | </sect2>
|
---|
[d3ef1e4] | 791 |
|
---|
[868c7c2] | 792 | </sect1>
|
---|