Skip to content

Commit

Permalink
BUGFIX: environment.py CudaCompiler missing info arg
Browse files Browse the repository at this point in the history
fixes regression for systems with nvcc installed--perhaps why not previously caught on CI.
Just a simple typo--missing a positional argument to CudaCompiler()

0c22798 is the first bad commit File
  "meson\mesonbuild\environment.py", line 1066, in detect_cuda_compiler
    return CudaCompiler(ccache + compiler, version, for_machine, is_cross, exe_wrap, host_compiler=cpp_compiler,
    linker=linker)# Please enter the commit message for your changes. Lines starting
TypeError: __init__() missing 1 required positional argument: 'info'# with '#' will be ignored, and an empty message aborts the commit.
  • Loading branch information
scivision authored and dcbaker committed Oct 10, 2019
1 parent 34ea712 commit 508662f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion mesonbuild/environment.py
Original file line number Diff line number Diff line change
Expand Up @@ -1036,6 +1036,7 @@ def detect_cuda_compiler(self, for_machine):
popen_exceptions = {}
is_cross = not self.machines.matches_build_machine(for_machine)
compilers, ccache, exe_wrap = self._get_compilers('cuda', for_machine)
info = self.machines[for_machine]
for compiler in compilers:
if isinstance(compiler, str):
compiler = [compiler]
Expand Down Expand Up @@ -1065,7 +1066,7 @@ def detect_cuda_compiler(self, for_machine):
version = out.strip().split('V')[-1]
cpp_compiler = self.detect_cpp_compiler(for_machine)
linker = CudaLinker(compiler, for_machine, 'nvlink', CudaCompiler.LINKER_PREFIX, version=CudaLinker.parse_version())
return CudaCompiler(ccache + compiler, version, for_machine, is_cross, exe_wrap, host_compiler=cpp_compiler, linker=linker)
return CudaCompiler(ccache + compiler, version, for_machine, is_cross, exe_wrap, host_compiler=cpp_compiler, info=info, linker=linker)
raise EnvironmentException('Could not find suitable CUDA compiler: "' + ' '.join(compilers) + '"')

def detect_fortran_compiler(self, for_machine: MachineChoice):
Expand Down

0 comments on commit 508662f

Please sign in to comment.