The problem is that the executable file suffix is .exe
, while running on Linux. A quick and easy fix is to simply change the suffix to .bin
, for example:
exe = executable(
'main.bin', # Do not use .exe here
'main.cu',
link_args: '-fopenmp',
cuda_args: '-Xcompiler=-fopenmp',
)
test('simple_run', exe)
Should run perfectly well. The decision to try running an .exe
file with mono
while on Linux, comes from this exact line in meson.