From af49c1586d8e968633f032243520b949f2a6462c Mon Sep 17 00:00:00 2001 From: Myaamori Date: Tue, 27 Oct 2020 21:50:15 +0000 Subject: [PATCH] meson: use check_header to check for iconv iconv is not a standalone library on Linux, so find_library is pointless --- meson.build | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/meson.build b/meson.build index df03749f8..7abdfa449 100644 --- a/meson.build +++ b/meson.build @@ -50,13 +50,10 @@ cxx = meson.get_compiler('cpp') cc = meson.get_compiler('c') deps += cc.find_library('m', required: false) deps += cc.find_library('dl', required: false) -iconv_dep = cc.find_library('iconv', required: false) -if not iconv_dep.found() and host_machine.system() == 'windows' +if not cxx.check_header('iconv.h') iconv_sp = subproject('iconv') # this really needs to be replaced with a proper port - deps_inc += iconv_sp.get_variable('iconv_incs') - iconv_dep = iconv_sp.get_variable('libiconv_dep') + deps += iconv_sp.get_variable('libiconv_dep') endif -deps += iconv_dep deps += dependency('libass', version: '>=0.9.7', fallback: ['libass', 'libass_dep'])