From 4a2a933478d0d5b8ab4bae67aded099298fa3d7b Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Mon, 22 Apr 2024 11:08:26 -0500 Subject: [PATCH] meson: Add build-scriptlive option Signed-off-by: Jordan Williams (cherry picked from commit 8f6efe8cb65498e9586a7217aac77f25068f770b) --- meson.build | 12 ++++++++---- meson_options.txt | 2 ++ 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/meson.build b/meson.build index e61e88f69..0a2f0622e 100644 --- a/meson.build +++ b/meson.build @@ -2491,6 +2491,7 @@ if opt and not is_disabler(exe) exes += exe endif +opt = get_option('build-scriptlive').require(have_pty).allowed() exe = executable( 'scriptlive', scriptlive_sources, @@ -2500,10 +2501,13 @@ exe = executable( realtime_libs, math_libs], install_dir : usrbin_exec_dir, - install : true) -exes += exe -manadocs += ['term-utils/scriptlive.1.adoc'] -bashcompletions += ['scriptlive'] + install : opt, + build_by_default : opt) +if opt and not is_disabler(exe) + exes += exe + manadocs += ['term-utils/scriptlive.1.adoc'] + bashcompletions += ['scriptlive'] +endif exe = executable( 'scriptreplay', diff --git a/meson_options.txt b/meson_options.txt index 65b43fdb6..77da35d99 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -71,6 +71,8 @@ option('build-partx', type : 'feature', description : 'build addpart, delpart, partx') option('build-script', type : 'feature', description : 'build script') +option('build-scriptlive', type : 'feature', + description : 'build scriptlive') option('build-uuidd', type : 'feature', description : 'build the uuid daemon') -- 2.47.3