This is an additional fix for clang 16, which fails due to an undeclared
symbol. Adding `_DNS_SD_LIBDISPATCH` makes the symbol visible in
`dns_sd.h`, allowing the build to complete successfully.
A number of headers in Libc are being vendored from other packages.
Instead of copying them from an earlier Libc, Libsystem now sources them
from their respective packages (see below). This allows Libc_old to be
dropped and avoids any potential clashes when building Libsystem.
libmalloc:
* malloc/malloc.h
libplatform:
* setjmp.h
* ucontext.h
* libkern/OSAtomic.h
* libkern/OSCacheControl.h
libpthread:
* pthread*.h
* sched.h
* spawn.h
syslog (vendored because only one file is needed):
* asl.h
xnu:
* spawn.h (a different one from libpthread)
* libproc.h
Clang 16 makes implicit declarations an error by default. The headers
are available, so include them.
`getline` was renamed to `get_line` to avoid a name clash. `util.h`
includes `stdio.h`, which defines `getline`.
Clang 15 does not like the fake xpc headers. Use the real ones instead.
Doing this no longer causes an infinite recursion because xnu now
depends on python3Minimal, which does not include configd support.
This fixes build failures caused by LibreSSL 3.4 being marked insecure
and allows it to be dropped from nixpkgs. Unbound is already not built
on aarch64-darwin, and it is not bundled with newer source releases.
Packages that require Unbound should depend on `unbound` from nixpkgs
instead of getting it indirectly from `darwin.network_cmds`.
with structuredAttrs lists will be bash arrays which cannot be exported
which will be a issue with some patches and some wrappers like cc-wrapper
this makes it clearer that NIX_CFLAGS_COMPILE must be a string as lists
in env cause a eval failure
7abd144913 switched the source releases to
pull from GitHub. This resulted in the IOUSBFamily installation failing,
as the extracted directory's name changed from `IOUSBFamily-630.4.5` to
`IOUSBFamily-IOUSBFamily-630.4.5`. This didn't occur for any other frameworks
because we used wildcards for copying them already.
What dtrace needs from the CoreSymbolication private framework on Darwin
is provided in Nixpkgs by two different packages, but both of their full
attribute paths end in CoreSymbolication.
This commit therefore does two things:
- adds the second CoreSymbolication package to dtrace's dependencies;
and
- adds an alias for the second CoreSymbolication package to avoid
having to explicitly name or rename it when calling the dtrace
package in the existing contexts.