10.0 | 123.5 | ppc | |
10.0.1 | 124.1 | ppc | |
10.0.2 | 124.7 | ppc | |
10.0.3 | 124.8 | ppc | ???? |
10.0.4 | 124.13 | ppc | |
10.1 | 201 | ppc | |
10.1.1 | 201.5 | ppc | |
10.1.2 | 201.14 | ppc | |
10.1.3 | 201.19 | ppc | |
10.1.4 | 201.19.3 | ppc | |
10.1.5 | 201.42.3 | ppc | |
10.2 | 344 | ppc | |
10.2.1 | 344.2 | ppc | |
10.2.2 | 344.12.2 | ppc | |
10.2.3 | 344.23 | ppc | |
10.2.4 | 344.26 | ppc | |
10.2.5 | 344.32 | ppc | |
10.2.6 | 344.34 | ppc | |
10.2.8 | 344.49 | ppc | |
10.2.7 | 344.21.73 | g5/powerbook-specific; defective | |
10.2.8 | 344.21.74 | g5-specific | |
10.3 | 517 | ppc | |
10.3.1 | 517 | ppc | ???? |
10.3.2 | 517.3.7 | ppc | |
10.3.3 | 517.3.15 | ppc | |
10.3.4 | 517.7.7 | ppc | |
10.3.5 | 517.7.21 | ppc | |
10.3.6 | 517.9.4 | ppc | |
10.3.7 | 517.9.5 | ppc | |
10.3.8 | 517.11.1 | ppc | |
10.3.9 | 517.12.7 | ppc | |
10.4 | 792 | ppc | |
10.4.1 | 792.1.5 | ppc | |
10.4.2 | 792.2.4 | ppc | |
10.4.3 | 792.6.22 | ppc | |
10.4.4 | 792.6.56 | ppc | |
10.4.5 | 792.6.61 | ppc | |
10.4.6 | 792.6.70 | ppc | |
10.4.7 | 792.6.76 | ppc | |
10.4.7+ | 792.10.96 | x86 | |
10.4.8 | 792.13.8 | x86 | |
10.4.8 | 792.12.6 | ppc | |
10.4.9 | 792.17.14 | ppc | |
10.4.9 | 792.18.15 | x86 | |
10.4.10 | 792.21.3 | ppc | |
10.4.10 | 792.22.5 | x86 | |
10.4.11 | 792.24.17 | ppc | |
10.4.11 | 792.25.20 | x86 | |
10.5 | 1228 | x86,ppc | |
10.5.1 | 1228.0.2 | x86,ppc | |
10.5.2 | 1228.3.13 | x86,ppc | |
10.5.3 | 1228.5.18 | x86,ppc | |
10.5.4 | 1228.5.20 | x86,ppc | |
10.5.5 | 1228.7.58 | x86,ppc | |
10.5.6 | 1228.9.59 | x86,ppc | |
10.5.7 | 1228.12.14 | x86,ppc | |
10.5.8 | 1228.15.4 | x86,ppc | |
10.6 | 1456.1.26 | x86 | |
10.6.1 | 1456.1.26 | x86 | no change? |
10.6.2 | 1486.2.11 | x86 | |
10.6.3 | 1504.3.12 | x86 | |
10.6.4 | 1504.7.4 | x86 | |
10.6.5 | 1504.9.17 | x86 | |
10.6.6 | 1504.9.26 | x86 | |
10.6.7 | 1504.9.37 | x86 | |
10.6.8 | 1504.15.3 | x86 | |
10.7 | 1699.22.73 | x86 | |
10.7.1 | 1699.22.81 | x86 | |
10.7.2 | 1699.24.8 | x86 | |
10.7.3 | 1699.24.23 | x86 | |
10.7.4 | 1699.26.8 | x86 | |
10.7.5 | 1699.32.7 | x86 | |
10.8 | 2050.7.9 | x86 | |
10.8.1 | 2050.9.2 | x86 | |
10.8.2 | 2050.18.24 | x86 | |
10.8.3 | 2050.22.13 | x86 | |
10.8.4 | 2050.24.15 | x86 | |
10.8.5 | 2050.48.11 | x86 | |
10.9 | 2422.1.72 | x86 | |
10.9.1 | 2422.1.72 | x86 | no change? |
10.9.2 | 2422.90.20 | x86 | |
10.9.3 | 2422.100.13 | x86 | |
10.9.4 | 2422.110.17 | x86 | |
10.9.5 | 2422.115.4 | x86 | |
10.10 | 2782.1.97 | x86 | |
10.10.1 | 2782.1.97 | x86 | no change? |
10.10.2 | 2782.10.72 | x86 | |
10.10.3 | 2782.20.48 | x86 | |
10.10.4 | 2782.30.5 | x86 | |
10.10.5 | 2782.40.9 | x86 | |
10.11 | 3247.1.106 | x86 | |
10.11.1 | 3247.10.11 | x86 | |
10.11.2 | 3248.20.55 | x86 | |
10.11.3 | 3248.30.4 | x86 | |
10.11.4 | 3248.40.184 | x86 | |
10.11.5 | 3248.50.21 | x86 | |
10.11.6 | 3248.60.10 | x86 | |
10.12 | 3789.1.32 | x86 | |
10.12.1 | 3789.21.4 | x86 | |
10.12.2 | 3789.31.2 | x86 | |
10.12.3 | 3789.41.3 | x86 | |
10.12.4 | 3789.51.2 | x86 | |
10.12.5 | 3789.60.24 | x86 | |
10.12.6 | 3789.70.16 | x86 |
Last active
September 10, 2017 16:55
-
-
Save epipping/33220afc91b53bad68c94bf5c49cf2de to your computer and use it in GitHub Desktop.
Create a git repository and populate it with XNU sources in a helpful way
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
## WARNING: This will operate in the directory in which it is invoked! | |
## These are meant to be configured | |
cachedir=$HOME/xnu_cache | |
orgfile=$HOME/xnu.org | |
## Can be set here or passed on the command line | |
platform=${1:-ppc} | |
old_macOS_minor= | |
git init --quiet | |
git commit --quiet --allow-empty --message 'Dummy commit' | |
gawk -F'|' '{ print $2 " " $3 " " $4 }' ${orgfile} | while read macOS XNU platforms; do | |
if [[ ${platforms} != *${platform}* ]]; then | |
continue | |
fi | |
echo macOS=${macOS} XNU=${XNU} | |
macOS_minor_rev=${macOS#10.} | |
macOS_minor=${macOS_minor_rev%.*} | |
if [[ ${old_macOS_minor} != ${macOS_minor} ]]; then | |
if [[ -n ${old_macOS_minor} ]]; then | |
# Discard the last bogus commit | |
git reset --quiet --hard 'HEAD~1' | |
fi | |
git checkout --quiet -b "macOS-10.${macOS_minor}.x" master | |
old_macOS_minor=${macOS_minor} | |
fi | |
dirname=xnu-${XNU} | |
tarball=${dirname}.tar.gz | |
cache_name=${cachedir}/${tarball} | |
if [[ ! -f ${cache_name} ]]; then | |
wget --quiet https://opensource.apple.com/tarballs/xnu/${tarball} -P ${cachedir}/ | |
fi | |
tar --strip-components=1 --exclude='*.save' --exclude='*.rej' --exclude='*.orig' -xf ${cache_name} | |
date=$(tar -tvf ${cache_name} | grep -v '\.\(save\|rej\|orig\)$' | gawk ' | |
BEGIN { | |
m["Jan"]=1; m["Feb"]=2; m["Mar"]=3; m["Apr"]=4; m["May"]=5; m["Jun"]=6; | |
m["Jul"]=7; m["Aug"]=8; m["Sep"]=9; m["Oct"]=10; m["Nov"]=11; m["Dec"]=12; | |
} | |
{ | |
time[NR] = sprintf("%d-%02d-%02d", $8, m[$6], $7) | |
} | |
END { | |
asort(time) | |
print time[NR] | |
}') | |
git add . | |
git commit --quiet --all --amend --allow-empty \ | |
--message "macOS-${macOS}: XNU-${XNU}" \ | |
--author 'Apple <[email protected]>' \ | |
--date="${date}T00:00:00" | |
git tag macOS-${macOS} | |
git tag XNU-${XNU} | |
tar -tf ${cache_name} | grep -v '\.\(save\|rej\|orig\)$' | while read f; do | |
f=${f#xnu-${XNU}/} | |
if [[ -f ./"${f}" || -L ./"${f}" ]]; then | |
rm -f ./"${f}" | |
fi | |
done | |
git commit --quiet --all --message 'Dummy commit' | |
if [[ $(git ls-files | wc -l) -ne 0 ]]; then | |
echo WARNING: sanity check failed; | |
echo these are the files: | |
git ls-files | |
fi | |
done | |
# Discard the last bogus commit | |
git reset --quiet --hard 'HEAD~1' | |
git branch --quiet --delete --force master |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use 5.22.0; # for /n | |
use strict; | |
use warnings; | |
use File::Slurp qw{read_file};; | |
use List::Util qw{pairs}; | |
my $comment = qr|\ ? \* (?! \/)|x; | |
foreach my $file (@ARGV) { | |
my $text = read_file($file); | |
$text =~ s/ | |
## Starting at the beginning of a line | |
(?<= \n) | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Copyright notice(s); optional: sometimes buried in the license body | |
( | |
${comment} \ Copyright .* \n | |
)* | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Header | |
${comment} \ @ [a-zA-Z_]* _HEADER_START @ \ * \n | |
## License body (i.e., lines that no finish the comment) | |
( | |
${comment} .* \n | |
)* | |
## Footer | |
${comment} \ @ [a-zA-Z_]* _HEADER_END @ \ * \n | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Leaving else inside the comment intact, also the closing | |
//xng; | |
print $text; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use 5.22.0; # for /n | |
use strict; | |
use warnings; | |
use File::Slurp qw{read_file};; | |
use List::Util qw{pairs}; | |
my $comment = qr|\. \\ "|x; | |
foreach my $file (@ARGV) { | |
my $text = read_file($file); | |
$text =~ s/ | |
## Starting at the beginning of a line | |
(?<= \n) | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Copyright notice(s); optional: sometimes buried in the license body | |
( | |
${comment} \ Copyright .* \n | |
)* | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Header | |
${comment} \ @ [a-zA-Z_]* _HEADER_START @ \ * \n | |
## License body (i.e., lines that no finish the comment) | |
( | |
${comment} .* \n | |
)* | |
## Footer | |
${comment} \ @ [a-zA-Z_]* _HEADER_END @ \ * \n | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Leaving else inside the comment intact, also the closing | |
//xng; | |
print $text; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use 5.22.0; # for /n | |
use strict; | |
use warnings; | |
use File::Slurp qw{read_file};; | |
use List::Util qw{pairs}; | |
my $comment = qr|\#|x; | |
foreach my $file (@ARGV) { | |
my $text = read_file($file); | |
$text =~ s/ | |
## Starting at the beginning of a line | |
(?<= \n) | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Copyright notice(s); optional: sometimes buried in the license body | |
( | |
${comment} \ Copyright .* \n | |
)* | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Header | |
${comment} \ @ [a-zA-Z_]* _HEADER_START @ \ * \n | |
## License body (i.e., lines that no finish the comment) | |
( | |
${comment} .* \n | |
)* | |
## Footer | |
${comment} \ @ [a-zA-Z_]* _HEADER_END @ \ * \n | |
## Empty lines | |
( | |
${comment} \ * \n | |
)* | |
## Leaving else inside the comment intact, also the closing | |
//xng; | |
print $text; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment