darwin.apple-source-releases: implement headers check
This commit is contained in:
parent
4bc22226a2
commit
c12df57435
@ -165,6 +165,25 @@ let
|
|||||||
|
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
|
# In rare cases, APPLE may drop some headers quietly on new release.
|
||||||
|
doInstallCheck = attrs ? appleHeaders;
|
||||||
|
passAsFile = [ "appleHeaders" ];
|
||||||
|
installCheckPhase = ''
|
||||||
|
cd $out/include
|
||||||
|
|
||||||
|
result=$(diff -u "$appleHeadersPath" <(find * -type f | sort) --label "Listed in appleHeaders" --label "Found in \$out/include" || true)
|
||||||
|
|
||||||
|
if [ -z "$result" ]; then
|
||||||
|
echo "Apple header list is matched."
|
||||||
|
else
|
||||||
|
echo >&2 "\
|
||||||
|
Apple header list is inconsistent, please ensure no header file is unexpectedly dropped.
|
||||||
|
$result
|
||||||
|
"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
|
||||||
} // attrs // {
|
} // attrs // {
|
||||||
meta = (with lib; {
|
meta = (with lib; {
|
||||||
platforms = platforms.darwin;
|
platforms = platforms.darwin;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user