diff --git a/meson.build b/meson.build index d52bb01bde435b86e87b6690c4256c01bbd40d3a..75311688e90c038afb5840eca9d8421c1ba1e762 100644 --- a/meson.build +++ b/meson.build @@ -1760,7 +1760,11 @@ else found_iconv = true endif if not found_iconv and ['auto', 'external'].contains(iconv_opt) and cc.has_header_symbol('iconv.h', 'iconv_open') - libiconv = [cc.find_library('iconv')] + dirs = [] + if host_system == 'freebsd' + dirs += '/usr/local/lib' + endif + libiconv = [cc.find_library('iconv', dirs: dirs)] found_iconv = true endif @@ -1989,9 +1993,9 @@ endif glib_conf.set('HAVE_PROC_SELF_CMDLINE', have_proc_self_cmdline) -python = import('python').find_installation('python3') # used for '#!/usr/bin/env ' -python_name = 'python3' +python_name = get_option('python_name') +python = import('python').find_installation(python_name) python_version = python.language_version() python_version_req = '>=3.4' diff --git a/meson_options.txt b/meson_options.txt index 2c831e37e31a8dca3e97c9ebccbd1a02946e213f..5229f5dd4c7411ab054be4af5f45ada828991b9c 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -1,3 +1,8 @@ +option('python_name', + type : 'string', + value : 'python3', + description : 'Python name, for FreeBSD may be python3.6') + option('runtime_libdir', type : 'string', value : '',