summaryrefslogtreecommitdiff
path: root/mesonbuild/linkers
diff options
context:
space:
mode:
authorLiza Chevalier <lizalc@pm.me>2025-10-29 11:17:00 -0500
committerDylan Baker <dylan@pnwbakers.com>2025-10-29 12:35:55 -0700
commitba860d72a96932608bb2b13a2f32ebda0087905a (patch)
treed40fb1da7ea242673c6f7896c70be6ed12d6416e /mesonbuild/linkers
parente9d255de1580235fff96e110001ce4293006caaa (diff)
downloadmeson-ba860d72a96932608bb2b13a2f32ebda0087905a.tar.gz
compilers: add Microchip XC32 compiler
The Microchip XC32 compiler is a GCC-based compiler implemented using existing GNU compiler classes. As the XC32 version and GCC version do not match mixins have been implemented to override versions used in versions checks where applicable.
Diffstat (limited to 'mesonbuild/linkers')
-rw-r--r--mesonbuild/linkers/linkers.py28
1 files changed, 28 insertions, 0 deletions
diff --git a/mesonbuild/linkers/linkers.py b/mesonbuild/linkers/linkers.py
index a905f0667..461bcc279 100644
--- a/mesonbuild/linkers/linkers.py
+++ b/mesonbuild/linkers/linkers.py
@@ -479,6 +479,14 @@ class Xc16Linker(StaticLinker):
def get_linker_always_args(self) -> T.List[str]:
return ['rcs']
+
+class Xc32ArLinker(ArLinker):
+
+ """Static linker for Microchip XC32 compiler."""
+
+ id = 'xc32-ar'
+
+
class CompCertLinker(StaticLinker):
def __init__(self, exelist: T.List[str]):
@@ -1112,6 +1120,26 @@ class Xc16DynamicLinker(DynamicLinker):
target: BuildTarget, extra_paths: T.Optional[T.List[str]] = None) -> T.Tuple[T.List[str], T.Set[bytes]]:
return ([], set())
+
+class Xc32DynamicLinker(GnuDynamicLinker):
+
+ """Linker for Microchip XC32 compiler."""
+
+ id = 'ld.xc32'
+
+ def sanitizer_args(self, value: T.List[str]) -> T.List[str]:
+ return []
+
+ def get_coverage_args(self) -> T.List[str]:
+ return DynamicLinker.get_coverage_args(self)
+
+ def get_pie_args(self) -> T.List[str]:
+ return DynamicLinker.get_pie_args(self)
+
+ def thread_flags(self, env: Environment) -> T.List[str]:
+ return []
+
+
class CompCertDynamicLinker(DynamicLinker):
"""Linker for CompCert C compiler."""