[Python-bugs-list] [ python-Bugs-542482 ] Problem compiling Python

noreply@sourceforge.net noreply@sourceforge.net
Fri, 01 Nov 2002 18:45:06 -0800


Bugs item #542482, was opened at 2002-04-11 08:48
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=542482&group_id=5470

>Category: Build
>Group: Python 2.2.1
Status: Open
Resolution: None
Priority: 5
Submitted By: Pierre (pierre42)
Assigned to: Nobody/Anonymous (nobody)
Summary: Problem compiling Python

Initial Comment:
Hi,

I try to compile Python-2.2.1 on my linux slackware 8
with gcc-3.0.4
there was no problem with the configure, but for the
make i got this :

# gmake
gcc -c -DNDEBUG -g -O3 -march=i686 -Wall
-Wstrict-prototypes -I. -I./Include -DHAVE_CONFIG_H  -o
Python/thread.o Python/thread.c
In file included from Python/thread.c:109:
Python/thread_pth.h: In function
`PyThread_start_new_thread':
Python/thread_pth.h:59: warning: return makes integer
from pointer without a cast
In file included from Python/thread.c:113:
Python/thread_pthread.h:113:1: warning: "CHECK_STATUS"
redefined
Python/thread_pth.h:31:1: warning: this is the location
of the previous definition
In file included from Python/thread.c:113:
Python/thread_pthread.h: At top level:
Python/thread_pthread.h:139: redefinition of
`PyThread__init_thread'
Python/thread_pth.h:38: `PyThread__init_thread'
previously defined here
Python/thread_pthread.h:154: redefinition of
`PyThread_start_new_thread'
Python/thread_pth.h:48: `PyThread_start_new_thread'
previously defined here
Python/thread_pthread.h:235: redefinition of
`PyThread_get_thread_ident'
Python/thread_pth.h:63: `PyThread_get_thread_ident'
previously defined here
Python/thread_pthread.h:250: redefinition of
`do_PyThread_exit_thread'
Python/thread_pth.h:73: `do_PyThread_exit_thread'
previously defined here
Python/thread_pthread.h:262: redefinition of
`PyThread_exit_thread'
Python/thread_pth.h:84: `PyThread_exit_thread'
previously defined here
Python/thread_pthread.h:268: redefinition of
`PyThread__exit_thread'
Python/thread_pth.h:89: `PyThread__exit_thread'
previously defined here
Python/thread_pthread.h:302: redefinition of
`PyThread_allocate_lock'
Python/thread_pth.h:119: `PyThread_allocate_lock'
previously defined here
Python/thread_pthread.h:335: redefinition of
`PyThread_free_lock'
Python/thread_pth.h:145: `PyThread_free_lock'
previously defined here
Python/thread_pthread.h:352: redefinition of
`PyThread_acquire_lock'
Python/thread_pth.h:154: `PyThread_acquire_lock'
previously defined here
Python/thread_pthread.h:390: redefinition of
`PyThread_release_lock'
Python/thread_pth.h:191: `PyThread_release_lock'
previously defined here
Python/thread_pthread.h:413: redefinition of `struct
semaphore'
Python/thread_pthread.h:421: redefinition of
`PyThread_allocate_sema'
Python/thread_pth.h:221: `PyThread_allocate_sema'
previously defined here
Python/thread_pthread.h:449: redefinition of
`PyThread_free_sema'
Python/thread_pth.h:246: `PyThread_free_sema'
previously defined here
Python/thread_pthread.h:463: redefinition of
`PyThread_down_sema'
Python/thread_pth.h:254: `PyThread_down_sema'
previously defined here
Python/thread_pthread.h:493: redefinition of
`PyThread_up_sema'
Python/thread_pth.h:283: `PyThread_up_sema' previously
defined here
gmake: *** [Python/thread.o] Error 1


It would be great if you could help me with this !

Best regards,

Pierre.




----------------------------------------------------------------------

>Comment By: Neal Norwitz (nnorwitz)
Date: 2002-11-01 21:45

Message:
Logged In: YES 
user_id=33168

Is this still a problem w/2.2.2?

----------------------------------------------------------------------

Comment By: Martin v. L÷wis (loewis)
Date: 2002-04-13 19:04

Message:
Logged In: YES 
user_id=21627

You are right; this is the intention. It turns out that a 
configuration of an alternate thread library is not 
supported if pthreads are also available on the system. 
 
I'll try to come up with a work-around, but this is not 
high-priority, and may take a while. 

----------------------------------------------------------------------

Comment By: Pierre (pierre42)
Date: 2002-04-13 09:18

Message:
Logged In: YES 
user_id=512388

I did ./configure  --with-threads --with-pth
I thought it means "enable thread support, and for this use
gnu pth". 

----------------------------------------------------------------------

Comment By: Martin v. L÷wis (loewis)
Date: 2002-04-13 04:31

Message:
Logged In: YES 
user_id=21627

I think I can see the problem now. For some reason, Python
tries to use both GNU pth and pthreads for threading; this
cannot work.

How did you invoke configure?

----------------------------------------------------------------------

Comment By: Pierre (pierre42)
Date: 2002-04-12 22:29

Message:
Logged In: YES 
user_id=512388

In fact i can't attach the file thread.i, it is too big :(

----------------------------------------------------------------------

Comment By: Pierre (pierre42)
Date: 2002-04-12 22:26

Message:
Logged In: YES 
user_id=512388

Ok i have done :

root@pierre:/tmp/Python-2.2.1# gcc -c -DNDEBUG -g -O3
-march=i686 -Wall -Wstrict-prototypes -dD --save-temps
--trace-includes -I. -I./Include -DHAVE_CONFIG_H  -o
Python/thread.o Python/thread.c >& compile.log

I attach you the file compile.log and the file thread.i


----------------------------------------------------------------------

Comment By: Martin v. L÷wis (loewis)
Date: 2002-04-11 17:59

Message:
Logged In: YES 
user_id=21627

Can you please add the options "-dD --save-temps
--trace-includes" to the gcc invocation, and attach both the
compiler (error) output and thread.i to this report?

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=542482&group_id=5470