Python installation Setuptools Compression requires the (missing) Zlib module solution

Source: Internet
Author: User

When installing Setuptools, the following error is reported:


Creating ' Dist/setuptools-0.6c11-py2.7.egg ' and adding ' Build/bdist.linux-x86_64/egg ' to it
Traceback (most recent):
File "setup.py", line 94, in <module>
Scripts = scripts,
File "/usr/local/lib/python2.7/distutils/core.py", line, in Setup
Dist.run_commands ()
File "/usr/local/lib/python2.7/distutils/dist.py", line 953, in Run_commands
Self.run_command (CMD)
File "/usr/local/lib/python2.7/distutils/dist.py", line 972, in Run_command
Cmd_obj.run ()
File "/opt/oracle/sor/install/setuptools-0.6c11/setuptools/command/install.py", line +, in run
Self.do_egg_install ()
File "/opt/oracle/sor/install/setuptools-0.6c11/setuptools/command/install.py", line +, in Do_egg_install
Self.run_command (' Bdist_egg ')
File "/usr/local/lib/python2.7/distutils/cmd.py", line 326, in Run_command
Self.distribution.run_command (command)
File "/usr/local/lib/python2.7/distutils/dist.py", line 972, in Run_command
Cmd_obj.run ()
File "/opt/oracle/sor/install/setuptools-0.6c11/setuptools/command/bdist_egg.py", line 236, in Run
Dry_run=self.dry_run, Mode=self.gen_header ())
File "/opt/oracle/sor/install/setuptools-0.6c11/setuptools/command/bdist_egg.py", line 527, in Make_zipfile
z = zipfile. ZipFile (zip_filename, mode, compression=compression)
File "/usr/local/lib/python2.7/zipfile.py", line 681, in __init__
"Compression requires the (missing) zlib module"

Runtimeerror:compression requires the (missing) zlib module


Yum Install zlib

Yum Install Zlib-devel

After the installation is complete, recompile the python2.7
No need to delete, just need to recompile only make && make installl installation is OK


Then reinstall Setuptools:

CD SETUPTOOLS-0.6C11

Python setup.py Install

Python installation Setuptools Compression requires the (missing) Zlib module solution

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.