Skip to contentSkip to conversation

u_boot_pylib: disable standalone module detection

PATCH New Paul HENRYS 1 participant 2 messages Mar 30

lore
Share & tools
lore
#0 lore raw

cover u_boot_pylib: disable standalone module detection

Do not try to detect standalone python modules at the top level, so setuptools stops searching for: command, terminal, ... as independent modules and instead relies on package discovery.

Steps to reproduce the issue without the patch:

git clone https://source.denx.de/u-boot/u-boot.git
cd u-boot
python3 -m venv myenv
source myenv/bin/activate
pip3 install tools/u_boot_pylib/
...
error: Multiple top-level modules discovered in a flat-layout: ['command', 'terminal', 'test_util', 'tout', 'cros_subprocess', 'tools', 'gitutil'].

Paul HENRYS:
tools: u_boot_pylib: disable standalone module detection

 tools/u_boot_pylib/pyproject.toml | 3 +++
 1 file changed, 3 insertions(+)
Signature · 1 line
2.43.0
#1 lore raw

PATCH 1/1 tools: u_boot_pylib: disable standalone module detection

Do not try to detect standalone python modules at the top level, so setuptools stops searching for: command, terminal, ... as independent modules and instead relies on package discovery.

---
 tools/u_boot_pylib/pyproject.toml | 3 +++
 1 file changed, 3 insertions(+)
tools/u_boot_pylib/pyproject.toml +3 -0
index a860d134551..22b364583a0 100644
@@ -21,5 +21,8 @@ classifiers = [
 "Homepage" = "https://docs.u-boot.org"
 "Bug Tracker" = "https://source.denx.de/groups/u-boot/-/issues"
 
+[tool.setuptools]
+py-modules = []
+
 [tool.setuptools.package-data]
 u_boot_pylib = ["*.rst"]
Signature · 1 line
2.43.0