954,557 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Build python3.1.2 from source on RHEL4

Hi all.
I'm trying install python 3.1.2 on RHEL4 from source, but 'make' failed to build some necessary modules. Followings are from build log:

*** WARNING: importing extension "_ctypes" failed with : 'module' object has no attribute 'load_dynamic'

Python build finished, but the necessary bits to build these modules were not found:
_sqlite3 _tkinter
To find the necessary bits, look in setup.py in detect_modules() for the module's name.


Failed to build these modules:
_bisect _codecs_cn _codecs_hk
_codecs_iso2022 _codecs_jp _codecs_kr
_codecs_tw _collections _csv
_ctypes _ctypes_test _curses
_curses_panel _dbm _elementtree
_gdbm _hashlib _heapq
_json _lsprof _multibytecodec
_multiprocessing _pickle _random
_sha256 _sha512 _socket
_ssl _struct _testcapi
array atexit audioop
binascii bz2 cmath
crypt datetime fcntl
grp itertools math
mmap nis operator
ossaudiodev parser pyexpat
readline resource select
spwd syslog termios
time unicodedata zlib

Any ideas?

_neo_
Junior Poster in Training
64 posts since Aug 2010
Reputation Points: 26
Solved Threads: 3
 

DOn't you need to pass a flag to ./configure, like --enable-shared ? Check your configure options.

Gribouillis
Posting Maven
Moderator
2,786 posts since Jul 2008
Reputation Points: 1,044
Solved Threads: 691
 

thanks, now I will try

_neo_
Junior Poster in Training
64 posts since Aug 2010
Reputation Points: 26
Solved Threads: 3
 

same result...:-(
This is a part of make's log:

gcc -pthread -shared build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/_ctypes.o build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/callbacks.o build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/callproc.o build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/stgdict.o build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/cfield.o build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/malloc_closure.o build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/libffi/src/prep_cif.o build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/libffi/src/x86/ffi.o build/temp.linux-i686-3.1/usr/src/Python-3.1.2/Modules/_ctypes/libffi/src/x86/sysv.o -L/usr/local/lib -L. -lpython3.1 -o build/lib.linux-i686-3.1/_ctypes.so
*** WARNING: importing extension "_ctypes" failed with : 'module' object has no attribute 'load_dynamic'

Python build finished, but the necessary bits to build these modules were not found:
_sqlite3 _tkinter
To find the necessary bits, look in setup.py in detect_modules() for the module's name.


Failed to build these modules:
_bisect _codecs_cn _codecs_hk
_codecs_iso2022 _codecs_jp _codecs_kr
_codecs_tw _collections _csv
_ctypes _ctypes_test _curses
_curses_panel _dbm _elementtree
_gdbm _hashlib _heapq
_json _lsprof _multibytecodec
_multiprocessing _pickle _random
_sha256 _sha512 _socket
_ssl _struct _testcapi
array atexit audioop
binascii bz2 cmath
crypt datetime fcntl
grp itertools math
mmap nis operator
ossaudiodev parser pyexpat
readline resource select
spwd syslog termios
time unicodedata zlib

running build_scripts

_neo_
Junior Poster in Training
64 posts since Aug 2010
Reputation Points: 26
Solved Threads: 3
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: