This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Fix compile/link when using Darwin 8
Type: Stage:
Components: macOS Versions: Python 2.4
process
Status: closed Resolution: accepted
Dependencies: Superseder:
Assigned To: bob.ippolito Nosy List: bob.ippolito, jackjansen, loewis
Priority: normal Keywords: patch

Created on 2005-03-28 10:13 by bob.ippolito, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
darwin-configure-2.4.1-2.diff bob.ippolito, 2005-03-28 17:51 darwin-configure-2.4.1-2.diff
Messages (15)
msg48070 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 10:13
(this is the 2.4-maint backport of 1171735)

Darwin 8's headers are anal about POSIX compliance, and linking 
has changed (prebinding is now deprecated, and libcc_dynamic no 
longer exists). This configure patch makes things right.
msg48071 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 10:19
Logged In: YES 
user_id=139309

... patch small enough to upload, using same autoconf version as what 
was used by CVS
msg48072 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2005-03-28 15:13
Logged In: YES 
user_id=21627

In the comment as to why this disables platform specific
features beyond repair, please list specific examples (e.g.
the first one that is encountered); please also put your
name as the one to ask for further details into this comment.

Also, I would prefer this not to talk about versions whose
development has not started yet (ie. 8.*), unless there is
some really strong indication that none of the 8.* releases
will provide a solution.
msg48073 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 16:26
Logged In: YES 
user_id=139309

I would prefer to not talk about versions that have not been released 
publicly yet too (it has been in development for quite some time), but it's 
going to be released with this bug, and we want Python to compile on this 
platform.

I need to make some updates to these patches, and will improve the 
comment at that time.
msg48074 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2005-03-28 16:55
Logged In: YES 
user_id=21627

I'm fine with this patch applying to 8.0 (or whatever it is
going to be called); my concern is that it is unclear
(atleast to me) whether the problem will still exist in,
say, 8.5.
msg48075 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 17:04
Logged In: YES 
user_id=139309

That's up to them.. I don't have access to that kind of information.  We'll 
know when a new set of headers are released.  In my experience with 
the platform, it is very rare that headers are modified in any way after 
release, until the next major version.  So my guess is that the problem 
will still exist in 8.5.

It doesn't matter so much either way, turning these defines off doesn't 
break anything.  On this platform, they are used almost exclusively to 
turn off behavior, not to enable or change behavior.  I'm perfectly willing 
to revise the patch when/if it's fixed in the headers, but I think that will 
be a while.
msg48076 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 17:51
Logged In: YES 
user_id=139309

This is an updated version of the patch.  When using gcc4, libcc_dynamic 
does not exist.  Previous versions of gcc require it.  So the linker flags are 
dependent on the gcc version.

This fixes compilation on Darwin >= 8 with gcc < 4.0 (gcc 4 is the default)
msg48077 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2005-03-28 17:56
Logged In: YES 
user_id=21627

Ok, this is fine then. The other option would have been to
explicitly state 8.0, instead of 8.*, and extend that to
8.[01] when 8.1 is released and still shows the problem, and
so on. I really wish Apple would provide a #define to turn
on additional features.
msg48078 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 18:03
Logged In: YES 
user_id=139309

I wish Apple would have an additional #define too, but they don't.

The other option sounds bad.  On the first minor kernel update, Python 
won't compile any more.  In the manner I applied the patch, a minor kernel 
update will not break anything.  When they fix the headers, we can fix 
Python's configure on our own schedule, since this patch won't regress 
with fixed headers.
msg48079 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2005-03-28 19:01
Logged In: YES 
user_id=21627

I'm concerned that this section in configure.in might
collect old cruft, without a chance of ever getting rid of
it. Therefore, in general, I would like to see each setting
be reconsidered every time a new OS release is made;
allowing for removal of settings for systems that are not
supported any longer.

In the specific case, this is probably fine as-is, since
"Darwin 8.*" will likely be superceded with Darwin 9.0
within a few years, at which point the issue then is
reconsidered.
msg48080 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 19:09
Logged In: YES 
user_id=139309

I agree, and I will fix it when the headers allow such a fix.

I just don't want to see a minor OS update break all current versions of 
Python, such that we have to issue a patch and accelerate a release.  I 
also don't want it to be specific to Darwin 8.*, because chances are, 
Darwin 9 is going to be more like Darwin 8 than previous versions... so it 
makes sense to default to whatever worked most recently.
msg48081 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 19:23
Logged In: YES 
user_id=139309

Apparently I don't have write access to this part of CVS yet, so I can't 
commit this.  Here's the commit message I would've used:

patch [1171767] - Darwin 8's headers disable functionality when POSIX
is enabled.  This prevents the toolbox glue, all of Carbon, and various
other non-POSIX features from compiling.  The POSIX symbols are 
stillused by default, so turning off the #define doesn't hurt.

Additionally, linker flags have changed for Darwin 8, and are different
for Darwin 8/gcc4 (default) and Darwin 8/gcc3.3.  

Approved by Anthony 
msg48082 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2005-03-28 20:38
Logged In: YES 
user_id=21627

Hmm; I can't see anything wrong with your user settings, so
you should have write access in theory. Can you do checkouts
using your SSH key?
msg48083 - (view) Author: Bob Ippolito (bob.ippolito) * (Python committer) Date: 2005-03-28 23:25
Logged In: YES 
user_id=139309

nice catch!  you're right, my release24-maint wasn't checked out with SSH.  
I did have access to commit.  Thanks.
msg48084 - (view) Author: Jack Jansen (jackjansen) * (Python committer) Date: 2005-03-31 10:40
Logged In: YES 
user_id=45365

Adding this information here for reference: rumour has it that Apple is 
actively thinking of ways to fix the POSIX_C_SOURCE problems (i.e. the 
fact that this define disables some features while enabling others), 
probably through a different define that you can use together with 
POSIX_C_SOURCE to re-enable apple-specific additions or something like 
that.

So, we should keep our eyes open for this.
History
Date User Action Args
2022-04-11 14:56:10adminsetgithub: 41767
2005-03-28 10:13:53bob.ippolitocreate