1# Copyright © 2017 Dylan Baker 2 3# Permission is hereby granted, free of charge, to any person obtaining a copy 4# of this software and associated documentation files (the "Software"), to deal 5# in the Software without restriction, including without limitation the rights 6# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7# copies of the Software, and to permit persons to whom the Software is 8# furnished to do so, subject to the following conditions: 9 10# The above copyright notice and this permission notice shall be included in 11# all copies or substantial portions of the Software. 12 13# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 19# SOFTWARE. 20 21files_libnouveau = files( 22 'nouveau_buffer.c', 23 'nouveau_buffer.h', 24 'nouveau_context.h', 25 'nouveau_debug.h', 26 'nouveau_fence.c', 27 'nouveau_fence.h', 28 'nouveau_gldefs.h', 29 'nouveau_heap.c', 30 'nouveau_heap.h', 31 'nouveau_mm.c', 32 'nouveau_mm.h', 33 'nouveau_screen.c', 34 'nouveau_screen.h', 35 'nouveau_statebuf.h', 36 'nouveau_video.c', 37 'nouveau_video.h', 38 'nouveau_vp3_video_bsp.c', 39 'nouveau_vp3_video.c', 40 'nouveau_vp3_video.h', 41 'nouveau_vp3_video_vp.c', 42 'nouveau_winsys.h', 43 'nv17_mpeg.xml.h', 44 'nv31_mpeg.xml.h', 45 'nv_m2mf.xml.h', 46 'nv_object.xml.h', 47 'nv30/nv01_2d.xml.h', 48 'nv30/nv30-40_3d.xml.h', 49 'nv30/nv30_clear.c', 50 'nv30/nv30_context.c', 51 'nv30/nv30_context.h', 52 'nv30/nv30_draw.c', 53 'nv30/nv30_format.c', 54 'nv30/nv30_format.h', 55 'nv30/nv30_fragprog.c', 56 'nv30/nv30_fragtex.c', 57 'nv30/nv30_miptree.c', 58 'nv30/nv30_push.c', 59 'nv30/nv30_query.c', 60 'nv30/nv30_resource.c', 61 'nv30/nv30_resource.h', 62 'nv30/nv30_screen.c', 63 'nv30/nv30_screen.h', 64 'nv30/nv30_state.c', 65 'nv30/nv30_state.h', 66 'nv30/nv30_state_validate.c', 67 'nv30/nv30_texture.c', 68 'nv30/nv30_transfer.c', 69 'nv30/nv30_transfer.h', 70 'nv30/nv30_vbo.c', 71 'nv30/nv30_vertprog.c', 72 'nv30/nv30_vertprog.h', 73 'nv30/nv30_winsys.h', 74 'nv30/nv40_vertprog.h', 75 'nv30/nv40_verttex.c', 76 'nv30/nvfx_fragprog.c', 77 'nv30/nvfx_shader.h', 78 'nv30/nvfx_vertprog.c', 79 'nv50/g80_defs.xml.h', 80 'nv50/g80_texture.xml.h', 81 'nv50/nv50_2d.xml.h', 82 'nv50/nv50_3ddefs.xml.h', 83 'nv50/nv50_3d.xml.h', 84 'nv50/nv50_blit.h', 85 'nv50/nv50_compute.c', 86 'nv50/nv50_compute.xml.h', 87 'nv50/nv50_context.c', 88 'nv50/nv50_context.h', 89 'nv50/nv50_formats.c', 90 'nv50/nv50_miptree.c', 91 'nv50/nv50_program.c', 92 'nv50/nv50_program.h', 93 'nv50/nv50_push.c', 94 'nv50/nv50_query.c', 95 'nv50/nv50_query.h', 96 'nv50/nv50_query_hw.c', 97 'nv50/nv50_query_hw.h', 98 'nv50/nv50_query_hw_metric.c', 99 'nv50/nv50_query_hw_metric.h', 100 'nv50/nv50_query_hw_sm.c', 101 'nv50/nv50_query_hw_sm.h', 102 'nv50/nv50_resource.c', 103 'nv50/nv50_resource.h', 104 'nv50/nv50_screen.c', 105 'nv50/nv50_screen.h', 106 'nv50/nv50_shader_state.c', 107 'nv50/nv50_state.c', 108 'nv50/nv50_stateobj.h', 109 'nv50/nv50_stateobj_tex.h', 110 'nv50/nv50_state_validate.c', 111 'nv50/nv50_surface.c', 112 'nv50/nv50_tex.c', 113 'nv50/nv50_transfer.c', 114 'nv50/nv50_transfer.h', 115 'nv50/nv50_vbo.c', 116 'nv50/nv50_winsys.h', 117 'nv50/nv84_video_bsp.c', 118 'nv50/nv84_video.c', 119 'nv50/nv84_video.h', 120 'nv50/nv84_video_vp.c', 121 'nv50/nv98_video_bsp.c', 122 'nv50/nv98_video.c', 123 'nv50/nv98_video.h', 124 'nv50/nv98_video_ppp.c', 125 'nv50/nv98_video_vp.c', 126 'codegen/nv50_ir.cpp', 127 'codegen/nv50_ir_bb.cpp', 128 'codegen/nv50_ir_build_util.cpp', 129 'codegen/nv50_ir_build_util.h', 130 'codegen/nv50_ir_driver.h', 131 'codegen/nv50_ir_emit_nv50.cpp', 132 'codegen/nv50_ir_from_common.cpp', 133 'codegen/nv50_ir_from_common.h', 134 'codegen/nv50_ir_from_nir.cpp', 135 'codegen/nv50_ir_from_tgsi.cpp', 136 'codegen/nv50_ir_graph.cpp', 137 'codegen/nv50_ir_graph.h', 138 'codegen/nv50_ir.h', 139 'codegen/nv50_ir_inlines.h', 140 'codegen/nv50_ir_lowering_helper.cpp', 141 'codegen/nv50_ir_lowering_helper.h', 142 'codegen/nv50_ir_lowering_nv50.cpp', 143 'codegen/nv50_ir_peephole.cpp', 144 'codegen/nv50_ir_print.cpp', 145 'codegen/nv50_ir_ra.cpp', 146 'codegen/nv50_ir_ssa.cpp', 147 'codegen/nv50_ir_target.cpp', 148 'codegen/nv50_ir_target.h', 149 'codegen/nv50_ir_target_nv50.cpp', 150 'codegen/nv50_ir_target_nv50.h', 151 'codegen/nv50_ir_util.cpp', 152 'codegen/nv50_ir_util.h', 153 'codegen/unordered_set.h', 154 'codegen/nv50_ir_emit_gk110.cpp', 155 'codegen/nv50_ir_emit_gm107.cpp', 156 'codegen/nv50_ir_emit_nvc0.cpp', 157 'codegen/nv50_ir_lowering_gm107.cpp', 158 'codegen/nv50_ir_lowering_gm107.h', 159 'codegen/nv50_ir_lowering_nvc0.cpp', 160 'codegen/nv50_ir_lowering_nvc0.h', 161 'codegen/nv50_ir_target_gm107.cpp', 162 'codegen/nv50_ir_target_gm107.h', 163 'codegen/nv50_ir_target_nvc0.cpp', 164 'codegen/nv50_ir_target_nvc0.h', 165 'nvc0/gm107_texture.xml.h', 166 'nvc0/nvc0_3d.xml.h', 167 'nvc0/nvc0_compute.c', 168 'nvc0/nvc0_compute.xml.h', 169 'nvc0/nvc0_context.c', 170 'nvc0/nvc0_context.h', 171 'nvc0/nvc0_formats.c', 172 'nvc0/nvc0_m2mf.xml.h', 173 'nvc0/nvc0_macros.h', 174 'nvc0/nvc0_miptree.c', 175 'nvc0/nvc0_program.c', 176 'nvc0/nvc0_program.h', 177 'nvc0/nvc0_query.c', 178 'nvc0/nvc0_query.h', 179 'nvc0/nvc0_query_hw.c', 180 'nvc0/nvc0_query_hw.h', 181 'nvc0/nvc0_query_hw_metric.c', 182 'nvc0/nvc0_query_hw_metric.h', 183 'nvc0/nvc0_query_hw_sm.c', 184 'nvc0/nvc0_query_hw_sm.h', 185 'nvc0/nvc0_query_sw.c', 186 'nvc0/nvc0_query_sw.h', 187 'nvc0/nvc0_resource.c', 188 'nvc0/nvc0_resource.h', 189 'nvc0/nvc0_screen.c', 190 'nvc0/nvc0_screen.h', 191 'nvc0/nvc0_shader_state.c', 192 'nvc0/nvc0_state.c', 193 'nvc0/nvc0_stateobj.h', 194 'nvc0/nvc0_state_validate.c', 195 'nvc0/nvc0_surface.c', 196 'nvc0/nvc0_tex.c', 197 'nvc0/nvc0_transfer.c', 198 'nvc0/nvc0_vbo.c', 199 'nvc0/nvc0_vbo_translate.c', 200 'nvc0/nvc0_video_bsp.c', 201 'nvc0/nvc0_video.c', 202 'nvc0/nvc0_video.h', 203 'nvc0/nvc0_video_ppp.c', 204 'nvc0/nvc0_video_vp.c', 205 'nvc0/nvc0_winsys.h', 206 'nvc0/nve4_compute.c', 207 'nvc0/nve4_compute.h', 208 'nvc0/nve4_compute.xml.h', 209 'nvc0/nve4_p2mf.xml.h', 210) 211 212libnouveau = static_library( 213 'nouveau', 214 [files_libnouveau, nir_opcodes_h], 215 include_directories : [ 216 inc_src, inc_include, inc_gallium, inc_gallium_aux, inc_common, 217 ], 218 c_args : [c_vis_args], 219 cpp_args : [cpp_vis_args], 220 dependencies : [dep_libdrm, dep_libdrm_nouveau], 221) 222 223nouveau_compiler = executable( 224 'nouveau_compiler', 225 'nouveau_compiler.c', 226 include_directories : [inc_src, inc_include, inc_gallium, inc_gallium_aux], 227 dependencies : [dep_libdrm, dep_libdrm_nouveau], 228 link_with : [libnouveau, libgallium, libmesa_util, libnir], 229 build_by_default : with_tools.contains('nouveau'), 230 install : with_tools.contains('nouveau'), 231) 232 233driver_nouveau = declare_dependency( 234 compile_args : '-DGALLIUM_NOUVEAU', 235 link_with : [libnouveauwinsys, libnouveau, libnir], 236) 237