1# 2023 Android Open Source Project 2# Copyright © 2017-2019 Intel Corporation 3# SPDX-License-Identifier: MIT 4 5option( 6 'platforms', 7 type : 'array', 8 value : ['auto'], 9 choices : [ 10 'auto', 'x11', 'wayland', 'haiku', 'android', 'windows', 11 ], 12 description : 'window systems to support. If this is set to `auto`, all ' + 13 'platforms applicable will be enabled.' 14) 15 16option( 17 'egl-native-platform', 18 type : 'combo', 19 value : 'auto', 20 choices : [ 21 'auto', 'x11', 'wayland', 'haiku', 'android', 'windows', 22 'surfaceless', 'drm', 23 ], 24 description : 'the window system EGL assumes for EGL_DEFAULT_DISPLAY', 25) 26 27option( 28 'android-stub', 29 type : 'boolean', 30 value : false, 31 description : 'Build against android-stub', 32) 33 34option( 35 'android-libbacktrace', 36 type : 'feature', 37 description : 'Use Android\'s libbacktrace', 38) 39 40option( 41 'dri3', 42 type : 'feature', 43 deprecated: {'true': 'enabled', 'false': 'disabled'}, 44 description : 'enable support for dri3' 45) 46 47option( 48 'dri-drivers-path', 49 type : 'string', 50 value : '', 51 description : 'Location to install dri drivers. Default: $libdir/dri.' 52) 53 54option( 55 'dri-search-path', 56 type : 'string', 57 value : '', 58 description : 'Locations to search for dri drivers, passed as colon ' + 59 'separated list. Default: dri-drivers-path.' 60) 61 62option( 63 'expat', 64 type : 'feature', 65 value : 'auto', 66 description : 'Controls the use of expat. ' + 67 'Cannot be disabled if xmlconfig is enabled.' 68) 69 70option( 71 'gallium-drivers', 72 type : 'array', 73 value : [], 74 choices : [ 75 'auto', 'kmsro', 'radeonsi', 'r300', 'r600', 'nouveau', 'freedreno', 76 'swrast', 'v3d', 'vc4', 'etnaviv', 'tegra', 'i915', 'svga', 'virgl', 77 'panfrost', 'iris', 'lima', 'zink', 'd3d12', 'asahi', 'crocus', 78 ], 79 description : 'List of gallium drivers to build. If this is set to auto ' + 80 'all drivers applicable to the target OS/architecture ' + 81 'will be built' 82) 83 84option( 85 'gallium-extra-hud', 86 type : 'boolean', 87 value : false, 88 description : 'Enable HUD block/NIC I/O HUD status support', 89) 90 91option( 92 'gallium-vdpau', 93 type : 'feature', 94 deprecated: {'true': 'enabled', 'false': 'disabled'}, 95 description : 'enable gallium vdpau frontend.', 96) 97 98option( 99 'vdpau-libs-path', 100 type : 'string', 101 value : '', 102 description : 'path to put vdpau libraries. defaults to $libdir/vdpau.' 103) 104 105option( 106 'gallium-omx', 107 type : 'combo', 108 value : 'auto', 109 choices : ['auto', 'disabled', 'bellagio', 'tizonia'], 110 description : 'enable gallium omx frontend.', 111) 112 113option( 114 'omx-libs-path', 115 type : 'string', 116 value : '', 117 description : 'path to put omx libraries. defaults to omx-bellagio ' + 118 'pkg-config pluginsdir.' 119) 120 121option( 122 'gallium-va', 123 type : 'feature', 124 deprecated: {'true': 'enabled', 'false': 'disabled'}, 125 description : 'enable gallium va frontend.', 126) 127 128option( 129 'va-libs-path', 130 type : 'string', 131 value : '', 132 description : 'path to put va libraries. defaults to $libdir/dri.' 133) 134 135option( 136 'gallium-xa', 137 type : 'feature', 138 deprecated: {'true': 'enabled', 'false': 'disabled'}, 139 description : 'enable gallium xa frontend.', 140) 141 142option( 143 'gallium-nine', 144 type : 'boolean', 145 value : false, 146 description : 'build gallium "nine" Direct3D 9.x frontend.', 147) 148 149option( 150 'gallium-d3d10umd', 151 type : 'boolean', 152 value : false, 153 description : 'build gallium D3D10 WDDM UMD frontend.', 154) 155 156option( 157 'gallium-opencl', 158 type : 'combo', 159 choices : ['icd', 'standalone', 'disabled'], 160 value : 'disabled', 161 description : 'build gallium "clover" OpenCL frontend.', 162) 163 164option( 165 'gallium-rusticl', 166 type : 'boolean', 167 value : false, 168 description : 'build gallium "rusticl" OpenCL frontend.', 169) 170 171option( 172 'gallium-windows-dll-name', 173 type : 'string', 174 value : 'libgallium_wgl', 175 description : 'name of gallium megadriver DLL built for Windows. ' + 176 'defaults to libgallium_wgl.dll to match DRI', 177) 178 179option( 180 'opencl-spirv', 181 type : 'boolean', 182 value : false, 183 description : 'build gallium "clover" OpenCL frontend with SPIR-V ' + 184 'binary support.', 185) 186 187option( 188 'static-libclc', 189 type : 'array', 190 value : [], 191 choices : ['spirv', 'spirv64', 'all'], 192 description : 'Link libclc SPIR-V statically.', 193) 194 195option( 196 'opencl-external-clang-headers', 197 type : 'feature', 198 description : 'Use system Clang headers at runtime for OpenCL kernel ' + 199 'compilation.', 200) 201 202option( 203 'd3d-drivers-path', 204 type : 'string', 205 value : '', 206 description : 'Location of D3D drivers. Default: $libdir/d3d', 207) 208 209option( 210 'vulkan-drivers', 211 type : 'array', 212 value : ['gfxstream-experimental'], 213 choices : ['auto', 'amd', 'broadcom', 'freedreno', 'intel', 'intel_hasvk', 214 'panfrost', 'swrast', 'virtio', 'imagination-experimental', 215 'microsoft-experimental', 'nouveau-experimental', 'gfxstream-experimental'], 216 description : 'List of vulkan drivers to build. If this is set to auto ' + 217 'all drivers applicable to the target OS/architecture ' + 218 'will be built' 219) 220 221# Note that currently turnip supports msm and kgsl, while the gallium driver 222# support msm and virtio. This is a temporary situation with virtio support 223# for turnip and kgsl support for gallium planned/in-progress. 224option( 225 'freedreno-kmds', 226 type : 'array', 227 value : ['msm'], 228 choices : ['msm', 'kgsl', 'virtio'], 229 description : 'List of kernel-mode drivers to enable for freedreno ' + 230 'gallium and vulkan driver', 231) 232 233option( 234 'imagination-srv', 235 type : 'boolean', 236 value : false, 237 description : 'Enable Services backend for Imagination Technologies ' + 238 'vulkan driver', 239) 240 241option( 242 'shader-cache', 243 type : 'feature', 244 deprecated: {'true': 'enabled', 'false': 'disabled'}, 245 description : 'Build with on-disk shader cache support.', 246) 247 248option( 249 'shader-cache-default', 250 type : 'boolean', 251 value : true, 252 description : 'If set to false, the feature is only activated when ' + 253 'environment variable MESA_SHADER_CACHE_DISABLE is set ' + 254 'to false', 255) 256 257option( 258 'shader-cache-max-size', 259 type : 'string', 260 value : '', 261 description : 'Default value for MESA_SHADER_CACHE_MAX_SIZE enviroment ' + 262 'variable. If set, determines the maximum size of the ' + 263 'on-disk cache of compiled shader programs, can be overriden ' + 264 'by enviroment variable if needed. Should be set to a number ' + 265 'optionally followed by ``K``, ``M``, or ``G`` to specify ' + 266 'a size in kilobytes, megabytes, or gigabytes. By default, ' + 267 'gigabytes will be assumed. And if unset, a maximum size of ' + 268 '1GB will be used.' 269) 270 271option( 272 'vulkan-icd-dir', 273 type : 'string', 274 value : '', 275 description : 'Location relative to prefix to put vulkan icds on install. ' + 276 'Default: $datadir/vulkan/icd.d' 277) 278 279option( 280 'moltenvk-dir', 281 type : 'string', 282 value : '', 283 description : 'Location of the MoltenVk SDK. Default: ' 284) 285 286option( 287 'vulkan-layers', 288 type : 'array', 289 value : [], 290 choices : ['device-select', 'intel-nullhw', 'overlay'], 291 description : 'List of vulkan layers to build' 292) 293 294option( 295 'shared-glapi', 296 type : 'feature', 297 deprecated: {'true': 'enabled', 'false': 'disabled'}, 298 description : 'Whether to build a shared or static glapi. Defaults to ' + 299 'disabled on Windows, enabled elsewhere' 300) 301 302option( 303 'gles1', 304 type : 'feature', 305 deprecated: {'true': 'enabled', 'false': 'disabled'}, 306 description : 'Build support for OpenGL ES 1.x' 307) 308 309option( 310 'gles2', 311 type : 'feature', 312 deprecated: {'true': 'enabled', 'false': 'disabled'}, 313 description : 'Build support for OpenGL ES 2.x and 3.x' 314) 315 316option( 317 'opengl', 318 type : 'boolean', 319 value : false, 320 description : 'Build support for desktop OpenGL' 321) 322 323option( 324 'gbm', 325 type : 'feature', 326 deprecated: {'true': 'enabled', 'false': 'disabled'}, 327 description : 'Build support for gbm platform' 328) 329 330option( 331 'gbm-backends-path', 332 type : 'string', 333 value : '', 334 description : 'Locations to search for gbm backends, passed as colon ' + 335 'separated list. Default: $libdir/gbm.' 336) 337 338option( 339 'glx', 340 type : 'combo', 341 value : 'auto', 342 choices : ['auto', 'disabled', 'dri', 'xlib'], 343 description : 'Build support for GLX platform' 344) 345 346option( 347 'egl', 348 type : 'feature', 349 deprecated: {'true': 'enabled', 'false': 'disabled'}, 350 description : 'Build support for EGL platform' 351) 352 353option( 354 'glvnd', 355 type : 'boolean', 356 value : false, 357 description : 'Enable GLVND support.' 358) 359 360option( 361 'microsoft-clc', 362 type : 'feature', 363 value : 'auto', 364 deprecated: {'true': 'enabled', 'false': 'disabled'}, 365 description : 'Build support for the Microsoft CLC to DXIL compiler' 366) 367 368option( 369 'spirv-to-dxil', 370 type : 'boolean', 371 value : false, 372 description : 'Build support for the SPIR-V to DXIL library' 373) 374 375option( 376 'glvnd-vendor-name', 377 type : 'string', 378 value : 'mesa', 379 description : 'Vendor name string to use for glvnd libraries' 380) 381 382option( 383 'glx-read-only-text', 384 type : 'boolean', 385 value : false, 386 description : 'Disable writable .text section on x86 (decreases performance)' 387) 388 389option( 390 'llvm', 391 type : 'feature', 392 deprecated: {'true': 'enabled', 'false': 'disabled'}, 393 description : 'Build with LLVM support.' 394) 395 396option( 397 'shared-llvm', 398 type : 'feature', 399 deprecated: {'true': 'enabled', 'false': 'disabled'}, 400 description : 'Whether to link LLVM shared or statically.' 401) 402 403option( 404 'draw-use-llvm', 405 type : 'boolean', 406 value : true, 407 description : 'Whether to use LLVM for the Gallium draw module, if LLVM ' + 408 'is included.' 409) 410 411option( 412 'valgrind', 413 type : 'feature', 414 deprecated: {'true': 'enabled', 'false': 'disabled'}, 415 description : 'Build with valgrind support' 416) 417 418option( 419 'libunwind', 420 type : 'feature', 421 deprecated: {'true': 'enabled', 'false': 'disabled'}, 422 description : 'Use libunwind for stack-traces' 423) 424 425option( 426 'lmsensors', 427 type : 'feature', 428 deprecated: {'true': 'enabled', 'false': 'disabled'}, 429 description : 'Enable HUD lmsensors support.' 430) 431 432option( 433 'build-tests', 434 type : 'boolean', 435 value : false, 436 description : 'Build unit tests. Currently this will build *all* unit ' + 437 'tests except the ACO tests, which may build more than expected.' 438) 439 440option( 441 'enable-glcpp-tests', 442 type : 'boolean', 443 value : true, 444 description : 'Build glcpp unit tests. These are flaky on CI.' 445) 446 447option( 448 'build-aco-tests', 449 type : 'boolean', 450 value : false, 451 description : 'Build ACO tests. These require RADV and glslang but not ' + 452 'an AMD GPU.' 453) 454 455option( 456 'install-intel-gpu-tests', 457 type : 'boolean', 458 value : false, 459 description : 'Build and install Intel unit tests which require the GPU. ' + 460 'This option is for developers and the Intel CI system only.' 461) 462 463option( 464 'selinux', 465 type : 'boolean', 466 value : false, 467 description : 'Build an SELinux-aware Mesa. This currently disables ' + 468 'execmem support at runtime unless SELinux is configured ' + 469 'with allow_execmem.' 470) 471 472option( 473 'execmem', 474 type : 'boolean', 475 deprecated : true, 476 description : 'Does nothing, left here for a while to avoid build breakages.', 477) 478 479option( 480 'osmesa', 481 type : 'boolean', 482 value : false, 483 description : 'Build OSmesa.' 484) 485 486option( 487 'tools', 488 type : 'array', 489 value : [], 490 choices : ['drm-shim', 'etnaviv', 'freedreno', 'glsl', 'intel', 'intel-ui', 491 'nir', 'nouveau', 'lima', 'panfrost', 'asahi', 'imagination', 492 'all', 'dlclose-skip'], 493 description : 'List of tools to build. (Note: `intel-ui` selects `intel`)', 494) 495 496option( 497 'power8', 498 type : 'feature', 499 deprecated: {'true': 'enabled', 'false': 'disabled'}, 500 description : 'Enable power8 optimizations.', 501) 502 503option( 504 'xlib-lease', 505 type : 'feature', 506 deprecated: {'true': 'enabled', 'false': 'disabled'}, 507 description : 'Enable VK_EXT_acquire_xlib_display.' 508) 509 510option( 511 'glx-direct', 512 type : 'boolean', 513 value : true, 514 description : 'Enable direct rendering in GLX and EGL for DRI', 515) 516 517option('egl-lib-suffix', 518 type : 'string', 519 value : '', 520 description : 'Suffix to append to EGL library name. Default: none.' 521) 522 523option( 524 'gles-lib-suffix', 525 type : 'string', 526 value : '', 527 description : 'Suffix to append to GLES library names. Default: none.' 528) 529 530option( 531 'platform-sdk-version', 532 type : 'integer', 533 min : 25, 534 max : 10000, 535 value : 25, 536 description : 'Android Platform SDK version. Default: Nougat version.' 537) 538 539option( 540 'allow-kcmp', 541 type : 'feature', 542 deprecated: {'true': 'enabled', 'false': 'disabled'}, 543 description : 'Allow using KCMP_FILE to compare file descriptions. ' + 544 'auto = allowed everywhere except on Android' 545) 546 547option( 548 'zstd', 549 type : 'feature', 550 deprecated: {'true': 'enabled', 'false': 'disabled'}, 551 description : 'Use ZSTD instead of ZLIB in some cases.' 552) 553 554option( 555 'zlib', 556 type : 'feature', 557 deprecated: {'true': 'enabled', 'false': 'disabled'}, 558 value : 'enabled', 559 description : 'Use ZLIB to build driver. Default: enabled' 560) 561 562option( 563 'sse2', 564 type : 'boolean', 565 value : true, 566 description : 'use msse2 flag for x86. Uses sse/sse2 instead of x87. Default: true', 567) 568 569option( 570 'perfetto', 571 type : 'boolean', 572 value : false, 573 description : 'Enable performance analysis with Perfetto. Default: false' 574) 575 576option( 577 'datasources', 578 type : 'array', 579 value : ['auto'], 580 choices : ['auto', 'panfrost', 'intel', 'freedreno'], 581 description : 'List of Perfetto datasources to build. If this is set to ' + 582 '`auto`, datasources that can not be build are skipped. ' + 583 'Default: [`auto`]' 584) 585 586option( 587 'gpuvis', 588 type : 'boolean', 589 value : false, 590 description : 'Enable tracing markers for gpuvis. Default: false' 591) 592 593option( 594 'custom-shader-replacement', 595 type : 'string', 596 value : '', 597 description : 'Enable a custom shader replacement mechanism. Note that ' + 598 'enabling this option requires adding/generating a ' + 599 'shader_replacement.h file that can be included (see ' + 600 'shaderapi.c).' 601) 602 603option( 604 'vmware-mks-stats', 605 type : 'boolean', 606 value : false, 607 description : 'Build gallium VMware/svga driver with mksGuestStats ' + 608 'instrumentation.' 609) 610 611option( 612 'vulkan-beta', 613 type : 'boolean', 614 value : false, 615 description : 'Build vulkan drivers with BETA extensions enabled.' 616) 617 618option( 619 'intel-clc', 620 type : 'combo', 621 deprecated: {'true': 'enabled', 'false': 'disabled'}, 622 value : 'disabled', 623 choices : [ 624 'enabled', 'disabled', 'system', 625 ], 626 description : 'Build the intel-clc compiler (enables Vulkan Intel ' + 627 'Ray Tracing on supported hardware).' 628) 629 630option( 631 'video-codecs', 632 type : 'array', 633 value : [], 634 choices: [ 635 'vc1dec', 'h264dec', 'h264enc', 'h265dec', 'h265enc' 636 ], 637 description : 'List of patent encumbered codecs to build support for. ' + 638 'Distros might want to consult their legal department before ' + 639 'enabling these. This is used for all video APIs (vaapi, ' + 640 'vdpau, vulkan). Non-patent encumbered codecs will be ' + 641 'enabled by default.' 642) 643 644option( 645 'gallium-d3d12-video', 646 type : 'feature', 647 value : 'auto', 648 deprecated: {'true': 'enabled', 'false': 'disabled'}, 649 description : 'build gallium d3d12 with video support.', 650) 651 652option( 653 'radv-build-id', 654 type : 'string', 655 value : '', 656 description : 'Override build id for shader cache keys (hex string). ' + 657 'Can be extracted with readelf -x .note.gnu.build-id' 658) 659 660option( 661 'min-windows-version', 662 type : 'integer', 663 min : 7, 664 max : 11, 665 value : 8, 666 description : 'Minimum Windows version to support. Defaults to Windows 8.' 667) 668 669option( 670 'xmlconfig', 671 type : 'feature', 672 value : 'auto', 673 deprecated: {'true': 'enabled', 'false': 'disabled'}, 674 description : 'Build custom xmlconfig (driconf) support. If disabled, ' + 675 'the default driconf file is hardcoded into Mesa. ' + 676 'Requires expat.' 677) 678 679option ( 680 'intel-xe-kmd', 681 type : 'feature', 682 value : 'disabled', 683 description: 'Enable Intel Xe KMD support.' 684) 685 686option( 687 'nvk-legacy-uapi', 688 type : 'boolean', 689 value : 'false', 690 description : 'Build support for legacy kernel uAPI.' 691) 692 693option( 694 'vk-no-nir', 695 type : 'boolean', 696 value : 'true', 697 description : 'Try to build Mesa Vulkan runtime without NIR' 698) 699 700option( 701 'decoders', 702 type : 'array', 703 value : ['auto'], 704 choices : [ 705 'gles', 706 'vulkan', 707 'magma', 708 'composer', 709 'auto', 710 ], 711 description : 'A list of supported decoders to build' 712) 713option( 714 'log-level', 715 type : 'combo', 716 value : 'error', 717 choices : [ 718 'none', 719 'info', 720 'warn', 721 'error', 722 ], 723 description : 'The logging level of gfxstream' 724) 725option('qnx_target', type : 'string', value : '', description : 'QNX SDP target path') 726option( 727 'gfxstream-build', 728 type : 'combo', 729 value : 'host', 730 choices : [ 731 'both', 732 'guest', 733 'host', 734 'guest-test', 735 ], 736 description : 'Which portions of gfxstream to build' 737) 738