aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/dependencies/misc.py
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@archlinux.org>2022-02-22 17:39:35 -0500
committerDylan Baker <dylan@pnwbakers.com>2022-03-01 12:13:24 -0800
commit140d6aef04ecd4d1d1df49a04d591060b4fb7a7e (patch)
tree494d0e5a873347085c3a47104db8ac3e961eb911 /mesonbuild/dependencies/misc.py
parent23e767176e832768d9c1f8c87efbe2bda69ee1c1 (diff)
downloadmeson-140d6aef04ecd4d1d1df49a04d591060b4fb7a7e.zip
meson-140d6aef04ecd4d1d1df49a04d591060b4fb7a7e.tar.gz
meson-140d6aef04ecd4d1d1df49a04d591060b4fb7a7e.tar.bz2
mark a bunch of dependencies with the version they were introduced
All these dependencies are impossible to find on versions of Meson older than the ones they got custom lookups in, because they don't provide pkg-config files. So they should not / cannot be reasonably used on older versions, and it is easy to say "yep, these should emit a FeatureNew for the versions they got added in".
Diffstat (limited to 'mesonbuild/dependencies/misc.py')
-rw-r--r--mesonbuild/dependencies/misc.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/mesonbuild/dependencies/misc.py b/mesonbuild/dependencies/misc.py
index 9cc549c..41ed5d7 100644
--- a/mesonbuild/dependencies/misc.py
+++ b/mesonbuild/dependencies/misc.py
@@ -63,6 +63,7 @@ def netcdf_factory(env: 'Environment',
class DlBuiltinDependency(BuiltinDependency):
def __init__(self, name: str, env: 'Environment', kwargs: T.Dict[str, T.Any]):
super().__init__(name, env, kwargs)
+ self.feature_since = ('0.62.0', "consider checking for dlopen() with and without find_library('dl')")
if self.clib_compiler.has_function('dlopen', '#include <dlfcn.h>', env)[0]:
self.is_found = True
@@ -71,6 +72,7 @@ class DlBuiltinDependency(BuiltinDependency):
class DlSystemDependency(SystemDependency):
def __init__(self, name: str, env: 'Environment', kwargs: T.Dict[str, T.Any]):
super().__init__(name, env, kwargs)
+ self.feature_since = ('0.62.0', "consider checking for dlopen() with and without find_library('dl')")
h = self.clib_compiler.has_header('dlfcn.h', '', env)
self.link_args = self.clib_compiler.find_library('dl', env, [], self.libtype)
@@ -470,6 +472,7 @@ class CursesSystemDependency(SystemDependency):
class IconvBuiltinDependency(BuiltinDependency):
def __init__(self, name: str, env: 'Environment', kwargs: T.Dict[str, T.Any]):
super().__init__(name, env, kwargs)
+ self.feature_since = ('0.60.0', "consider checking for iconv_open() with and without find_library('iconv')")
code = '''#include <iconv.h>\n\nint main() {\n iconv_open("","");\n}''' # [ignore encoding] this is C, not python, Mr. Lint
if self.clib_compiler.links(code, env)[0]:
@@ -479,6 +482,7 @@ class IconvBuiltinDependency(BuiltinDependency):
class IconvSystemDependency(SystemDependency):
def __init__(self, name: str, env: 'Environment', kwargs: T.Dict[str, T.Any]):
super().__init__(name, env, kwargs)
+ self.feature_since = ('0.60.0', "consider checking for iconv_open() with and without find_library('iconv')")
h = self.clib_compiler.has_header('iconv.h', '', env)
self.link_args = self.clib_compiler.find_library('iconv', env, [], self.libtype)
@@ -490,6 +494,7 @@ class IconvSystemDependency(SystemDependency):
class IntlBuiltinDependency(BuiltinDependency):
def __init__(self, name: str, env: 'Environment', kwargs: T.Dict[str, T.Any]):
super().__init__(name, env, kwargs)
+ self.feature_since = ('0.59.0', "consider checking for ngettext() with and without find_library('intl')")
code = '''#include <libintl.h>\n\nint main() {\n gettext("Hello world");\n}'''
if self.clib_compiler.links(code, env)[0]:
@@ -499,6 +504,7 @@ class IntlBuiltinDependency(BuiltinDependency):
class IntlSystemDependency(SystemDependency):
def __init__(self, name: str, env: 'Environment', kwargs: T.Dict[str, T.Any]):
super().__init__(name, env, kwargs)
+ self.feature_since = ('0.59.0', "consider checking for ngettext() with and without find_library('intl')")
h = self.clib_compiler.has_header('libintl.h', '', env)
self.link_args = self.clib_compiler.find_library('intl', env, [], self.libtype)