2021-05-28 09:39:13 +00:00
|
|
|
{ appleDerivation', stdenvNoCC, ed, unifdef, Libc_old, Libc_10-9 }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-05-28 09:39:13 +00:00
|
|
|
appleDerivation' stdenvNoCC {
|
2020-04-24 23:36:52 +00:00
|
|
|
nativeBuildInputs = [ ed unifdef ];
|
|
|
|
|
2021-12-26 17:43:05 +00:00
|
|
|
patches = [
|
|
|
|
./0001-Define-TARGET_OS_EMBEDDED-in-std-lib-io-if-not-defin.patch
|
|
|
|
];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
# TODO: asl.h actually comes from syslog project now
|
|
|
|
installPhase = ''
|
|
|
|
export SRCROOT=$PWD
|
|
|
|
export DSTROOT=$out
|
|
|
|
export PUBLIC_HEADERS_FOLDER_PATH=include
|
|
|
|
export PRIVATE_HEADERS_FOLDER_PATH=include
|
|
|
|
bash xcodescripts/headers.sh
|
|
|
|
|
|
|
|
cp ${./CrashReporterClient.h} $out/include/CrashReporterClient.h
|
|
|
|
|
|
|
|
cp ${Libc_10-9}/include/NSSystemDirectories.h $out/include
|
|
|
|
|
|
|
|
# Ugh Apple stopped releasing this stuff so we need an older one...
|
|
|
|
cp ${Libc_old}/include/spawn.h $out/include
|
|
|
|
cp ${Libc_old}/include/setjmp.h $out/include
|
|
|
|
cp ${Libc_old}/include/ucontext.h $out/include
|
|
|
|
cp ${Libc_old}/include/pthread*.h $out/include
|
|
|
|
cp ${Libc_old}/include/sched.h $out/include
|
|
|
|
cp -R ${Libc_old}/include/malloc $out/include
|
|
|
|
|
|
|
|
mkdir -p $out/include/libkern
|
|
|
|
cp ${Libc_old}/include/asl.h $out/include
|
|
|
|
cp ${Libc_old}/include/libproc.h $out/include
|
|
|
|
cp ${Libc_old}/include/libkern/OSAtomic.h $out/include/libkern
|
|
|
|
cp ${Libc_old}/include/libkern/OSCacheControl.h $out/include/libkern
|
|
|
|
'';
|
2021-02-19 19:06:45 +00:00
|
|
|
|
|
|
|
appleHeaders = builtins.readFile ./headers.txt;
|
2020-04-24 23:36:52 +00:00
|
|
|
}
|