From a904939a43bf43289345321da68b743e0d9ea804 Mon Sep 17 00:00:00 2001 From: Rasmus Thomsen Date: Tue, 19 May 2020 10:11:49 +0200 Subject: build: allow building without help in meson --- src/meson.build | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) (limited to 'src/meson.build') diff --git a/src/meson.build b/src/meson.build index 972e4b4..07beac7 100644 --- a/src/meson.build +++ b/src/meson.build @@ -54,15 +54,24 @@ apk_src = [ 'help.c', ] -genhelp_script = find_program('genhelp.lua') +if lua_bin.found() + genhelp_script = find_program('genhelp.lua') -generated_help = custom_target( - 'help.h', - capture: true, - output: 'help.h', - input: man_files, - command: [genhelp_script, '@INPUT@'], -) + generated_help = custom_target( + 'help.h', + capture: true, + output: 'help.h', + input: man_files, + command: [genhelp_script, '@INPUT@'], + ) +else + generated_help = custom_target( + 'help.h', + capture: true, + output: 'help.h', + command: ['echo', '#define NO_HELP'], + ) +endif apk_src += [ generated_help ] -- cgit v1.2.3-70-g09d2