From 06a31dece06792fd70fe2b4353f65df02f13549e Mon Sep 17 00:00:00 2001 From: HazelFZ Date: Mon, 4 Mar 2019 17:43:22 +0800 Subject: [PATCH] Link against libiconv when possible (#372) --- lib/meson.build | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/meson.build b/lib/meson.build index 90ce5a4..e27feab 100644 --- a/lib/meson.build +++ b/lib/meson.build @@ -9,11 +9,15 @@ else libfuse_sources += [ 'mount_bsd.c' ] endif +deps = [ thread_dep ] if cfg.get('HAVE_ICONV') libfuse_sources += [ 'modules/iconv.c' ] + libiconv = cc.find_library('iconv', required: false) + if libiconv.found() + deps += [ libiconv ] + endif endif -deps = [ thread_dep ] libdl = cc.find_library('dl', required: false) if libdl.found() deps += [ libdl ] -- 2.30.2