Fix mismatched param names between Compiler and BasicLinkerIsCompilerMixin

dirc2
Tristan Partin 2 years ago committed by Jussi Pakkanen
parent e05a88835a
commit 5a7427cebb
  1. 12
      mesonbuild/compilers/java.py
  2. 4
      mesonbuild/compilers/mixins/islinker.py

@ -34,13 +34,20 @@ class JavaCompiler(BasicLinkerIsCompilerMixin, Compiler):
language = 'java'
id = 'unknown'
_WARNING_LEVELS: T.Dict[str, T.List[str]] = {
'0': ['-nowarn'],
'1': ['-Xlint:all'],
'2': ['-Xlint:all', '-Xdoclint:all'],
'3': ['-Xlint:all', '-Xdoclint:all'],
}
def __init__(self, exelist: T.List[str], version: str, for_machine: MachineChoice,
info: 'MachineInfo', full_version: T.Optional[str] = None):
super().__init__(exelist, version, for_machine, info, full_version=full_version)
self.javarunner = 'java'
def get_warn_args(self, level: str) -> T.List[str]:
return ['-Xlint:all', '-Xdoclint:all']
return self._WARNING_LEVELS[level]
def get_werror_args(self) -> T.List[str]:
return ['-Werror']
@ -65,9 +72,6 @@ class JavaCompiler(BasicLinkerIsCompilerMixin, Compiler):
def get_buildtype_args(self, buildtype: str) -> T.List[str]:
return java_buildtype_args[buildtype]
def get_depfile_suffix(self) -> str:
return 'd'
def compute_parameters_with_absolute_paths(self, parameter_list: T.List[str],
build_dir: str) -> T.List[str]:
for idx, i in enumerate(parameter_list):

@ -58,7 +58,7 @@ class BasicLinkerIsCompilerMixin(Compiler):
def get_linker_exelist(self) -> T.List[str]:
return self.exelist.copy()
def get_linker_output_args(self, output: str) -> T.List[str]:
def get_linker_output_args(self, outputname: str) -> T.List[str]:
return []
def get_linker_always_args(self) -> T.List[str]:
@ -119,7 +119,7 @@ class BasicLinkerIsCompilerMixin(Compiler):
def get_buildtype_linker_args(self, buildtype: str) -> T.List[str]:
return []
def get_link_debugfile_name(self, target: str) -> str:
def get_link_debugfile_name(self, targetfile: str) -> str:
return ''
def thread_flags(self, env: 'Environment') -> T.List[str]:

Loading…
Cancel
Save