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

Failure to build on fresh ArchLinux #119

Open
appetrosyan opened this issue Mar 5, 2024 · 2 comments
Open

Failure to build on fresh ArchLinux #119

appetrosyan opened this issue Mar 5, 2024 · 2 comments

Comments

@appetrosyan
Copy link
Contributor

appetrosyan commented Mar 5, 2024

Given that the AUR package has a missing MPI dependency I tried installing PolyChord in a fresh venv today. I don't think this has been reported yet, so odds are I'll close this issue myself, but leave it in, so if anyone later comes across it, they know how to fix it.

Here's the output of the build commmand:

× Building wheel for pypolychord (pyproject.toml) did not run successfully. │ exit code: 1 ╰─> [73 lines of output] running bdist_wheel running build running build_py make -C /tmp/pip-req-build-h_v66dsl/src/polychord /tmp/pip-req-build-h_v66dsl/lib/libchord.so make[1]: Entering directory '/tmp/pip-req-build-h_v66dsl/src/polychord' mpifort -ffree-line-length-none -cpp -fPIC -fno-stack-arrays -fallow-argument-mismatch -Ofast -DMPI -c utils.F90 [antares:111791] Error: Unable to get the user home directory [antares:111791] Error: Unable to get the user home directory -------------------------------------------------------------------------- It looks like opal_init failed for some reason; your parallel process is likely to abort. There are many reasons that a parallel process can fail during opal_init; some of which are due to configuration or environment problems. This failure appears to be an internal failure; here's some additional information (which may only be relevant to an Open MPI developer):
    mca_base_var_init failed
    --> Returned value -1 instead of OPAL_SUCCESS
  --------------------------------------------------------------------------
  make[1]: *** [Makefile:22: utils.o] Error 255
  make[1]: Leaving directory '/tmp/pip-req-build-h_v66dsl/src/polychord'
  make: *** [Makefile:80: /tmp/pip-req-build-h_v66dsl/lib/libchord.so] Error 2
  Traceback (most recent call last):
    File "/home/app/Git/sspr/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
      main()
    File "/home/app/Git/sspr/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
      json_out['return_val'] = hook(**hook_input['kwargs'])
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/home/app/Git/sspr/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 251, in build_wheel
      return _build_backend().build_wheel(wheel_directory, config_settings,
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 410, in build_wheel
      return self._build_with_temp_dir(
             ^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 395, in _build_with_temp_dir
      self.run_setup()
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 311, in run_setup
      exec(code, locals())
    File "<string>", line 125, in <module>
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/__init__.py", line 103, in setup
      return distutils.core.setup(**attrs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 185, in setup
      return run_commands(dist)
             ^^^^^^^^^^^^^^^^^^
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
      dist.run_commands()
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
      self.run_command(cmd)
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/dist.py", line 963, in run_command
      super().run_command(command)
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
      cmd_obj.run()
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/wheel/bdist_wheel.py", line 368, in run
      self.run_command("build")
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
      self.distribution.run_command(command)
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/dist.py", line 963, in run_command
      super().run_command(command)
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
      cmd_obj.run()
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/command/build.py", line 131, in run
      self.run_command(cmd_name)
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/cmd.py", line 318, in run_command
      self.distribution.run_command(command)
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/dist.py", line 963, in run_command
      super().run_command(command)
    File "/tmp/pip-build-env-v_ov0wk6/overlay/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
      cmd_obj.run()
    File "<string>", line 97, in run
    File "/usr/lib/python3.11/subprocess.py", line 413, in check_call
      raise CalledProcessError(retcode, cmd)
  subprocess.CalledProcessError: Command '['make', '-e', 'libchord.so']' returned non-zero exit status 2.
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pypolychord
Failed to build pypolychord
ERROR: Could not build wheels for pypolychord, which is required to install pyproject.toml-based projects

This is running on a fresh pip virtual environment on an up to date version of Arch Linux with the pypolychord AUR package installed (i.e. it can be built).

@appetrosyan
Copy link
Contributor Author

This is the same result as if I run

pip install git+https://github.com/PolyChord/PolyChordLite@master --break-system-packages

Outside the venv.

@appetrosyan
Copy link
Contributor Author

It doesn't fail if you clone, and install via

sudo python setup.py install

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

1 participant