]>
git.saurik.com Git - cydia.git/blob - sysroot.sh
99c8889a2bca8aab5ba4af5f393b057ad57e83d3
3 if [[ ${BASH_VERSION} != 4* ]]; then
4 echo "bash 4.0 required" 1>&2
14 for command in unlzma wget
; do
15 if ! which "${command}" &>/dev
/null
; then
16 echo "Cannot run \`${command}\`. Please read compiling.txt." 1>&2
21 if tar --help | grep bsdtar
&>/dev
/null
; then
22 echo "Running \`tar\` is bsdtar :(. Please read compiling.txt." 1>&2
26 xcode
=$(xcodebuild -sdk macosx -version Path)
32 repository
=http
://apt.saurik.com
/
35 architecture
=iphoneos
-arm
45 wget
-O "${package}.deb" "${url}"
47 compressed
=data.
tar.
${z}
49 if ar -x "${package}.deb" "${compressed}" 2>/dev
/null
; then
50 ${dpkgz[${z}]} "${compressed}"
55 if ! [[ -e data.
tar ]]; then
56 echo "unable to extract package" 1>&2
67 urls
[coreutils
]=http
://apt.saurik.com
/debs
/coreutils_7.4
-11_iphoneos-arm.deb
70 wget
-qO- "${repository}dists/${distribution}/${component}/binary-${architecture}/Packages.bz2" | bzcat
| {
71 regex
='^([^ \t]*): *(.*)'
74 while IFS
= read -r line
; do
75 if [[ ${line} == '' ]]; then
76 package
=${fields[package]}
77 if [[ -n ${urls[${package}]} ]]; then
78 filename
=${fields[filename]}
79 urls
[${package}]=${repository}${filename}
84 elif [[ ${line} =~
${regex} ]]; then
85 name
=${BASH_REMATCH[1],,}
86 value
=${BASH_REMATCH[2]}
87 fields
[${name}]=${value}
93 for package
in "${!urls[@]}"; do
94 extract
"${package}" "${urls[${package}]}"
103 wget
-O CoreFoundation
/CFUniChar.h
"http://www.opensource.apple.com/source/CF/CF-550/CFUniChar.h?txt"
106 wget
-O WebCore
/WebCoreThread.h
'http://www.opensource.apple.com/source/WebCore/WebCore-658.28/wak/WebCoreThread.h?txt'
108 ln -s /System
/Library
/Frameworks
/IOKit.framework
/Headers IOKit