Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can not find meson executable in Python 3.10, meson 0.62.1 #1

Closed
Nic30 opened this issue Jun 6, 2022 · 2 comments
Closed

Can not find meson executable in Python 3.10, meson 0.62.1 #1

Nic30 opened this issue Jun 6, 2022 · 2 comments

Comments

@Nic30
Copy link

Nic30 commented Jun 6, 2022

I am not sure when this stopped working but with latest meson and python there see to be some issue and meson executable does not seem to be in path.
Maybe we can import meson and execute it directly instead of relying on its executable?

[build-system]
requires = [
   "wheel",
   "meson>=0.62.1",
   "mesonpep517",
   "pybind11>=2.8.1",
   "ninja",
]
build-backend = "mesonpep517.buildapi"

Full pyproject.toml: https:/Nic30/hwtHls/blob/llvm_mir_integration/pyproject.toml

Processing /root/project
  Installing build dependencies ... -� �\� �|� �/� �-� �\� �done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... -� �\� �|� �/� �-� �\� �|� �/� �-� �\� �|� �/� �done
  Preparing metadata (pyproject.toml) ... -� �error
  error: subprocess-exited-with-error
  
  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [22 lines of output]
      Traceback (most recent call last):
        File "/usr/lib/python3/dist-packages/pip/_vendor/pep517/in_process/_in_process.py", line 363, in <module>
          main()
        File "/usr/lib/python3/dist-packages/pip/_vendor/pep517/in_process/_in_process.py", line 345, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
        File "/usr/lib/python3/dist-packages/pip/_vendor/pep517/in_process/_in_process.py", line 164, in prepare_metadata_for_build_wheel
          return hook(metadata_directory, config_settings)
        File "/tmp/pip-build-env-3ri6jxdy/overlay/local/lib/python3.10/dist-packages/mesonpep517/buildapi.py", line 269, in prepare_metadata_for_build_wheel
          meson_configure(builddir, config_settings=config_settings)
        File "/tmp/pip-build-env-3ri6jxdy/overlay/local/lib/python3.10/dist-packages/mesonpep517/buildapi.py", line 51, in meson_configure
          meson(*args, builddir=args[0], config_settings=config_settings)
        File "/tmp/pip-build-env-3ri6jxdy/overlay/local/lib/python3.10/dist-packages/mesonpep517/buildapi.py", line 25, in meson
          return subprocess.check_output(['meson'] + list(args))
        File "/usr/lib/python3.10/subprocess.py", line 420, in check_output
          return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
        File "/usr/lib/python3.10/subprocess.py", line 501, in run
          with Popen(*popenargs, **kwargs) as process:
        File "/usr/lib/python3.10/subprocess.py", line 966, in __init__
          self._execute_child(args, executable, preexec_fn, close_fds,
        File "/usr/lib/python3.10/subprocess.py", line 1842, in _execute_child
          raise child_exception_type(errno_num, err_msg, err_filename)
      FileNotFoundError: [Errno 2] No such file or directory: 'meson'
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.


Exited with code exit status 1

Full log: https://app.circleci.com/pipelines/github/Nic30/hwtHls/195/workflows/50629ae8-6a92-4310-b7bf-a9a0fc5dd959/jobs/201

@jeandet
Copy link
Owner

jeandet commented Jun 6, 2022

hello @Nic30, I'm really sorry but I'm neither the author of this package nor this is the official repo. I forked it from https://gitlab.com/thiblahute/mesonpep517 mostly to solve a build issue on Windows.
That said your issue looks really weird to me, could it be related to the latest Meson release? Not sure I can help much more.
Note also that there is this package https:/FFY00/meson-python which seems to be more actively maintained than mesonpep517.

@Nic30
Copy link
Author

Nic30 commented Jun 7, 2022

@jeandet thank you for your response. I was thinking that this is official repo.

could it be related to the latest Meson release?

Currently I do not know but I guess it is somehow related to new pip I think that the environment is just not propagated to subprocess but I do not know exactly how pep517 work. But there seems to be fix for this issue in pull requests https://gitlab.com/thiblahute/mesonpep517/-/merge_requests/18

Closing this issue as I opened it in wrong repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants