1# Copyright © 2017 Dylan Baker 2# Copyright © 2017-2018 Intel Corporation 3 4# Permission is hereby granted, free of charge, to any person obtaining a copy 5# of this software and associated documentation files (the "Software"), to deal 6# in the Software without restriction, including without limitation the rights 7# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8# copies of the Software, and to permit persons to whom the Software is 9# furnished to do so, subject to the following conditions: 10 11# The above copyright notice and this permission notice shall be included in 12# all copies or substantial portions of the Software. 13 14# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 20# SOFTWARE. 21 22inc_gallium_drivers = include_directories('drivers') 23inc_gallium_winsys = include_directories('winsys') 24inc_gallium_winsys_sw = include_directories('winsys/sw') 25 26subdir('auxiliary') 27subdir('auxiliary/pipe-loader') 28subdir('winsys/sw/null') 29if with_dri 30 subdir('winsys/sw/dri') 31else 32 libswdri = [] 33endif 34if with_gallium_drisw_kms 35 subdir('winsys/sw/kms-dri') 36else 37 libswkmsdri = [] 38endif 39if with_platform_windows 40 subdir('winsys/sw/gdi') 41else 42 libwsgdi = null_dep 43endif 44subdir('winsys/sw/wrapper') 45if with_platform_haiku 46 subdir('winsys/sw/hgl') 47endif 48if with_gallium_softpipe 49 subdir('drivers/softpipe') 50 if draw_with_llvm 51 subdir('drivers/llvmpipe') 52 endif 53else 54 driver_swrast = declare_dependency() 55endif 56if with_gallium_asahi 57 subdir('drivers/asahi') 58else 59 driver_asahi = declare_dependency() 60endif 61if with_gallium_r300 or with_gallium_radeonsi or with_gallium_r600 62 subdir('winsys/radeon/drm') 63endif 64if with_gallium_r300 65 subdir('drivers/r300') 66else 67 driver_r300 = declare_dependency() 68endif 69if with_gallium_r600 70 subdir('drivers/r600') 71else 72 driver_r600 = declare_dependency() 73endif 74if with_gallium_radeonsi 75 subdir('winsys/amdgpu/drm') 76 subdir('drivers/radeonsi') 77else 78 driver_radeonsi = declare_dependency() 79endif 80if with_gallium_nouveau 81 subdir('winsys/nouveau/drm') 82 subdir('drivers/nouveau') 83else 84 driver_nouveau = declare_dependency() 85endif 86if with_gallium_freedreno 87 subdir('winsys/freedreno/drm') 88 subdir('drivers/freedreno') 89else 90 driver_freedreno = declare_dependency() 91endif 92if with_gallium_vc4 93 subdir('winsys/vc4/drm') 94 subdir('drivers/vc4') 95else 96 driver_vc4 = declare_dependency() 97endif 98if with_gallium_panfrost 99 subdir('winsys/panfrost/drm') 100 subdir('drivers/panfrost') 101else 102 driver_panfrost = declare_dependency() 103endif 104if with_gallium_etnaviv 105 subdir('winsys/etnaviv/drm') 106 subdir('drivers/etnaviv') 107else 108 driver_etnaviv = declare_dependency() 109endif 110if with_gallium_kmsro 111 subdir('winsys/kmsro/drm') 112else 113 driver_kmsro = declare_dependency() 114endif 115if with_gallium_v3d 116 subdir('winsys/v3d/drm') 117 subdir('drivers/v3d') 118else 119 driver_v3d = declare_dependency() 120endif 121if with_gallium_tegra 122 subdir('winsys/tegra/drm') 123 subdir('drivers/tegra') 124else 125 driver_tegra = declare_dependency() 126endif 127if with_gallium_crocus 128 subdir('winsys/crocus/drm') 129 subdir('drivers/crocus') 130else 131 driver_crocus = declare_dependency() 132endif 133if with_gallium_iris 134 subdir('winsys/iris/drm') 135 subdir('drivers/iris') 136else 137 driver_iris = declare_dependency() 138endif 139if with_gallium_i915 140 subdir('winsys/i915/drm') 141 subdir('drivers/i915') 142else 143 driver_i915 = declare_dependency() 144endif 145if with_gallium_svga 146 if not with_platform_windows 147 subdir('winsys/svga/drm') 148 endif 149 subdir('drivers/svga') 150else 151 driver_svga = declare_dependency() 152endif 153if with_gallium_virgl 154 subdir('winsys/virgl/common') 155 subdir('winsys/virgl/drm') 156 subdir('winsys/virgl/vtest') 157 subdir('drivers/virgl') 158else 159 driver_virgl = declare_dependency() 160endif 161if with_gallium_lima 162 subdir('winsys/lima/drm') 163 subdir('drivers/lima') 164else 165 driver_lima = declare_dependency() 166endif 167if with_gallium_zink 168 subdir('drivers/zink') 169else 170 driver_zink = declare_dependency() 171endif 172if with_gallium_d3d12 173 subdir('drivers/d3d12') 174else 175 driver_d3d12 = declare_dependency() 176endif 177if with_gallium_opencl 178 # TODO: this isn't really clover specific, but ATM clover is the only 179 # consumer 180 subdir('targets/pipe-loader') 181 182 subdir('frontends/clover') 183 subdir('targets/opencl') 184endif 185if with_dri 186 subdir('frontends/dri') 187 subdir('targets/dri') 188endif 189if with_osmesa 190 subdir('frontends/osmesa') 191 subdir('targets/osmesa') 192endif 193if with_glx == 'xlib' 194 subdir('winsys/sw/xlib') 195 subdir('frontends/glx/xlib') 196 subdir('targets/libgl-xlib') 197endif 198if with_gallium_vdpau 199 subdir('frontends/vdpau') 200 subdir('targets/vdpau') 201endif 202if with_gallium_xvmc 203 subdir('frontends/xvmc') 204 subdir('targets/xvmc') 205endif 206if with_gallium_omx != 'disabled' 207 subdir('frontends/omx') 208 subdir('targets/omx') 209endif 210if with_gallium_va 211 subdir('frontends/va') 212 subdir('targets/va') 213endif 214if with_gallium_xa 215 subdir('frontends/xa') 216 subdir('targets/xa') 217endif 218if with_platform_haiku 219 subdir('frontends/hgl') 220 subdir('targets/haiku-softpipe') 221endif 222if with_gallium_st_nine 223 subdir('frontends/nine') 224 subdir('targets/d3dadapter9') 225endif 226if with_gallium_st_d3d10umd 227 subdir('frontends/d3d10umd') 228 subdir('targets/d3d10sw') 229endif 230if with_platform_windows 231 subdir('frontends/wgl') 232 if with_gallium_d3d12 233 subdir('winsys/d3d12/wgl') 234 subdir('targets/libgl-d3d12') 235 else 236 winsys_d3d12_wgl = declare_dependency() 237 endif 238 subdir('targets/wgl') 239 subdir('targets/libgl-gdi') 240endif 241if with_tests 242 subdir('targets/graw-null') 243 if with_platform_windows 244 subdir('targets/graw-gdi') 245 elif with_glx == 'gallium-xlib' 246 subdir('targets/graw-xlib') 247 endif 248 subdir('tests') 249endif 250if with_swrast_vk 251 subdir('frontends/lavapipe') 252 subdir('targets/lavapipe') 253endif 254