Conversation
|
Confirming here that applying the patch makes the nis module compile successfully at a system where the sun rpc interfaces are provided by libtirpc and not glibc. |
|
With this change, setup.py first checks if rpcsvc/yp_prot.h is available: and then it checks if libtirpc is available: If libtirpc is available, it pass /usr/include/tirpc in include directories to build nismodule.c. In Fedora 27, rpcsvc/yp_prot.h is provided by glibc-headers. In Fedora rawhide (future F28), it's still provided by glibc-headers. It may be provided by a different package (rpcsvc-proto) in the future: https://bugzilla.redhat.com/show_bug.cgi?id=1532364 The PR is correct since rpcsvc/yp_prot.h will remain in /usr/include (full path: /usr/include/rpcsvc/yp_prot.h) even if it will be provided by a different package in Fedora 28. |
vstinner
left a comment
There was a problem hiding this comment.
LGTM, but please just rename include_dirs variable.
Later we might enhance the code by using pkg-config to get the include directory, rather than using an hardcoded path, but well... setup.py doesn't support pkg-config yet, pkg-config is not available on all platforms, and nis is going to be deprecated... So I don't think that it's worth it.
setup.py
Outdated
There was a problem hiding this comment.
This code lives in the giant detect_modules() function which is 1184 lines long... The function should be refactored, but that's out of the scope of the PR.
Would you mind to rename include_dirs to nic_incs, as done for for other "include_dirs=" parameters? It would avoid bad surprised with name clashes in this giant function.
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis module Signed-off-by: Christian Heimes <christian@python.org>
|
@vstinner PR is ready for review |
|
Thanks @tiran for the PR 🌮🎉.. I'm working now to backport this PR to: 2.7, 3.6. |
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis module Signed-off-by: Christian Heimes <christian@python.org> (cherry picked from commit f3031b8)
|
GH-5165 is a backport of this pull request to the 3.6 branch. |
|
GH-5166 is a backport of this pull request to the 2.7 branch. |
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis module Signed-off-by: Christian Heimes <christian@python.org> (cherry picked from commit f3031b8)
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis moduleupdated path for rpc.h for systems using libtirpc See python/cpython#5137 This closes #224 Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillion@kitware.com>
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis moduleupdated path for rpc.h for systems using libtirpc See python/cpython#5137 This closes #224 Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillion@kitware.com>
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis moduleupdated path for rpc.h for systems using libtirpc See python/cpython#5137 This closes #224 Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis moduleupdated path for rpc.h for systems using libtirpc See python/cpython#5137 This closes #224 Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis moduleupdated path for rpc.h for systems using libtirpc See python/cpython#5137 This closes python-cmake-buildsystem#224 Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
glibc has removed Sun RPC. Use replacement libtirpc headers and library in nis moduleupdated path for rpc.h for systems using libtirpc See python/cpython#5137 This closes python-cmake-buildsystem#224 Co-authored-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
glibc has removed Sun RPC. Use replacement libtirpc headers and library in
nis module
Signed-off-by: Christian Heimes christian@python.org
https://bugs.python.org/issue32521