[vlc-commits] [Git][videolan/vlc][master] meson: fix iconv detection in contribs
Steve Lhomme (@robUx4)
gitlab at videolan.org
Sat Nov 16 07:26:00 UTC 2024
Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
43908345 by Steve Lhomme at 2024-11-16T07:02:49+00:00
meson: fix iconv detection in contribs
The meson "helper" doesn't check in extra directories and there's no option to do so.
- - - - -
1 changed file:
- meson.build
Changes:
=====================================
meson.build
=====================================
@@ -151,6 +151,14 @@ dl_lib = cc.find_library('dl', required: false)
# iconv library
iconv_dep = dependency('iconv', required: false)
+if not iconv_dep.found()
+ # check in contribs
+ if cc.has_function('iconv_open', prefix: vlc_conf_prefix + '#include <iconv.h>',
+ dependencies: [contrib_dep, cc.find_library('iconv', dirs: contrib_libdir)])
+ iconv_dep = declare_dependency(
+ dependencies: [contrib_dep, cc.find_library('iconv', dirs: contrib_libdir)])
+ endif
+endif
iconv_const_test = '''
#include <stddef.h>
#include <iconv.h>
@@ -163,7 +171,7 @@ if iconv_dep.found()
cdata.set('HAVE_ICONV', 1)
# Check if iconv() prototype uses const
- if cc.compiles(iconv_const_test, name: 'Test iconv() for const-using prototype')
+ if cc.compiles(iconv_const_test, name: 'Test iconv() for const-using prototype', dependencies: iconv_dep)
cdata.set('ICONV_CONST', 'const')
else
cdata.set('ICONV_CONST', '')
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/4390834515cc4308a6a7f00c2e2fcf66cb714512
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/4390834515cc4308a6a7f00c2e2fcf66cb714512
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list