From 643e98ad549eb4e6a9d88f53b4c1111a8cac4519 Mon Sep 17 00:00:00 2001 From: Nils Homer Date: Fri, 17 Jan 2025 00:14:30 -0700 Subject: [PATCH] build: add sources when building --- build.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/build.py b/build.py index 5765ca2..e825fcb 100644 --- a/build.py +++ b/build.py @@ -10,13 +10,13 @@ BUILD_DIR = Path("cython_build") compile_args = [] link_args = [] -include_dirs = ["bwa"] +include_dirs = ["bwa", "pybwa"] libraries = ['m', 'z', 'pthread'] -library_dirs=['bwa'] +library_dirs=['pybwa', 'bwa'] extra_objects = [] h_files = [] c_files = [] -for root_dir in ["bwa", "pybwa"]: +for root_dir in library_dirs: h_files.extend(str(x) for x in Path(root_dir).rglob("*.h")) c_files.extend(str(x) for x in Path(root_dir).rglob("*.c") if x.name not in ['example.c', 'main.c']) @@ -117,8 +117,9 @@ def build(): 'platforms': ['POSIX', 'UNIX', 'MacOS'], 'classifiers': [_f for _f in CLASSIFIERS.split('\n') if _f], 'url': 'https://github.com/fulcrumgenomics/pybwa', - 'packages': ['pybwa'], - 'package_dir': {'pybwa': 'pybwa'}, + 'packages': ['pybwa', 'pybwa.include.bwa'], + 'package_dir': {'pybwa': 'pybwa', 'pybwa.include.bwa': 'bwa'}, + 'package_data': {'': ['*.pxd', '*.h', '*.c', 'py.typed', '*.pyi'], }, "ext_modules": extension_modules, "cmdclass": { "build_ext": cython_build_ext,