build: Add option to specify path to perl binary

This commit is contained in:
Rainer Müller 2018-03-23 01:36:35 +01:00 committed by TingPing
parent ee85129a9b
commit ed6f544572
4 changed files with 5 additions and 5 deletions

View File

@ -90,7 +90,7 @@ if get_option('with-plugin')
]
endif
if get_option('with-perl')
if get_option('with-perl') != 'false'
plugin_metainfo += [
['Perl', 'Provides a scripting interface in Perl', 'GPL-2.0+']
]

View File

@ -42,8 +42,8 @@ option('with-fishlim', type: 'boolean',
option('with-lua', type: 'string', value: 'luajit',
description: 'Lua scripting plugin, value is pkg-config name to use or "false"'
)
option('with-perl', type: 'boolean',
description: 'Perl scripting plugin'
option('with-perl', type: 'string', value: 'perl',
description: 'Perl scripting plugin, value is path to perl executable or "false"'
)
option('with-python', type: 'string', value: 'python3',
description: 'Python scripting plugin. value is pkg-config name to use or "false"'

View File

@ -26,7 +26,7 @@ if get_option('with-lua') != 'false'
subdir('lua')
endif
if get_option('with-perl')
if get_option('with-perl') != 'false'
subdir('perl')
endif

View File

@ -25,7 +25,7 @@ if get_option('with-perl-legacy-api')
perl_cflags += '-DOLD_PERL'
endif
perl = find_program('perl')
perl = find_program(get_option('with-perl'))
ret = run_command([perl, '-MExtUtils::Embed', '-e', 'ccopts'])
if ret.returncode() != 0