Support building debian packages for PANDA and pip packages for PyPANDA #1399
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR aims to give us a sane way to distribute PANDA and PyPANDA.
Debian packaging
Add support for creating debian packages for PANDA using our existing docker containers.
Running
./panda/debian/setup.sh Ubuntu [VERSION]
with VERSION set to 18.04/20.04/22.04 will create a pandare.deb package that can be installed withapt install pandare.deb
. This PR does not integrate this with CI but I think that's something we should explore in the future.PyPANDA packaging
This PR refactors the PyPANDA install to remove the panda binaries, libraries and plugins and limits it to just python scripts, the qcows.json, and the autogenerated headers. As a result the package is about 50x smaller and no longer gets out of sync with the host (non-python) version of PANDA.
Instead of including these binaries in the package, this now uses the binaries at the expected paths from the debian package package. If a user installs with
python3 setup.py develop
it should continue to behave as normal and pull libpanda libraries and compiled plugins from the panda build path.To create a source dist in panda/panda/python/core you run:
Known issues
Example
The following dockerfile installs panda and pypanda in Ubuntu 20.04 from the panda .deb and the pypanda sdist: