Issue1358
Created on 2007-10-29 18:14 by andres, last changed 2007-12-01 15:21 by ronaldoussoren.
|
msg56921 - (view) |
Author: andres (andres) |
Date: 2007-10-29 18:14 |
|
Compiling python 2.5.1 on Mac OS X 10.5 (Leopard) fails with the
following message:
gcc -fno-strict-aliasing -Wno-long-double -no-cpp-precomp
-mno-fused-madd -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -I.
-I./Include -DPy_BUILD_CORE -c ./Modules/posixmodule.c -o
Modules/posixmodule.o
./Modules/posixmodule.c: In function ‘posix_setpgrp’:
./Modules/posixmodule.c:3592: error: too few arguments to function ‘setpgrp’
make: *** [Modules/posixmodule.o] Error 1
I am also attaching the output of the configuration script.
|
|
msg56926 - (view) |
Author: Martin v. Löwis (loewis) |
Date: 2007-10-29 20:00 |
|
Can you please also attach config.log (perhaps compressed)?
|
|
msg56936 - (view) |
Author: andres (andres) |
Date: 2007-10-29 21:50 |
|
I've attached a compressed config.log.
Incidentally, we were able to get Python to compile by appending the
following line to pyconfig.h:
#define SETPGRP_HAVE_ARG
-Andres
On Oct 29, 2007, at 1:00 PM, Martin v. Löwis wrote:
>
> Martin v. Löwis added the comment:
>
> Can you please also attach config.log (perhaps compressed)?
>
> ----------
> nosy: +loewis
>
> __________________________________
> Tracker <report@bugs.python.org>
> <http://bugs.python.org/issue1358>
> __________________________________
|
|
msg56962 - (view) |
Author: Guido van Rossum (gvanrossum) |
Date: 2007-10-30 14:40 |
|
Thanks for testing on Leopard! I haven't gotten that yet.
Assigning to Neal since this ought to be fixed before 2.5.2 is released.
(But someone needs to come up with a proper patch.)
|
|
msg56980 - (view) |
Author: Martin v. Löwis (loewis) |
Date: 2007-10-30 21:00 |
|
There is an autoconf test that tries to compile
| #include <unistd.h>
| int
| main ()
| {
| setpgrp(0,0);
| ;
| return 0;
| }
(with many additional defines - see config.log.gz). This file compiles
with the error message
conftest.c:185: error: too many arguments to function 'setpgrp'
hence configure concludes that SETPGRP_HAVE_ARG should *not* be defined
- yet you say it works when it is defined.
Can somebody with access to the system resolve this mystery? Studying
the header file that has the setpgrp declaration is probably necessary.
|
|
msg56985 - (view) |
Author: Neal Norwitz (nnorwitz) |
Date: 2007-10-31 05:04 |
|
I don't have access to a 10.5 machine. My guess is that the difference
is between configure not setting _XOPEN_SOURCE and/or
_XOPEN_SOURCE_EXTENDED and it being set in pyconfig.h. At least those
are both defined on 10.4.
This page talks about needing to include unistd.h, but doesn't give
enough info:
http://developer.apple.com/documentation/Darwin/Reference/Manpages/man2/setpgid.2.html
Hopefully someone else with access to 10.5 can confirm if this is the
case and we can resolve this.
|
|
msg57755 - (view) |
Author: Simon Percivall (percivall) |
Date: 2007-11-22 10:57 |
|
It has to do with the MACOSX_DEPLOYMENT_TARGET. If it's set to 10.4, the
legacy version of setpgrp is used (with args), it it's 10.5, setpgrp
expects no arguments. It seems configure won't detect the difference.
|
|
msg57836 - (view) |
Author: Guido van Rossum (gvanrossum) |
Date: 2007-11-26 02:57 |
|
IMO it should be set to 10.4 since we want binaries that run on that
platform too. Is this something we can fix in the configure script?
|
|
msg58050 - (view) |
Author: Ronald Oussoren (ronaldoussoren) |
Date: 2007-12-01 15:21 |
|
This issue is fixed in the trunk and python2.5 branch.
To work around this issue with the 2.5.1 source tree you have to set
MACOSX_DEPLOYMENT_TARGET when configuring python:
../configure <insert-args-here> MACOSX_DEPLOYMENT_TARGET=10.3
(the value 10.3 is what configure picks by default, building with 10.5
as the target works as well). The problem is that configure picked a
deployment target for use during compilation of python itself, but
didn't use that during the configure phase. That causes configure to
pick up the wrong set of feature macros.
|
|
| Date |
User |
Action |
Args |
| 2007-12-01 15:21:29 | ronaldoussoren | set | status: open -> closed nosy:
+ ronaldoussoren resolution: fixed messages:
+ msg58050 |
| 2007-11-26 02:57:34 | gvanrossum | set | messages:
+ msg57836 |
| 2007-11-22 10:57:56 | percivall | set | nosy:
+ percivall messages:
+ msg57755 |
| 2007-10-31 05:04:01 | nnorwitz | set | messages:
+ msg56985 |
| 2007-10-30 21:00:39 | loewis | set | messages:
+ msg56980 |
| 2007-10-30 14:40:23 | gvanrossum | set | priority: release blocker assignee: nnorwitz messages:
+ msg56962 nosy:
+ gvanrossum, nnorwitz |
| 2007-10-29 21:50:49 | andres | set | files:
+ unnamed, config.log.gz, unnamed messages:
+ msg56936 |
| 2007-10-29 20:00:53 | loewis | set | nosy:
+ loewis messages:
+ msg56926 |
| 2007-10-29 18:14:49 | andres | create | |
|