473,385 Members | 1,908 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Problems building zlib module on RHEL

I can't seem to get the zlib module to build on an RHEL box.

I did the following:
1) Download zlib 1.2.3
2) configure;make;make install
3) Download python 2.5.2
4) configure;make;make install
5) >>import zlib ="ImportError: No module named zlib"

In the make install step for python, I notice there are the following
errors:

building 'zlib' extension
gcc -pthread -shared build/temp.linux-x86_64-2.5/home/shake/python/
Python-2.5.2/Modules/zlibmodule.o -L/usr/local/lib -lz -o build/
lib.linux-x86_64-2.5/zlib.so
/usr/bin/ld: /usr/local/lib/libz.a(crc32.o): relocation R_X86_64_32
against `a local symbol' can not be used when making a shared object;
recompile with -fPIC
/usr/local/lib/libz.a: could not read symbols: Bad value
collect2: ld returned 1 exit status

Does anyone have any hints on how to get around this?

system info:
kernel : 2.6.9-67.0.1.ELsmp
gcc : 3.4.6

Thanks,

Mike
Mar 18 '08 #1
1 4361
On Mar 18, 8:42 am, "mhearne808[insert-at-sign-here]gmail[insert-dot-
here]com" <mhearne...@gmail.comwrote:
I can't seem to get the zlib module to build on an RHEL box.

I did the following:
1) Download zlib 1.2.3
2) configure;make;make install
3) Download python 2.5.2
4) configure;make;make install
5) >>import zlib ="ImportError: No module named zlib"

In the make install step for python, I notice there are the following
errors:

building 'zlib' extension
gcc -pthread -shared build/temp.linux-x86_64-2.5/home/shake/python/
Python-2.5.2/Modules/zlibmodule.o -L/usr/local/lib -lz -o build/
lib.linux-x86_64-2.5/zlib.so
/usr/bin/ld: /usr/local/lib/libz.a(crc32.o): relocation R_X86_64_32
against `a local symbol' can not be used when making a shared object;
recompile with -fPIC
/usr/local/lib/libz.a: could not read symbols: Bad value
collect2: ld returned 1 exit status

Does anyone have any hints on how to get around this?

system info:
kernel : 2.6.9-67.0.1.ELsmp
gcc : 3.4.6

Thanks,

Mike
I figured it out, although it wasn't obvious... You have to compile
zlib as a shared library by running "configure -s".
Mar 18 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Slavik | last post by:
All libraries were installed (precompiled) This is FreeBSD 5.1 installed zlib, installed jpeg and png libraries (in default directories) GD 2.0.11 source is in /usr/gd-2.0.11 (compiled and...
3
by: Alan Toppen | last post by:
I was unable to use the ZipFile class in the zipfile module in Python2.4. I got an error that zlib could not be found. Comparing my Python 2.2 installation I noticed Python 2.4 was missing a...
6
by: Laszlo Zsolt Nagy | last post by:
Sorry, I realized that the import zlib was not executed from my (working) service. So here is the question: why can't I use zlib from a win32 service? Is there any way to make it working? ...
4
by: shamzz | last post by:
Hi, I've compiled (configure/make/make install) Python 2.4.4 from source on Suse Linux Enterprise Server 9 (x64). I need Python to be compiled with Zlib so that I can compile and use Zope. ...
3
by: John Murtari | last post by:
Folks, Trying to build php 4.4.6 and apache 1.3.37 on RHEL 4. Each of them builds and installs okay, but when we start apache we get: Syntax error on line 238 of...
13
by: treble54 | last post by:
I need to build PHP from source with the pdo_ibm extension and I am having an issue with it. Firstly, I am using Visual Studio .NET 2003 and I am building PHP from source through the Visual Studio...
4
by: mhearne808[insert-at-sign-here]gmail[insert-dot-he | last post by:
I'm trying to compile Python 2.5 on a RHEL system, using "./ configure;make;make install". The build seems to go alright, but the zlib module is missing. I've tried the following: 1) Download...
3
by: stuntgoat | last post by:
import zlib works in Python 2.4 (debian etch AMD64 - default python version for that distro) I built python 2.5 from source; zlib is not importable. I am trying to compile MySQLdb. any...
2
by: rajevar | last post by:
hi, i have seen various post related to this topic but i couldnt resolve my issue yet. Im using python version 2.5 on Linux environment this is the error im getting if i try to import zlib ...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.