freedreno/afuc: Install asm/disasm
[mesa.git] / src / freedreno / afuc / meson.build
1 # Copyright © 2020 Google, Inc
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
21 afuc_parser = custom_target(
22 'parser.[ch]',
23 input: 'parser.y',
24 output: ['parser.c', 'parser.h'],
25 command: [
26 prog_bison, '@INPUT@', '--defines=@OUTPUT1@', '--output=@OUTPUT0@'
27 ]
28 )
29
30 afuc_lexer = custom_target(
31 'lexer.c',
32 input: 'lexer.l',
33 output: 'lexer.c',
34 command: [
35 prog_flex, '-o', '@OUTPUT@', '@INPUT@'
36 ]
37 )
38
39 asm = executable(
40 'afuc-asm',
41 [
42 'asm.c',
43 afuc_lexer,
44 afuc_parser,
45 ],
46 include_directories: [
47 inc_freedreno_rnn,
48 ],
49 link_with: [
50 libfreedreno_rnn,
51 ],
52 dependencies: [],
53 build_by_default : with_tools.contains('freedreno'),
54 install: install_fd_decode_tools,
55 )
56
57 disasm = executable(
58 'afuc-disasm',
59 'disasm.c',
60 include_directories: [
61 inc_freedreno_rnn,
62 ],
63 link_with: [
64 libfreedreno_rnn,
65 ],
66 dependencies: [],
67 build_by_default : with_tools.contains('freedreno'),
68 install: install_fd_decode_tools,
69 )