-
Notifications
You must be signed in to change notification settings - Fork 0
Add Debian package (.deb) support to Python binary builds #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: anubhavkrishna1 <182243148+anubhavkrishna1@users.noreply.github.com>
…and updated documentation Co-authored-by: anubhavkrishna1 <182243148+anubhavkrishna1@users.noreply.github.com>
anubhavkrishna1
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems good
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds Debian package (.deb) support to the existing Python binary build system, allowing users to install Python binaries as proper Debian packages alongside the existing tar.gz and zip archives.
- Added .deb package creation to both standard and glibc236 build workflows
- Updated README with comprehensive installation and uninstallation instructions for deb packages
- Enhanced release artifacts to include .deb files with SHA256 checksums
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| README.md | Added deb package installation instructions and uninstallation section |
| .github/workflows/build.yml | Added deb packaging tools and deb package creation step |
| .github/workflows/build-glibc236.yml | Added deb packaging tools and deb package creation step for glibc236 builds |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
| echo "Priority: optional" >> deb_package/DEBIAN/control | ||
| echo "Architecture: amd64" >> deb_package/DEBIAN/control | ||
| echo "Installed-Size: $INSTALLED_SIZE" >> deb_package/DEBIAN/control | ||
| echo "Depends: libc6 (>= 2.17), libssl3 | libssl1.1, zlib1g, libbz2-1.0, libffi8 | libffi7 | libffi6, libgdbm6 | libgdbm5, liblzma5, libncurses6 | libncurses5, libreadline8 | libreadline7 | libreadline6, libsqlite3-0, uuid-runtime" >> deb_package/DEBIAN/control |
Copilot
AI
Sep 6, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This long dependency line is difficult to read and maintain. Consider breaking it into multiple echo statements or using a multi-line approach for better readability.
| echo "Priority: optional" >> deb_package/DEBIAN/control | ||
| echo "Architecture: amd64" >> deb_package/DEBIAN/control | ||
| echo "Installed-Size: $INSTALLED_SIZE" >> deb_package/DEBIAN/control | ||
| echo "Depends: libc6 (>= 2.17), libssl3 | libssl1.1 | libssl1.0.0, zlib1g, libbz2-1.0, libffi8 | libffi7 | libffi6, libgdbm6 | libgdbm5 | libgdbm3, liblzma5, libncurses6 | libncurses5, libreadline8 | libreadline7 | libreadline6, libsqlite3-0, uuid-runtime" >> deb_package/DEBIAN/control |
Copilot
AI
Sep 6, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This long dependency line is difficult to read and maintain. Consider breaking it into multiple echo statements or using a multi-line approach for better readability.
| echo "Depends: libc6 (>= 2.17), libssl3 | libssl1.1 | libssl1.0.0, zlib1g, libbz2-1.0, libffi8 | libffi7 | libffi6, libgdbm6 | libgdbm5 | libgdbm3, liblzma5, libncurses6 | libncurses5, libreadline8 | libreadline7 | libreadline6, libsqlite3-0, uuid-runtime" >> deb_package/DEBIAN/control | |
| DEPENDS="libc6 (>= 2.17)," | |
| DEPENDS="$DEPENDS libssl3 | libssl1.1 | libssl1.0.0," | |
| DEPENDS="$DEPENDS zlib1g," | |
| DEPENDS="$DEPENDS libbz2-1.0," | |
| DEPENDS="$DEPENDS libffi8 | libffi7 | libffi6," | |
| DEPENDS="$DEPENDS libgdbm6 | libgdbm5 | libgdbm3," | |
| DEPENDS="$DEPENDS liblzma5," | |
| DEPENDS="$DEPENDS libncurses6 | libncurses5," | |
| DEPENDS="$DEPENDS libreadline8 | libreadline7 | libreadline6," | |
| DEPENDS="$DEPENDS libsqlite3-0," | |
| DEPENDS="$DEPENDS uuid-runtime" | |
| echo "Depends: $DEPENDS" >> deb_package/DEBIAN/control |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove unnecessary dependencies just keep important ones
This PR implements support for creating Debian packages (.deb files) alongside the existing tar.gz and zip binary archives, addressing the request to "pack python3 binary in also deb file".
Changes Made
Workflow Enhancements
build.ymlandbuild-glibc236.ymlworkflows now installdpkg-debandfakeroottools required for creating Debian packages.debfiles alongside existing formats, with SHA256 checksums for all package typesPackage Details
python<major.minor>-custom(e.g.,python3.11-custom) installed to/opt/python-<version>/python<major.minor>-custom-glibc236installed to/opt/python-<version>-glibc236/Documentation Updates
Usage Examples
Installing a deb package:
Uninstalling:
Benefits
The implementation maintains minimal changes to existing workflows while adding comprehensive deb package support that integrates seamlessly with the current build process.
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.