foot/terminfo/meson.build
Daniel Eklöf 770bd79a9c meson: try to workaround 'tic' writing multiple files into a subdirectory
tic writes all our terminfo files into a subdirectory. This is
difficult for meson to groc; you can for example not say

  output: ['f/foot', 'f/foot-direct']

This tries to workaround it by setting 'install: false' in the 'tic'
custom target, and instead add two separate targets for each terminfo
file.

Since the compiled terminfo file 'foot' would collide with the
executable 'foot', all terminfo stuff has been moved into a
subdirectory.
2020-05-03 17:48:40 +02:00

19 lines
593 B
Meson

tic = find_program('tic', native: true)
tic_generated = custom_target(
'terminfo',
output: 'f',
input: 'foot.info',
command: [tic, '-x', '-o', '@OUTDIR@', '-e', 'foot,foot-direct', '@INPUT@'],
install: false,
install_dir: join_paths(get_option('datadir'), 'terminfo'))
foreach terminfo : ['foot', 'foot-direct']
custom_target(
'terminfo-@0@'.format(terminfo),
output: terminfo,
input: tic_generated,
command: ['cp', join_paths('@INPUT@', terminfo), '@OUTPUT@'],
install: true,
install_dir: join_paths(get_option('datadir'), 'terminfo', 'f'))
endforeach