473,387 Members | 1,621 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,387 software developers and data experts.

2.4beta1 distutil problem?

Hi,

I'd like to install SCons (http://www.scons.org) on my Linux box.
There, the cvs version of Python is running.
Doing as recommended in the README file

export SCONS_LIB_DIR=`pwd`/src/engine
python src/script/scons.py build/scons

I get after some time
/usr/local/bin/python build/scons/setup.py bdist_wininst
running bdist_wininst
running build
running build_py
running build_scripts
Traceback (most recent call last):
File "/Obj/OBJ/Python/SCons/scons/build/scons/setup.py", line 221, in ?
apply(distutils.core.setup, (), arguments)
File "/usr/local/lib/python2.4/distutils/core.py", line 149, in setup
dist.run_commands()
File "/usr/local/lib/python2.4/distutils/dist.py", line 946, in
run_commands
self.run_command(cmd)
File "/usr/local/lib/python2.4/distutils/dist.py", line 966, in
run_command
cmd_obj.run()
File "/usr/local/lib/python2.4/distutils/command/bdist_wininst.py",
line 127, in run
assert self.skip_build, "Should have already checked this"
AssertionError: Should have already checked this
scons: *** [build/scons/dist/scons-0.96.win32.exe] Error 1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ^^^^^^^^^

Remember this is a build on a Linux machine.
This install procedure is claimed to work with Python 2.3.x .

Thanks for any hints,
Helmut.
--
Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
Jul 18 '05 #1
2 1633
Helmut Jarausch <ja******@skynet.be> writes:
Hi,

I'd like to install SCons (http://www.scons.org) on my Linux box.
There, the cvs version of Python is running.
Doing as recommended in the README file

export SCONS_LIB_DIR=`pwd`/src/engine
python src/script/scons.py build/scons

I get after some time
/usr/local/bin/python build/scons/setup.py bdist_wininst
running bdist_wininst
running build
running build_py
running build_scripts
Traceback (most recent call last):
File "/Obj/OBJ/Python/SCons/scons/build/scons/setup.py", line 221, in ?
apply(distutils.core.setup, (), arguments)
File "/usr/local/lib/python2.4/distutils/core.py", line 149, in setup
dist.run_commands()
File "/usr/local/lib/python2.4/distutils/dist.py", line 946, in
run_commands
self.run_command(cmd)
File "/usr/local/lib/python2.4/distutils/dist.py", line 966, in
run_command
cmd_obj.run()
File "/usr/local/lib/python2.4/distutils/command/bdist_wininst.py",
line 127, in run
assert self.skip_build, "Should have already checked this"
AssertionError: Should have already checked this
scons: *** [build/scons/dist/scons-0.96.win32.exe] Error 1
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> ^^^^^^^^^

Remember this is a build on a Linux machine.
This install procedure is claimed to work with Python 2.3.x .


Seems like a bug to me. And it has nothing to do with Linux or not - it
is triggered if the distribution doesn't have any extension modules.

A quick fix is this patch, at least it works for me:

Thomas

Index: bdist_wininst.py
================================================== =================
RCS file: /cvsroot/python/python/dist/src/Lib/distutils/command/bdist_wininst.py,v
retrieving revision 1.54
diff -c -r1.54 bdist_wininst.py
*** bdist_wininst.py 17 Aug 2004 10:15:07 -0000 1.54
--- bdist_wininst.py 27 Oct 2004 15:11:11 -0000
***************
*** 116,135 ****
install_lib.compile = 0
install_lib.optimize = 0

! # If we are building an installer for a Python version other
! # than the one we are currently running, then we need to ensure
! # our build_lib reflects the other Python version rather than ours.
! # Note that for target_version!=sys.version, we must have skipped the
! # build step, so there is no issue with enforcing the build of this
! # version.
! target_version = self.target_version
! if not target_version:
! assert self.skip_build, "Should have already checked this"
! target_version = sys.version[0:3]
! plat_specifier = ".%s-%s" % (get_platform(), target_version)
! build = self.get_finalized_command('build')
! build.build_lib = os.path.join(build.build_base,
! 'lib' + plat_specifier)

# Use a custom scheme for the zip-file, because we have to decide
# at installation time which scheme to use.
--- 116,136 ----
install_lib.compile = 0
install_lib.optimize = 0

! if self.distribution.has_ext_modules():
! # If we are building an installer for a Python version other
! # than the one we are currently running, then we need to ensure
! # our build_lib reflects the other Python version rather than ours.
! # Note that for target_version!=sys.version, we must have skipped the
! # build step, so there is no issue with enforcing the build of this
! # version.
! target_version = self.target_version
! if not target_version:
! assert self.skip_build, "Should have already checked this"
! target_version = sys.version[0:3]
! plat_specifier = ".%s-%s" % (get_platform(), target_version)
! build = self.get_finalized_command('build')
! build.build_lib = os.path.join(build.build_base,
! 'lib' + plat_specifier)

# Use a custom scheme for the zip-file, because we have to decide
# at installation time which scheme to use.
Jul 18 '05 #2
Many thanks,
hopefully it makes it into the CVS,

Helmut.
Thomas Heller wrote:
Seems like a bug to me. And it has nothing to do with Linux or not - it
is triggered if the distribution doesn't have any extension modules.

A quick fix is this patch, at least it works for me:

Thomas

Index: bdist_wininst.py
================================================== =================
RCS file: /cvsroot/python/python/dist/src/Lib/distutils/command/bdist_wininst.py,v
retrieving revision 1.54
diff -c -r1.54 bdist_wininst.py
*** bdist_wininst.py 17 Aug 2004 10:15:07 -0000 1.54
--- bdist_wininst.py 27 Oct 2004 15:11:11 -0000
***************
*** 116,135 ****
install_lib.compile = 0
install_lib.optimize = 0

! # If we are building an installer for a Python version other
! # than the one we are currently running, then we need to ensure
! # our build_lib reflects the other Python version rather than ours.
! # Note that for target_version!=sys.version, we must have skipped the
! # build step, so there is no issue with enforcing the build of this
! # version.
! target_version = self.target_version
! if not target_version:
! assert self.skip_build, "Should have already checked this"
! target_version = sys.version[0:3]
! plat_specifier = ".%s-%s" % (get_platform(), target_version)
! build = self.get_finalized_command('build')
! build.build_lib = os.path.join(build.build_base,
! 'lib' + plat_specifier)

# Use a custom scheme for the zip-file, because we have to decide
# at installation time which scheme to use.
--- 116,136 ----
install_lib.compile = 0
install_lib.optimize = 0

! if self.distribution.has_ext_modules():
! # If we are building an installer for a Python version other
! # than the one we are currently running, then we need to ensure
! # our build_lib reflects the other Python version rather than ours.
! # Note that for target_version!=sys.version, we must have skipped the
! # build step, so there is no issue with enforcing the build of this
! # version.
! target_version = self.target_version
! if not target_version:
! assert self.skip_build, "Should have already checked this"
! target_version = sys.version[0:3]
! plat_specifier = ".%s-%s" % (get_platform(), target_version)
! build = self.get_finalized_command('build')
! build.build_lib = os.path.join(build.build_base,
! 'lib' + plat_specifier)

# Use a custom scheme for the zip-file, because we have to decide
# at installation time which scheme to use.

--
Helmut Jarausch

Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
Jul 18 '05 #3

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

Similar topics

0
by: Holger Joukl | last post by:
Hi, what version of python are you using? I got the same error when invoking a customized, 2-year-old version of distutils with python 2.3.3 (instead of 1.5.2, as before). Reason is code in...
4
by: Jesper Olsen | last post by:
Hi, I have a C-extention build with distutils that I would like to debug. How can I specify to distuils to pass option "-g" and not "-O2" along to the compiler (gcc)? Jesper
11
by: Kostatus | last post by:
I have a virtual function in a base class, which is then overwritten by a function of the same name in a publically derived class. When I call the function using a pointer to the derived class...
117
by: Peter Olcott | last post by:
www.halting-problem.com
0
by: gatti | last post by:
When building a C extension, Distutils standard command 'install' calls the 'build' command before performing the installation (see Lib/distutils/command/install.py and build.py). Reusing the...
2
by: Robert Creager | last post by:
I'm receiving the following error during startup: Aug 10 14:11:27 thunder postgres: LOG: failed to create socket: Address family not supported by protocol Aug 10 14:11:27 thunder postgres: ...
6
by: Jeff Davis | last post by:
After installing PostgreSQL 7.4 beta 1 from source, I decided to install the /contrib module tsearch2. I cd to the tsearch2 directory and typed "make", however I get an error that...
18
by: Ian Stanley | last post by:
Hi, Continuing my strcat segmentation fault posting- I have a problem which occurs when appending two sting literals using strcat. I have tried to fix it by writing my own function that does the...
28
by: Jon Davis | last post by:
If I have a class with a virtual method, and a child class that overrides the virtual method, and then I create an instance of the child class AS A base class... BaseClass bc = new ChildClass();...
0
by: Terry Reedy | last post by:
"??" <littlesweetmelon@gmail.comwrote in message news:cdb837ea0806050201l10a91b40xfa28d29de18fed30@mail.gmail.com... | When you use distutil to trigger compilation, a special *python script* |...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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.