-
Notifications
You must be signed in to change notification settings - Fork 2
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
Rewrite Debian/Ubuntu packaging #24
Conversation
To avoid having to deal with the setup.py install vagueries when installing python for Debian packaging, let pybuild take care of the building and installing of python. Rewrite debian/rules to make use of debhelper for as much as possible and minimize hackery. Also remove Debian-packaging-specific hacks in Makefile.in The recipe we are now following is to install everything in debian/tmp (instead of straight into the debian/<package>/ directories), and divide the resulting files up over the packages using debian/<package.install> files. Try to clean up some Lintin errors and warnings in the process. Note that we are still using distutils in the setup.py files and calling "python setup.py install" which are both deprecated. Only this combination appears to not be hit by pypa/pip#10978 so just leaving as is. Also introduces: * testing on both Focal and Jammy * fix intermittent test failure in build process
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.
Looks great. This is a huge improvement and will help me immensely on a few machines where I've run into problems with this already. Thanks @stephankramer !
Couple of quick questions in the comments but happy to approve regardless.
.github/workflows/ubuntu.yml
Outdated
@@ -22,7 +38,7 @@ jobs: | |||
run: | | |||
echo "Europe/London" > /etc/timezone | |||
apt-get -y update | |||
DEBIAN_FRONTEND=noninteractive apt-get -y install gfortran g++ python3-setuptools python3-all-dev debhelper dh-python texlive python3-junit.xml | |||
DEBIAN_FRONTEND=noninteractive apt-get -y install gfortran g++ python3-setuptools python3-pip python3-all-dev debhelper dh-python texlive python3-junit.xml |
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.
Not a problem but curious if the pip installation is still necessary or leftover from when you were trying it that way?
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.
Removed now
debian/control
Outdated
Priority: extra | ||
Build-Depends: gfortran (>=4.2), g++ (>=4.2), python3-setuptools (>= 0.6b3-1), python3-all-dev (>= 2.3.5-11), debhelper (>= 5.0.38), dh-python, texlive | ||
Priority: optional | ||
Build-Depends: gfortran (>=4.2), g++ (>=4.2), python3-setuptools (>= 39), python3-pip, python3-all-dev , debhelper (>= 5.0.38), dh-python, texlive |
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.
Same question about pip, is it a required dependency?
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.
No indeed. Removed
Also update actions versions to get rid of github actions warnings
368b636
to
7877ed7
Compare
7877ed7
to
b30d9ae
Compare
Thanks, good point. |
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.
Looks good!
To avoid having to deal with the setup.py install vagueries when installing python for Debian packaging, let pybuild take care of the building and installing of python. Rewrite debian/rules to make use of debhelper for as much as possible and minimize hackery. Also remove Debian-packaging-specific hacks in Makefile.in
The recipe we are now following is to install everything in debian/tmp (instead of straight into the debian// directories), and divide the resulting files up over the packages using debian/<package.install> files. Try to clean up some Lintin errors and warnings in the process.
Note that we are still using distutils in the setup.py files and calling "python setup.py install" which are both deprecated. Only this combination appears to not be hit by pypa/pip#10978 so just leaving as is.
Also introduces: