Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 799383

Summary: dev-python/pyproject2setuppy: make it work with dev-util/maturin
Product: Gentoo Linux Reporter: Alessandro Barbieri <lssndrbarbieri>
Component: Current packagesAssignee: Michał Górny <mgorny>
Status: RESOLVED OBSOLETE    
Severity: normal CC: ionen, python, rust, sam, steils
Priority: Normal Keywords: NeedPatch
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Alessandro Barbieri 2021-06-30 19:06:52 UTC
I'm trying to package orjson and they use pyproject.toml with maturin
The current pyproject2setuppy fail
at compiling with

python3.9 -m pyproject2setuppy build -j 12                                                                                                                                                                                                  
Traceback (most recent call last):                                                                                                                                                                                                          
  File "/usr/lib/python3.9/runpy.py", line 197, in _run_module_as_main                                                                                                                                                                      
    return _run_code(code, main_globals, None,                                                                                                                                                                                              
  File "/usr/lib/python3.9/runpy.py", line 87, in _run_code                                                                                                                                                                                 
    exec(code, run_globals)                                                                                                                                                                                                                 
  File "/usr/lib/python3.9/site-packages/pyproject2setuppy/__main__.py", line 52, in <module>                                                                                                                                               
    main()                                                                                                                                                                                                                                  
  File "/usr/lib/python3.9/site-packages/pyproject2setuppy/__main__.py", line 45, in main                                                                                                                                                   
    raise NotImplementedError(                                                                                                                                                                                                              
NotImplementedError: Build backend maturin unknown

at installing with

>>> Install dev-python/orjson-3.5.3 into /var/tmp/portage/dev-python/orjson-3.5.3/image
python3.9 -m pyproject2setuppy install --skip-build --root=/var/tmp/portage/dev-python/orjson-3.5.3/image
Traceback (most recent call last):                                                                                    
  File "/usr/lib/python3.9/runpy.py", line 197, in _run_module_as_main                     
    return _run_code(code, main_globals, None,                                                                        
  File "/usr/lib/python3.9/runpy.py", line 87, in _run_code                                              
    exec(code, run_globals)                                                                                           
  File "/usr/lib/python3.9/site-packages/pyproject2setuppy/__main__.py", line 52, in <module>
    main()        
  File "/usr/lib/python3.9/site-packages/pyproject2setuppy/__main__.py", line 45, in main
    raise NotImplementedError(
NotImplementedError: Build backend maturin unknown
Comment 1 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2021-06-30 19:28:48 UTC
I currently have less than zero interest in Rust.
Comment 2 anonymous 2021-10-05 11:36:49 UTC
When I try to build dev-python/pdm-pep517::crocket-overlay, I get this error.

NotImplementedError: Build backend pdm.pep517.api unknown
Comment 3 Ionen Wolkens gentoo-dev 2022-04-25 18:41:31 UTC
DISTUTILS_USE_PEP517=maturin is supported now and allows use a pyproject.toml with maturin build-system with distutils-r1. See >=dev-python/adblock-0.5.2-r1 for an example.

Given this is replacing pyproject2setuppy, I think we can mark this obsolete.

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a830c1249c408185b448ecb2b9e8a1eb997fac4a