This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: Cannot link _crypt and _nis modules on a host with glibc-2.12
Type: compile error Stage: resolved
Components: Versions: Python 3.4, Python 3.5
Status: closed Resolution: third party
Dependencies: Superseder:
Assigned To: Nosy List: Arfrever, mmokrejs, r.david.murray
Priority: normal Keywords:

Created on 2016-07-11 08:54 by mmokrejs, last changed 2022-04-11 14:58 by admin. This issue is now closed.

File name Uploaded Description Edit
build.log mmokrejs, 2016-07-11 08:54 build.log
nohup.out mmokrejs, 2016-07-11 16:08 python-3.4.5 using system-wide RedHat tools
nohup-gentoo-prefix.out mmokrejs, 2016-07-11 16:09 python-3.4.5 using Gentoo:Prefix tools on top of the RedHhat
Messages (7)
msg270163 - (view) Author: Martin Mokrejs (mmokrejs) Date: 2016-07-11 08:54
  it seems at least python 3.4.3-r5 on a Gentoo Linux.

Failed to build these modules:
_crypt                nis
msg270165 - (view) Author: Martin Mokrejs (mmokrejs) Date: 2016-07-11 09:01
Also is an issue with 3.5.1-r3:

x86_64-pc-linux-gnu-gcc -pthread -shared -Wl,-O1 -L. -L/scratch/mmokrejs/gentoo/lib -L/scratch/mmokrejs/gentoo/usr/lib -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -O2 -pipe -O2 -pipe -march=native -fwrapv build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/_decimal.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/basearith.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/constants.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/context.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/convolute.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/crt.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/difradix2.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/fnt.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/fourstep.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/io.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/memory.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/mpdecimal.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/numbertheory.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/sixstep.o build/temp.linux-x86_64-3.5/scratch/mmokrejs/gentoo/var/tmp/portage/dev-lang/python-3.5.1-r3/work/Python-3.5.1/Modules/_decimal/libmpdec/transpose.o -L. -L/scratch/mmokrejs/gentoo/lib -L/scratch/mmokrejs/gentoo/usr/lib -lpython3.5 -o build/lib.linux-x86_64-3.5/
*** WARNING: renaming "_crypt" since importing it failed: build/lib.linux-x86_64-3.5/ undefined symbol: crypt
*** WARNING: renaming "nis" since importing it failed: build/lib.linux-x86_64-3.5/ undefined symbol: yp_master

Following modules built successfully but were removed because they could not be imported:
_crypt                nis
msg270176 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2016-07-11 13:11
Since you are using the gentoo build system to build this, the bug report should go to the gentoo project, as indicated by the message at the end of your build log.  If they find a bug in python itself, then it can be reported here (Arfrever at least can reopen the issue if needed).  More likely it is a gentoo configuration issue.
msg270179 - (view) Author: Martin Mokrejs (mmokrejs) Date: 2016-07-11 13:23
Ah, thank you for a quick answer.

The problem is not with a Gentoo, the problem is with python which needs too new libc or libnss or libcrypt.

I am re-opening, why cannot I compile newer python version on glibc-2.12 host? This is not a problme with python-2.7, at least.
msg270184 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2016-07-11 14:43
Can you demonstrate the problem without involving the gentoo build system, using a vanilla tarball downloaded from our site?
msg270186 - (view) Author: Martin Mokrejs (mmokrejs) Date: 2016-07-11 16:08
Interesting, using the system-wide RedHat stuff I can compile vanilla Python-3.4.5. See attached nohup.out. I tried to stick to the same configure arguments as Gentoo's package manager used.

I also tried to compile the vanilla tarball under Gentoo::Prefix and wow, it also went through (as fat as _crypt is concerned). See nohup-gentoo-prefix.out
msg270187 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2016-07-11 16:20
Now you see why I guessed that it was a Gentoo issue :)  Or an issue in whatever it is you are using, since it doesn't sound like vanilla gentoo, either.

So, I'm closing this again.  If you find something you really think is a bug in *our* build process, you can open a new ticket for it.
Date User Action Args
2022-04-11 14:58:33adminsetgithub: 71667
2016-07-11 16:20:32r.david.murraysetstatus: open -> closed

messages: + msg270187
2016-07-11 16:09:26mmokrejssetfiles: + nohup-gentoo-prefix.out
2016-07-11 16:08:25mmokrejssetfiles: + nohup.out

messages: + msg270186
2016-07-11 14:43:39r.david.murraysetmessages: + msg270184
2016-07-11 13:23:51mmokrejssetstatus: closed -> open

messages: + msg270179
2016-07-11 13:11:00r.david.murraysetstatus: open -> closed

nosy: + Arfrever, r.david.murray
messages: + msg270176

resolution: third party
stage: resolved
2016-07-11 09:01:16mmokrejssetversions: + Python 3.5
2016-07-11 09:01:11mmokrejssetmessages: + msg270165
2016-07-11 08:54:33mmokrejscreate