rembg icon indicating copy to clipboard operation
rembg copied to clipboard

[BUG] llvmlite fails building upon pip install

Open blurridge opened this issue 1 year ago • 3 comments

Describe the bug I've tried pip installing both on my docker container and my local machine and llvmlite does not build. Also already tried updating pip

To Reproduce Steps to reproduce the behavior:

  1. Create an environment with Python 3.10
  2. Pip install rembg

Expected behavior Successful pip install

Images Input images to reproduce.

OS Version: Mac OS Sonoma 14.6.1

Rembg version: v2.0.59

Additional context

note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for numba
  Building wheel for llvmlite (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for llvmlite (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [26 lines of output]
      running bdist_wheel
      /Users/blurridge/Documents/Coding/fsl-backend/env/bin/python3.10 /private/var/folders/js/n5lc337x5sd6y0sqph8lr6gm0000gn/T/pip-install-gyhwh4ko/llvmlite_ac3d895caafe49ab9a581b2fec787acb/ffi/build.py
      LLVM version... Traceback (most recent call last):
        File "/private/var/folders/js/n5lc337x5sd6y0sqph8lr6gm0000gn/T/pip-install-gyhwh4ko/llvmlite_ac3d895caafe49ab9a581b2fec787acb/ffi/build.py", line 105, in main_posix
          out = subprocess.check_output([llvm_config, '--version'])
        File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 420, in check_output
          return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
        File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 501, in run
          with Popen(*popenargs, **kwargs) as process:
        File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/subprocess.py", line 966, in __init__
          self._execute_child(args, executable, preexec_fn, close_fds,
        File "/Library/Frameworks/Python.framework/Versions/3.10/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: 'llvm-config'

      During handling of the above exception, another exception occurred:

      Traceback (most recent call last):
        File "/private/var/folders/js/n5lc337x5sd6y0sqph8lr6gm0000gn/T/pip-install-gyhwh4ko/llvmlite_ac3d895caafe49ab9a581b2fec787acb/ffi/build.py", line 191, in <module>
          main()
        File "/private/var/folders/js/n5lc337x5sd6y0sqph8lr6gm0000gn/T/pip-install-gyhwh4ko/llvmlite_ac3d895caafe49ab9a581b2fec787acb/ffi/build.py", line 185, in main
          main_posix('osx', '.dylib')
        File "/private/var/folders/js/n5lc337x5sd6y0sqph8lr6gm0000gn/T/pip-install-gyhwh4ko/llvmlite_ac3d895caafe49ab9a581b2fec787acb/ffi/build.py", line 107, in main_posix
          raise RuntimeError("%s failed executing, please point LLVM_CONFIG "
      RuntimeError: llvm-config failed executing, please point LLVM_CONFIG to the path for llvm-config
      error: command '/Users/blurridge/Documents/Coding/fsl-backend/env/bin/python3.10' failed with exit code 1
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for llvmlite
Failed to build numba llvmlite
ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (numba, llvmlite)

blurridge avatar Sep 12 '24 04:09 blurridge