The process of packaging a nested Python module with scikit-build involves the following steps:
Create a setup.py file in the root directory of the package.
Import the setup function from the scikit-build module.
Create a setup dictionary that defines the package name, version, author, description, required packages, and any other relevant metadata.
Add the following code to the setup dictionary to include the nested module:
setup(
...
packages = find_packages(),
include_package_data = True,
...
)
The find_packages()
function will automatically search for any packages within the root folder, including any nested modules.
Add any C/C++ source files or libraries required for the package.
Run python setup.py sdist
to create a source distribution package.
Run pip install .
to install the package locally.
Test the package to ensure that it functions correctly.
Publish the package to PyPI or another package repository as desired.
By following these steps, you can package a nested Python module with scikit-build and make it accessible as a standalone package for use in other projects.
Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss
Asked: 2021-09-25 11:00:00 +0000
Seen: 15 times
Last updated: Mar 09 '22
How can I use oversampling to address a problem?
What is the process for obtaining metadata from my Python-Django project in order to execute SSO?
How come const char* is automatically transformed to bool instead of std::string?
How can Django Admin accommodate a variety of formats and locales for its input fields?
How can an array be passed using typo3 flexform xml and itemsProcConfig?
Is it possible to invoke an asynchronous function without using the await keyword?