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.

classification
Title: Build failure
Type: Stage:
Components: Build Versions: Python 2.4
process
Status: closed Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: ceramond, loewis
Priority: normal Keywords:

Created on 2005-06-30 06:27 by ceramond, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (3)
msg25689 - (view) Author: L.M (ceramond) Date: 2005-06-30 06:27
./configure + make fails with various errors
on FreeBSD 4.11-RELEASE 

case $MAKEFLAGS in  *-s*)  CC='gcc -pthread'
LDSHARED='gcc -shared' 
OPT='-DNDEBUG -g -O3 -Wall -Wstrict-prototypes'
./python -E ./setup.py -q 
build;;  *)  CC='gcc -pthread' LDSHARED='gcc -shared'
OPT='-DNDEBUG -g -O3 
-Wall -Wstrict-prototypes' ./python -E ./setup.py
build;;  esac
Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
'import site' failed; use -v for traceback
Traceback (most recent call last):
  File "./setup.py", line 6, in ?
    import sys, os, getopt, imp, re
ImportError: No module named os
*** Error code 1

If I run "make" again, it stops with this, instead, 
I found it strange because "pwd.so" isn't ready yet.


case $MAKEFLAGS in  *-s*)  CC='gcc -pthread'
LDSHARED='gcc -shared' 
OPT='-DNDEBUG -g -O3 -Wall -Wstrict-prototypes'
./python -E ./setup.py -q 
build;;  *)  CC='gcc -pthread' LDSHARED='gcc -shared'
OPT='-DNDEBUG -g -O3 
-Wall -Wstrict-prototypes' ./python -E ./setup.py
build;;  esac
Traceback (most recent call last):
  File "./setup.py", line 1184, in ?
    main()
  File "./setup.py", line 1178, in main
    scripts = ['Tools/scripts/pydoc', 'Tools/scripts/idle',
  File
"/home/mondo/Python-2.4.1/Lib/distutils/core.py", line
123, in setup
    dist.parse_config_files()
  File
"/home/mondo/Python-2.4.1/Lib/distutils/dist.py", line
339, in 
parse_config_files
    filenames = self.find_config_files()
  File
"/home/mondo/Python-2.4.1/Lib/distutils/dist.py", line
302, in 
find_config_files
    check_environ()
  File
"/home/mondo/Python-2.4.1/Lib/distutils/util.py", line
155, in 
check_environ
    import pwd
ImportError: No module named pwd
*** Error code 1


I've tried "make clean" + retry, 
giving --prefix=so-and-so to ./configure,
and some other things without success.

I have already built exactly same Python source
on this server several weeks ago (in a different
directory),
and do not understand why it's failing, now.
(Possibly, admin updated something causing build
process to fail...)

msg25690 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2005-07-06 05:20
Logged In: YES 
user_id=21627

The pwd module is only used if HOME isn't set. Why is HOME
not set on your system?
msg25691 - (view) Author: L.M (ceramond) Date: 2005-07-06 14:13
Logged In: YES 
user_id=1305168

Thank you for the info.
"export HOME" soplved the problem.

HOME wasn't exported because I was compiling on
shared hosting environment, and the host doesn't set
normal env variables.

I set HOME (and some other env var), but didn't export them.
And that caused the build failure.
History
Date User Action Args
2022-04-11 14:56:12adminsetgithub: 42145
2005-06-30 06:27:54ceramondcreate