1# ############################################################################# 2# Copyright (c) 2018-present lzutao <taolzu(at)gmail.com> 3# Copyright (c) 2022-present Tristan Partin <tristan(at)partin.io> 4# All rights reserved. 5# 6# This source code is licensed under both the BSD-style license (found in the 7# LICENSE file in the root directory of this source tree) and the GPLv2 (found 8# in the COPYING file in the root directory of this source tree). 9# ############################################################################# 10 11lz4_source_root = '../../../..' 12 13sources = files( 14 lz4_source_root / 'programs/bench.c', 15 lz4_source_root / 'programs/datagen.c', 16 lz4_source_root / 'programs/lz4cli.c', 17 lz4_source_root / 'programs/lz4io.c', 18) 19 20lz4 = executable( 21 'lz4', 22 sources, 23 include_directories: include_directories(lz4_source_root / 'programs'), 24 dependencies: [liblz4_internal_dep], 25 export_dynamic: get_option('debug') and host_machine.system() == 'windows', 26 install: true 27) 28 29install_man(lz4_source_root / 'programs/lz4.1') 30 31if meson.version().version_compare('>=0.61.0') 32 foreach alias : ['lz4c', 'lz4cat', 'unlz4'] 33 install_symlink( 34 alias, 35 install_dir: get_option('bindir'), 36 pointing_to: 'lz4' 37 ) 38 install_symlink( 39 '@0@.1'.format(alias), 40 install_dir: get_option('mandir') / 'man1', 41 pointing_to: 'lz4.1' 42 ) 43 endforeach 44endif 45