Python project from source to DEB using dpkg-deb
dpkg-deb
Using dpkg-deb util to create debian package from python project (wrap the whl file create by python3 -m build)
Demo
demo code
My basic idea is create project DEBIAN folder the include all the file that i need to pack include the whl file that create using python -m build
- Create root folder named
python3-<project-name> - Create DEBIAN folder
- Add control file under DEBIAN folder
- Using
python -m build --outdirto place the dir under the project debian folder (dist sub folder) - Add
postinstandpostrmto install thewhlfile when we install the package - Set execte permission to
postinstandpostrmand644tocontrolfile - Create
debsfolder under project root for deb output - Run
dpkg-deb python3-<project-name> debs - Check the debian using
dpkg -Ianddpkg -c
Project
| control | |
|---|---|
| postint | |
|---|---|
TODO
- i know that run pip from postinst it`s bead idea,