Skip to content
Snippets Groups Projects
Commit 9645e3dd authored by Grégoire Kubler's avatar Grégoire Kubler
Browse files

feat : find_package is now hanlded by pyproject.toml

parent 078cdfd6
No related branches found
No related tags found
No related merge requests found
......@@ -23,7 +23,11 @@ build-backend = "setuptools.build_meta"
#####################################################
# SETUPTOOLS
[tool.setuptools]
#####################################################
[tool.setuptools.packages.find]
where = ["."] # list of folders that contain the packages (["."] by default)
include = ["aidge_core*"] # package names should match these glob patterns (["*"] by default)
exclude = ["aidge_core.unit_tests*"] # exclude packages matching these glob patterns (empty by default)
namespaces = false # to disable scanning PEP 420 namespaces (true by default)
# SETUPTOOLS_SCM
[tool.setuptools_scm]
write_to = "aidge_core/_version.py"
......
......@@ -12,7 +12,6 @@ from math import ceil
import toml
from setuptools import setup, Extension
from setuptools import find_packages
from setuptools.command.build_ext import build_ext
def get_project_name() -> str:
......@@ -21,7 +20,6 @@ def get_project_name() -> str:
return project_toml["project"]["name"]
class CMakeExtension(Extension):
def __init__(self, name):
super().__init__(name, sources=[])
......@@ -98,9 +96,7 @@ class CMakeBuild(build_ext):
if __name__ == "__main__":
setup(
packages=find_packages(where="."),
include_package_data=True,
ext_modules=[CMakeExtension(get_project_name())],
cmdclass={
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment