Hi Iain,

>> On 30 Jun 2025, at 12:58, Rainer Orth <r...@cebitec.uni-bielefeld.de> wrote:
>> 
>> I recently noticed that libphobos isn't enable by default on 32-bit
>> Darwin with the target triples determined by config.guess.  E.g. on a
>> Darwin 15 system the target triple is something like
>> i386-apple-darwin15.6.0 while configure.tgt only matches
>> i?86-*-darwin1[2-7].
>> 
>> This patch also allows such minor and micro versions.
>> 
>> Tested on i386-apple-darwin15.6.0.
>> 
>> I'd commit this as obvious, but there's more: on older Darwin versions
>> (9, 10, and 11), configure.tgt only sets LIBDRUNTIME_ONLY.
>
> For Darwin9 the xcode linker is not new enough to work (it needs at least
> the Darwin10 linker).  IIRC Darwin10 has some missing libc functionality
> that the wider libphobos (at least used to) uses.  I’d imagine some of the
> fails you see on Darwin11 could be in a similar category.

in that case it would probably be best to remove *-*-darwin9* from
libphobos/configure.tgt.

As for Darwin 10, I remembered that when I `inherited' an ancient
Xserve3,1 running Mac OS X 10.6/Darwin 10, I tried building GCC trunk
back in 2023.

It did indeed lack a couple of libc functions (arc4random_buf, getdelim,
__fork), breaking the libphobos build.  I still have a patch to handle
this, but overall Darwin 10 proved to be so tedious that I've never
posted it and since upgraded the system to Mac OS X 10.11/Darwin 15

I guess it's best to leave 10.6 buried for good :-)

>>  However,
>> toplevel configure.ac doesn't take this into account when deciding
>> whether to enable libphobos or not.  I wonder if it should, though.`
>
> I *think* that’s right - we want to enable libphobos but only the minimal
> druntime?

Exactly: that's what my test results are from.

>>  I
>> guess it could: on my Darwin 11 system, test results (with explicit
>> --enable-libphobos) aren't too bad:
>
> <snip>
>> 
>> 
>> Thoughts?
>
> Certainly, the configure.tgt fix is OK - that’s a slip-up.  It’s also OK
> to enable libphobos for Darwin11 if that’s going to get reasonable testing,
> but I was not planning on trying to fix outstanding issues there.

I still bootstrap Darwin 11 once a week (both 64-bit-default and
32-bit-default), but pay little attention to the results except for
broken builds or massive increases in testsuite failues.

> I would avoid Darwin10 for now, and Darwin <= 9 is a non-starter
> without some additional configury to detect a usable linker version.

That would leave us with only Darwin 11 in the LIBDRUNTIME_ONLY category
right now.  I guess given the age of those OS versions, we might just as
well leave things as they are while I continue to build with
--enable-libphobos.

Thanks.
        Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University

Reply via email to