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

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

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
3 11506
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
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
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 thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: pmiller | last post by:
I ported my code from the development to application platform, I found a "type error" on a fileout statement: outfile.write(object.id +",") Object.id is provided by a library routine that is...
20
by: elderic | last post by:
Hi there, are there other ways than the ones below to check for <type 'function'> in a python script? (partly inspired by wrapping Tkinter :P) def f(): print "This is f(). Godspeed!" 1.:...
3
by: tanusreesen | last post by:
Hi All, I am completely new to python programming language.I was trying to write a program on class.But I am getting this error.Can someone please help me to solve the error I am facing.I...
0
by: txtoth | last post by:
I'm trying to map a security_context_t ** to a python list. After calling the method that returns this type when I process the returned list in a for loop I get: TypeError: expected string or...
2
by: J. Peng | last post by:
Python's variable is dynamic type,is it? But why this can't work? Traceback (most recent call last): File "<stdin>", line 1, in ? TypeError: unsupported operand type(s) for +: 'int' and 'str' ...
2
by: Jordan Harry | last post by:
I'm trying to write a simple program to calculate permutations. I created a file called "mod.py" and put the following in it: def factorial(n): a = n b = n while a>0 and b>1: n = (n)*(b-1)...
6
by: Rafe | last post by:
Forgive me if I mangle any terminology here, but please correct me if I do... I have an object which acts exactly like a string as long as I stay in Python land. However, I am using the object...
1
by: flapjacks | last post by:
line1 = ((0.0, -1.0), (1.0, 1.0), (2.0, 3.0), (3.0, 5.0), (4.0, 7.0), (5.0, 9.0), (6.0, 11.0), (7.0, 13.0), (8.0, 15.0), (9.0, 17.0)) line2 = ((0.0, 2.0), (1.0, 1.0), (2.0, 0.0), (3.0, -1.0), (4.0,...
3
by: smiths7 | last post by:
Hey guys, I'm new to python and tkinter and am building a quote module thats interface is up and running but the button definitions arent working and i get an error when my "QUOTE" button is...
0
by: VivesProcSPL | last post by:
Obviously, one of the original purposes of SQL is to make data query processing easy. The language uses many English-like terms and syntax in an effort to make it easy to learn, particularly for...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
0
by: jianzs | last post by:
Introduction Cloud-native applications are conventionally identified as those designed and nurtured on cloud infrastructure. Such applications, rooted in cloud technologies, skillfully benefit from...
0
by: mar23 | last post by:
Here's the situation. I have a form called frmDiceInventory with subform called subfrmDice. The subform's control source is linked to a query called qryDiceInventory. I've been trying to pick up the...
0
by: fareedcanada | last post by:
Hello I am trying to split number on their count. suppose i have 121314151617 (12cnt) then number should be split like 12,13,14,15,16,17 and if 11314151617 (11cnt) then should be split like...
0
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
0
Git
by: egorbl4 | last post by:
Скачал я git, хотел начать настройку, а там вылезло вот это Что это? Что мне с этим делать? ...
1
by: davi5007 | last post by:
Hi, Basically, I am trying to automate a field named TraceabilityNo into a web page from an access form. I've got the serial held in the variable strSearchString. How can I get this into the...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....

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.