diff --git a/.gitignore b/.gitignore index d2d6f36..6dd3c30 100644 --- a/.gitignore +++ b/.gitignore @@ -18,6 +18,14 @@ develop-eggs lib lib64 +# Compilation artifacts +_skbuild/ + +# Python distribution stuff +dist/ +MANIFEST +*.egg-info/ + # Installer logs pip-log.txt diff --git a/README.md b/README.md index da51138..13906cd 100644 --- a/README.md +++ b/README.md @@ -58,6 +58,29 @@ You can use tito for building rpm package. From checkout dir: tito build --rpm --test +## Building Python package +To create a binary "wheel" distribution, use: + + python setup.py bdist_wheel + +To create a source distribution, use: + + python setup.py sdist + +Installing source distributions require the installer of the package to have all of the build dependencies installed on their system, since they compile the code during installation. Binary distributions are pre-compiled, but they are likely not portable between substantially different systems, e.g. Fedora and Ubuntu. + +Note: if you are building a bdist or installing the sdist on a system with an older version of Pip, you may need to install the ```scikit-build``` Python package first. + +To install either of these packages, use: + + pip install dist/{{ package name }} + +To create an "editable" install of libcomps, use: + + python setup.py develop + +Note: To recompile the libraries and binaries, you muse re-run this command. + ### Installing * After successful build run: make install