From 4b1dac78f57fc4f8f2bfef0a378d0aca29ce6862 Mon Sep 17 00:00:00 2001 From: Thomas Waldmann Date: Mon, 18 Sep 2023 01:03:57 +0200 Subject: [PATCH] pyproject.toml: exclude source files which have been compiled, fixes #7828 --- pyproject.toml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 26fca448..908777ac 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,6 +53,18 @@ nofuse = [] borg = "borg.archiver:main" borgfs = "borg.archiver:main" +[tool.setuptools] +# See also the MANIFEST.in file. +# We want to install all the files in the package directories... +include-package-data = true + +[tool.setuptools.packages.find] +where = ["src"] + +[tool.setuptools.exclude-package-data] +# ...except the source files which have been compiled (C extensions): +"*" = ["*.c", "*.h", "*.pyx"] + [build-system] requires = ["setuptools", "wheel", "pkgconfig", "Cython", "setuptools_scm[toml]>=6.2"] build-backend = "setuptools.build_meta"