1 # Copyright © 2017 Rob Clark
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:
10 # The above copyright notice and this permission notice shall be included in
11 # all copies or substantial portions of the Software.
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
21 ir3_nir_trig_c = custom_target(
23 input : 'ir3/ir3_nir_trig.py',
24 output : 'ir3_nir_trig.c',
25 command : [prog_python2, '@INPUT@', '-p',
26 join_paths(meson.source_root(), 'src/compiler/nir/')],
28 depend_files : nir_algebraic_py,
31 files_libfreedreno = files(
32 'adreno_common.xml.h',
37 'freedreno_batch_cache.c',
38 'freedreno_batch_cache.h',
39 'freedreno_context.c',
40 'freedreno_context.h',
47 'freedreno_program.c',
48 'freedreno_program.h',
51 'freedreno_query_acc.c',
52 'freedreno_query_acc.h',
53 'freedreno_query_hw.c',
54 'freedreno_query_hw.h',
55 'freedreno_query_sw.c',
56 'freedreno_query_sw.h',
57 'freedreno_resource.c',
58 'freedreno_resource.h',
63 'freedreno_surface.c',
64 'freedreno_surface.h',
65 'freedreno_texture.c',
66 'freedreno_texture.h',
73 'a2xx/fd2_compiler.c',
74 'a2xx/fd2_compiler.h',
85 'a2xx/fd2_rasterizer.c',
86 'a2xx/fd2_rasterizer.h',
101 'a3xx/fd3_context.c',
102 'a3xx/fd3_context.h',
111 'a3xx/fd3_program.c',
112 'a3xx/fd3_program.h',
115 'a3xx/fd3_rasterizer.c',
116 'a3xx/fd3_rasterizer.h',
119 'a3xx/fd3_texture.c',
120 'a3xx/fd3_texture.h',
126 'a4xx/fd4_context.c',
127 'a4xx/fd4_context.h',
136 'a4xx/fd4_program.c',
137 'a4xx/fd4_program.h',
140 'a4xx/fd4_rasterizer.c',
141 'a4xx/fd4_rasterizer.h',
144 'a4xx/fd4_texture.c',
145 'a4xx/fd4_texture.h',
151 'a5xx/fd5_compute.c',
152 'a5xx/fd5_compute.h',
153 'a5xx/fd5_context.c',
154 'a5xx/fd5_context.h',
163 'a5xx/fd5_program.c',
164 'a5xx/fd5_program.h',
167 'a5xx/fd5_rasterizer.c',
168 'a5xx/fd5_rasterizer.h',
171 'a5xx/fd5_texture.c',
172 'a5xx/fd5_texture.h',
178 'ir3/ir3_compiler_nir.c',
179 'ir3/ir3_compiler.c',
180 'ir3/ir3_compiler.h',
185 'ir3/ir3_legalize.c',
188 'ir3/ir3_nir_lower_if_else.c',
196 freedreno_includes = [
197 inc_src, inc_include, inc_gallium, inc_gallium_aux, inc_nir,
198 include_directories('ir3')
201 libfreedreno = static_library(
203 [files_libfreedreno, ir3_nir_trig_c],
204 include_directories : freedreno_includes,
205 c_args : [c_vis_args],
206 cpp_args : [cpp_vis_args],
207 dependencies : [dep_libdrm, dep_libdrm_freedreno],
208 build_by_default : false,
211 ir3_compiler = executable(
214 include_directories : freedreno_includes,
215 dependencies : [dep_libdrm, dep_libdrm_freedreno],
216 link_with : [libfreedreno, libgallium, libmesa_util],
217 build_by_default : false,