472,325 Members | 1,768 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

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

python install settings...

hi,

i am running Linux Ubuntu Hoary and am trying to build the Python
numarray package, v. 1.3.2 by hand since ubuntu's repos won't be
updated until breezy.

i have python 2.4, and gcc 3.3.5

after unpacking the tar, i run "python setup.py install", as it says in
the installation instructions. i get the following:

[colfax 53] numarray-1.3.2 > python setup.py install
Using EXTRA_COMPILE_ARGS = []
running install
running build
running build_py
copying Lib/numinclude.py -> build/lib.linux-i686-2.4/numarray
running build_ext
Traceback (most recent call last):
File "setup.py", line 222, in ?
main()
File "setup.py", line 213, in main
setup(**p)
File "/usr/lib/python2.4/distutils/core.py", line 149, in setup
dist.run_commands()
File "/usr/lib/python2.4/distutils/dist.py", line 946, in
run_commands
self.run_command(cmd)
File "/usr/lib/python2.4/distutils/dist.py", line 966, in run_command
cmd_obj.run()
File "/usr/lib/python2.4/distutils/command/install.py", line 506, in
run
self.run_command('build')
File "/usr/lib/python2.4/distutils/cmd.py", line 333, in run_command
self.distribution.run_command(command)
File "/usr/lib/python2.4/distutils/dist.py", line 966, in run_command
cmd_obj.run()
File "/usr/lib/python2.4/distutils/command/build.py", line 112, in
run
self.run_command(cmd_name)
File "/usr/lib/python2.4/distutils/cmd.py", line 333, in run_command
self.distribution.run_command(command)
File "/usr/lib/python2.4/distutils/dist.py", line 966, in run_command
cmd_obj.run()
File "/usr/lib/python2.4/distutils/command/build_ext.py", line 254,
in run
customize_compiler(self.compiler)
File "/usr/lib/python2.4/distutils/sysconfig.py", line 174, in
customize_compiler
cc_cmd = cc + ' ' + opt
TypeError: cannot concatenate 'str' and 'NoneType' objects
I had a similiar (but different) error earlier, but then I learned I
had to set my "CC" environment variable. So I set that to "gcc". i have
tried setting my "OPT" setting to something like "-g 02" (no idea what
it means just found it somewhere, but it still didn't work.

upon closer inspection of Python's distutils sysconfig.py, is the error
being caused by the ' ' in "cc_cmd = cc + ' ' + opt"? Any ideas on this
new error? Are there packages/settings I need to take care of before i
can use Python's distutils to install stuff?

Thanks,
Jason

Jul 19 '05 #1
1 1939
"jtan325" <mr*********@gmail.com> writes:

customize_compiler
cc_cmd = cc + ' ' + opt
TypeError: cannot concatenate 'str' and 'NoneType' objects
[...]
upon closer inspection of Python's distutils sysconfig.py, is the error
being caused by the ' ' in "cc_cmd = cc + ' ' + opt"? Any ideas on this
new error? Are there packages/settings I need to take care of before i
can use Python's distutils to install stuff?


The error message indicates that one of the operands on the right side is
None. ' ' is clearly a string constant (string with one whitespace), so the
problem must be either cc or opt - one of them is None.

Toying a little I realized Python emits different warnings for pairs
cc, opt = None, 'cat' and
cc, opt = 'cat', None:
cc, opt = None, 'cat'
cc_cmd = cc + ' ' + opt Traceback (most recent call last):
File "<stdin>", line 1, in ?
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'

# note the different TypeError message below
cc, opt = 'cat', None
cc_cmd = cc + ' ' + opt

Traceback (most recent call last):
File "<stdin>", line 1, in ?
TypeError: cannot concatenate 'str' and 'NoneType' objects

So, for some reason, variable opt is None.

--
# Edvard Majakari Software Engineer
# PGP PUBLIC KEY available Soli Deo Gloria!

$_ = '456476617264204d616a616b6172692c20612043687269737 469616e20'; print
join('',map{chr hex}(split/(\w{2})/)),uc substr(crypt(60281449,'es'),2,4),"\n";
Jul 19 '05 #2

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

Similar topics

14
by: Franz Steinhäusler | last post by:
Hello, My second question from my last post (PyQt on Python 2.4), I think, is a little got under (i have installed both Python 2.3 and Python...
7
by: p | last post by:
WE had a Crystal 8 WebApp using vs 2002 which we upgraded to VS2003. I also have Crystal 9 pro on my development machine. The web app runs fine on...
5
by: Marcelo Gosling | last post by:
Hi, everyone. This is on WinXP SP2, with Python 2.4.3 and DJGPP gcc 4.1.0. I'm having trouble including Python.h in a C file. The following C...
0
by: Kurt B. Kaiser | last post by:
Patch / Bug Summary ___________________ Patches : 393 open (+15) / 3315 closed (+17) / 3708 total (+32) Bugs : 908 open (+22) / 5975...
4
by: jmg3000 | last post by:
What's the customary way to keep your own local Python and package directory? For example, when you're on a server where you don't have root...
14
by: TheFlyingDutchman | last post by:
I am trying to install Python 2.5 on Windows XP. It installs into the root directory on C:\ instead of C:\Python25 which it shows by default as...
4
by: Alia Khouri | last post by:
Can we open up the discussion here about how to improve setuptools which has become the de facto standard for distributing / installing python...
7
by: W. eWatson | last post by:
I copied the following code from a matplotlib tutorial, and it fails. I'm using python 2.4 on Win XP. It's matplotlib-0.98.3.win32-py2.4exe. It...
0
by: eGenix Team: M.-A. Lemburg | last post by:
________________________________________________________________________ ANNOUNCING eGenix.com mx Base Distribution Version 3.1.1 for Python...
0
by: tammygombez | last post by:
Hey fellow JavaFX developers, I'm currently working on a project that involves using a ComboBox in JavaFX, and I've run into a bit of an issue....
0
by: tammygombez | last post by:
Hey everyone! I've been researching gaming laptops lately, and I must say, they can get pretty expensive. However, I've come across some great...
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
by: CD Tom | last post by:
This happens in runtime 2013 and 2016. When a report is run and then closed a toolbar shows up and the only way to get it to go away is to right...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
0
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...

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.