Merge ~ahasenack/ubuntu/+source/freeradius:jammy-freeradius-fix-python3-linking-1873923 into ubuntu/+source/freeradius:ubuntu/devel
Status: | Merged |
---|---|
Merged at revision: | b9c37d97398c41a645f3b4555f3d1f69b14d6560 |
Proposed branch: | ~ahasenack/ubuntu/+source/freeradius:jammy-freeradius-fix-python3-linking-1873923 |
Merge into: | ubuntu/+source/freeradius:ubuntu/devel |
Diff against target: |
56 lines (+34/-0) 3 files modified
debian/changelog (+7/-0) debian/patches/fix-python-version-parsing.patch (+26/-0) debian/patches/series (+1/-0) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Utkarsh Gupta (community) | Approve | ||
Canonical Server | Pending | ||
Review via email: mp+417631@code.launchpad.net |
Description of the change
Fix linking of the rlm_python3 module with python3
PPA: https:/
I'm not super proud of this fix, but I figured it was the smallest one we could do at this stage. Running autoreconf makes a lot of other changes, and also produces warnings. It's likely upstream isn't fully ready for autoconf 2.7x. We had to fix other packages in the recent past due to this autoconf version bump, and I don't think we should do it now just days before beta freeze.
Note that this is a configure (and configure.ac) script deep inside the soruce tree, and not the main one at the root.
That being said, the one-liner fix comes exactly from such an autoreconf run.
I grepped the code and the only other place where the python version is parsed like that is in rlm-python, which we don't build:
=== configuring in src/modules/
...
configure: WARNING: silently not building rlm_python.
configure: WARNING: FAILURE: rlm_python requires: python-binary.
Another option I entertained for a while was to export EMBED=--embed in d/rules, which would also accomplish this. But rely on configure being the same going forward, still using that variable or detection mechanism, and we wouldn't notice a breakage again, unless we added a DEP8 test specifically for this.
To test:
apt update
apt install freeradius freeradius-python3 -y
ln -s /etc/freeradius
systemctl stop freeradius
freeradius -Xx 2>&1 | tee output.log
In jammy, freeradius will exit with this:
Thu Mar 24 14:23:46 2022 : Error: /etc/freeradius
With the fix, it will stay running.
Another quick check is verify the python3 module was linked with python3:
root@j1:~# ldd /usr/lib/
root@j1:~#
versus
root@j1:~# ldd /usr/lib/
libpython3.
Looks good with one trivial comment.