From be94747ea36d7ec0a2747744d3006d8fe0d42a60 Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Mon, 3 Aug 2020 11:56:45 +0200
Subject: Fix include path for boost


diff --git a/mesonbuild/dependencies/boost.py b/mesonbuild/dependencies/boost.py
index aadf3f8..f2bf548 100644
--- a/mesonbuild/dependencies/boost.py
+++ b/mesonbuild/dependencies/boost.py
@@ -518,10 +518,11 @@ class BoostDependency(SystemDependency):
 
     def detect_inc_dirs(self, root: Path) -> T.List[BoostIncludeDir]:
         candidates = []  # type: T.List[Path]
-        inc_root = root / 'include'
+        inc_root = root / 'headers'
 
         candidates += [root / 'boost']
         candidates += [inc_root / 'boost']
+        candidates += [inc_root / 'x86' / 'boost']
         if inc_root.is_dir():
             for i in inc_root.iterdir():
                 if not i.is_dir() or not i.name.startswith('boost-'):
-- 
2.30.2


From 6081acef2fe915a8b05b7d9f30f05554bba0861f Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Fri, 26 Nov 2021 11:39:48 +0100
Subject: add support for gcc 2.95.3


diff --git a/mesonbuild/compilers/detect.py b/mesonbuild/compilers/detect.py
index 03c5226..f39c919 100644
--- a/mesonbuild/compilers/detect.py
+++ b/mesonbuild/compilers/detect.py
@@ -415,7 +415,7 @@ def _detect_c_or_cpp_compiler(env: 'Environment', lang: str, for_machine: Machin
         version = search_version(out)
 
         guess_gcc_or_lcc: T.Optional[str] = None
-        if 'Free Software Foundation' in out or 'xt-' in out:
+        if 'Free Software Foundation' in out or 'xt-' in out or '2.95.3' in out:
             guess_gcc_or_lcc = 'gcc'
         if 'e2k' in out and 'lcc' in out:
             guess_gcc_or_lcc = 'lcc'
diff --git a/mesonbuild/compilers/mixins/gnu.py b/mesonbuild/compilers/mixins/gnu.py
index bc40af4..923a8ef 100644
--- a/mesonbuild/compilers/mixins/gnu.py
+++ b/mesonbuild/compilers/mixins/gnu.py
@@ -280,7 +280,7 @@ class GnuLikeCompiler(Compiler, metaclass=abc.ABCMeta):
         stdo = self._get_search_dirs(env)
         for line in stdo.split('\n'):
             if line.startswith(name + ':'):
-                return self._split_fetch_real_dirs(line.split('=', 1)[1])
+                return self._split_fetch_real_dirs(line.split('=', 1)[1] if '=' in line else line)
         return []
 
     def get_lto_compile_args(self, *, threads: int = 0, mode: str = 'default') -> T.List[str]:
@@ -396,3 +396,13 @@ class GnuCompiler(GnuLikeCompiler):
         elif threads > 0:
             return [f'-flto={threads}']
         return super().get_lto_compile_args(threads=threads)
+
+    def gnu_symbol_visibility_args(self, vistype: str) -> T.List[str]:
+        if mesonlib.version_compare(self.version, '< 4'):
+            vistype = ''
+        return super().gnu_symbol_visibility_args(vistype)
+
+    def get_dependency_gen_args(self, outtarget: str, outfile: str) -> T.List[str]:
+        if mesonlib.version_compare(self.version, '< 4'):
+            return []
+        return super().get_dependency_gen_args(outtarget, outfile)
-- 
2.30.2


