By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,558 Members | 1,399 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,558 IT Pros & Developers. It's quick & easy.

TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'

P: n/a
Hello,

Ik get the following error when I install a new Python software
package such as Zope or PIL.

This is what I get whem I 'make' Zope :

running build_ext
Traceback (most recent call last):
File "/usr/local/zope/Zope-2.7.2-0/setup.py", line 1091, in ?
distclass=ZopeDistribution,
File "/usr/local/lib/python2.3/distutils/core.py", line 149, in
setup
dist.run_commands()
File "/usr/local/lib/python2.3/distutils/dist.py", line 907, in
run_commands
self.run_command(cmd)
File "/usr/local/lib/python2.3/distutils/dist.py", line 927, in
run_command
cmd_obj.run()
File "/usr/local/lib/python2.3/distutils/command/build.py", line
107, in run
self.run_command(cmd_name)
File "/usr/local/lib/python2.3/distutils/cmd.py", line 333, in
run_command
self.distribution.run_command(command)
File "/usr/local/lib/python2.3/distutils/dist.py", line 927, in
run_command
cmd_obj.run()
File "/usr/local/lib/python2.3/distutils/command/build_ext.py", line
244, in run
customize_compiler(self.compiler)
File "/usr/local/lib/python2.3/distutils/sysconfig.py", line 159, in
customize_compiler
cpp = cc + " -E" # not always
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'
make: *** [build] Error 1
../configure has finisched withoud problems.

System : Fedora Core 2
Python 2.3.3
What is wrong here ?

Greetings,

Martin Koekenberg
Jul 18 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Hi Martin,
File "/usr/local/lib/python2.3/distutils/sysconfig.py", line 159, in
customize_compiler
cpp = cc + " -E" # not always
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'
make: *** [build] Error 1


Judging by the error I'm guessing that you might not have a c or c++
compiler installed. Run the following command to check if you have the
required rpms:

rpm -q gcc
rpm -q gcc-c++

Install them if you they are missing and then rerun 'configure' and 'make'.

HTH
Steve
Jul 18 '05 #2

P: n/a
Hello Steve,

That is not the problem.
gcc-3.3.3-7 and gcc-c++-3.3.3-7 are installed.

Greetings,

Martin Koekenberg
On Fri, 20 Aug 2004 14:12:50 +0530, Steve <lo******@gmail.com> wrote:
Hi Martin,
File "/usr/local/lib/python2.3/distutils/sysconfig.py", line 159, in
customize_compiler
cpp = cc + " -E" # not always
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'
make: *** [build] Error 1


Judging by the error I'm guessing that you might not have a c or c++
compiler installed. Run the following command to check if you have the
required rpms:

rpm -q gcc
rpm -q gcc-c++

Install them if you they are missing and then rerun 'configure' and 'make'.

HTH
Steve


Jul 18 '05 #3

P: n/a
Ok mayby that is the solution. but....

How do I set this environmet variable ??
I don't have a lot of linux experience ;-)

Thanks,

Martin Koekenberg

On 25 Aug 2004 15:54:58 -0700, "Brett C." <br***@python.org> wrote:
Set your environment 'CC' environment variable to gcc and it should go
away.


Jul 18 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.