• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright © 2017-2019 Intel Corporation
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_libcrocus = files(
22  'gen4_blorp_exec.h',
23  'driinfo_crocus.h',
24  'crocus_batch.c',
25  'crocus_batch.h',
26  'crocus_blit.c',
27  'crocus_bufmgr.c',
28  'crocus_bufmgr.h',
29  'crocus_clear.c',
30  'crocus_context.c',
31  'crocus_context.h',
32  'crocus_draw.c',
33  'crocus_fence.c',
34  'crocus_fence.h',
35  'crocus_fine_fence.c',
36  'crocus_fine_fence.h',
37  'crocus_formats.c',
38  'crocus_genx_macros.h',
39  'crocus_genx_protos.h',
40  'crocus_monitor.c',
41  'crocus_pipe.h',
42  'crocus_pipe_control.c',
43  'crocus_program.c',
44  'crocus_program_cache.c',
45  'crocus_resolve.c',
46  'crocus_resource.c',
47  'crocus_resource.h',
48  'crocus_screen.c',
49  'crocus_screen.h',
50  'crocus_disk_cache.c',
51)
52
53crocus_per_hw_ver_libs = []
54foreach v : ['40', '45', '50', '60', '70', '75', '80']
55  crocus_per_hw_ver_libs += static_library(
56    'crocus_per_hw_ver@0@'.format(v),
57    ['crocus_blorp.c', 'crocus_query.c', 'crocus_state.c', 'crocus_blt.c', gen_xml_pack],
58    include_directories : [inc_include, inc_src, inc_mapi, inc_mesa, inc_gallium, inc_gallium_aux, inc_intel],
59    c_args : [
60      no_override_init_args, c_sse2_args,
61      '-DGFX_VERx10=@0@'.format(v),
62    ],
63    gnu_symbol_visibility : 'hidden',
64    dependencies : [dep_libdrm, dep_valgrind, idep_genxml, idep_nir_headers],
65  )
66endforeach
67
68libcrocus = static_library(
69  'crocus',
70  [files_libcrocus, gen_xml_pack],
71  include_directories : [
72    inc_src, inc_include, inc_gallium, inc_gallium_aux, inc_intel,
73    inc_gallium_drivers,
74    # these should not be necessary, but main/macros.h...
75    inc_mesa, inc_mapi
76  ],
77  c_args : [c_sse2_args],
78  cpp_args : [c_sse2_args],
79  gnu_symbol_visibility : 'hidden',
80  dependencies : [dep_libdrm, dep_valgrind, idep_genxml, idep_libintel_common, idep_nir_headers],
81  link_with : [
82    crocus_per_hw_ver_libs, libintel_compiler, libintel_dev, libisl,
83    libblorp, libintel_perf
84  ],
85)
86
87driver_crocus = declare_dependency(
88  compile_args : '-DGALLIUM_CROCUS',
89  link_with : [libcrocus, libcrocuswinsys],
90)
91