summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJay Freeman <saurik@saurik.com>2008-02-14 14:32:59 +0000
committerJay Freeman <saurik@saurik.com>2008-02-14 14:32:59 +0000
commit6b964b69935fcc52a1c0a95695ca436e00b6690f (patch)
treea863dd50c7cc7fe19b9759360ed4d5b545f9ba0f
parent459c9779557e19437de4a02f6311c322989228b3 (diff)
Drastically reworked bootstrap package.
git-svn-id: http://svn.telesphoreo.org/trunk@88 514c082c-b64e-11dc-b46d-3d985efe055d
-rwxr-xr-xbootstrap.sh22
-rwxr-xr-xconstruct.sh2
-rw-r--r--data/base/base-1.tgzbin1208 -> 0 bytes
-rw-r--r--data/base/base.tgzbin0 -> 1229 bytes
-rw-r--r--data/base/make.sh2
-rw-r--r--data/cydia/make.sh6
-rw-r--r--data/libarmfp/_metadata/description1
l---------data/libarmfp/_metadata/maintainer1
-rw-r--r--data/libarmfp/_metadata/priority1
-rw-r--r--data/libarmfp/_metadata/section1
-rw-r--r--data/libarmfp/_metadata/version1
-rwxr-xr-xdata/libarmfp/libarmfp.dylibbin0 -> 8704 bytes
-rw-r--r--data/libarmfp/make.sh2
-rw-r--r--data/saurik/make.sh2
-rwxr-xr-xover/usr/libexec/cydia/boot/godmodebin0 -> 8956 bytes
-rwxr-xr-xover/usr/libexec/cydia/boot/install.sh (renamed from data/cydia/install.sh)9
-rw-r--r--tool/godmode.c8
-rw-r--r--tool/symlink.c (renamed from data/cydia/symlink.c)0
-rwxr-xr-xutil/configure.sh6
19 files changed, 49 insertions, 15 deletions
diff --git a/bootstrap.sh b/bootstrap.sh
index e014e820b..0033e56ad 100755
--- a/bootstrap.sh
+++ b/bootstrap.sh
@@ -8,9 +8,13 @@ export PKG_BOOT=${PKG_BASE}/Packager
rm -rf "${PKG_BOOT}"
svn export "${PKG_BASE}/over" "${PKG_BOOT}"
+arm-apple-darwin-gcc -o "${PKG_BOOT}/usr/libexec/cydia_/godmode" "${PKG_BASE}/tool/godmode.c"
+arm-apple-darwin-gcc -o "${PKG_BOOT}/usr/libexec/cydia_/symlink" "${PKG_BASE}/tool/symlink.c"
+chmod +s "${PKG_BOOT}/usr/libexec/cydia_/godmode"
+
mkdir -p "${PKG_BOOT}/var/lib/dpkg/info"
-PKG_REQS=(adv-cmds base bash coreutils cydia gawk grep inetutils nano network-cmds nvi saurik sed shell-cmds system-cmds unzip zip)
+PKG_REQS=(adv-cmds base bash coreutils cydia gawk grep inetutils less libarmfp nano network-cmds saurik sed shell-cmds system-cmds unzip zip)
cd "${PKG_BASE}/data"
PKG_REQS=($(find -L "${PKG_REQS[@]}" | while read -r line; do realpath "${line}"; done | grep "/home/saurik/telesphoreo/data/[^/]*$" | sed -e 's/.*\///' | sort -u))
@@ -37,10 +41,24 @@ cd "${PKG_BOOT}"
rm -f ../Packager.xml
find * -type l -print -o -name "terminfo" -prune | while read -r link; do
- echo "<array><string>Exec</string><string>/bin/ln -fs $(readlink "${link}") /${link}</string></array>"
+ echo "<array><string>Exec</string><string>/usr/libexec/cydia/symlink $(readlink "${link}") /${link}</string></array>"
rm -f "${link}"
done >>../Packager.xml
+mkdir -p usr/libexec/cydia/boot
+
+cp -a bin/bash usr/libexec/cydia/boot
+cp -a bin/df usr/libexec/cydia/boot
+cp -a bin/ln usr/libexec/cydia/boot
+cp -a bin/mktemp usr/libexec/cydia/boot
+cp -a bin/mv usr/libexec/cydia/boot
+cp -a usr/bin/basename usr/libexec/cydia/boot
+cp -a usr/bin/du usr/libexec/cydia/boot
+cp -a usr/lib/libhistory.5.2.dylib usr/libexec/cydia/boot
+cp -a usr/lib/libintl.8.0.2.dylib usr/libexec/cydia/boot
+cp -a usr/lib/libncurses.5.dylib usr/libexec/cydia/boot
+cp -a usr/lib/libreadline.5.2.dylib usr/libexec/cydia/boot
+
rm -f ../Packager.zip
zip -qry ../Packager.zip *
rm -rf "${PKG_BOOT}"
diff --git a/construct.sh b/construct.sh
index 534db09b5..795bcb672 100755
--- a/construct.sh
+++ b/construct.sh
@@ -19,7 +19,7 @@ gzip -c "${PKG_PKGS}" >"${PKG_PKGS}.gz"
#cp -a debs "${PKG_REPO}"
cd "${PKG_REPO}/dists/tangelo"
-export PKG_RVSN=13
+export PKG_RVSN=86
cat >main/binary-darwin-arm/Release <<EOF
Archive: stable
diff --git a/data/base/base-1.tgz b/data/base/base-1.tgz
deleted file mode 100644
index 3594c315e..000000000
--- a/data/base/base-1.tgz
+++ /dev/null
Binary files differ
diff --git a/data/base/base.tgz b/data/base/base.tgz
new file mode 100644
index 000000000..d1789b539
--- /dev/null
+++ b/data/base/base.tgz
Binary files differ
diff --git a/data/base/make.sh b/data/base/make.sh
index 72290cbb2..fbd4f1b14 100644
--- a/data/base/make.sh
+++ b/data/base/make.sh
@@ -1 +1 @@
-tar -zxvf "${PKG_DATA}/base-1.tgz" -C "${PKG_DEST}"
+tar -zxvf "${PKG_DATA}/base.tgz" -C "${PKG_DEST}"
diff --git a/data/cydia/make.sh b/data/cydia/make.sh
index 36f51ad89..7e988c316 100644
--- a/data/cydia/make.sh
+++ b/data/cydia/make.sh
@@ -12,9 +12,3 @@ pkg: chmod +s /Applications/Cydia.app/Cydia
pkg: mkdir -p /System/Library/PreferenceBundles
pkg: cp -a CydiaSettings.bundle /System/Library/PreferenceBundles
-
-pkg: mkdir -p /usr/libexec/cydia
-pkg: cp -a %/install.sh /usr/libexec/cydia
-
-pkg: arm-apple-darwin-gcc -o symlink %/symlink.c
-pkg: cp -a symlink /usr/libexec/cydia
diff --git a/data/libarmfp/_metadata/description b/data/libarmfp/_metadata/description
new file mode 100644
index 000000000..c4cbc0947
--- /dev/null
+++ b/data/libarmfp/_metadata/description
@@ -0,0 +1 @@
+library used by older iPhone software
diff --git a/data/libarmfp/_metadata/maintainer b/data/libarmfp/_metadata/maintainer
new file mode 120000
index 000000000..0fa66e077
--- /dev/null
+++ b/data/libarmfp/_metadata/maintainer
@@ -0,0 +1 @@
+../../../people/saurik \ No newline at end of file
diff --git a/data/libarmfp/_metadata/priority b/data/libarmfp/_metadata/priority
new file mode 100644
index 000000000..134d9bc32
--- /dev/null
+++ b/data/libarmfp/_metadata/priority
@@ -0,0 +1 @@
+optional
diff --git a/data/libarmfp/_metadata/section b/data/libarmfp/_metadata/section
new file mode 100644
index 000000000..00b394251
--- /dev/null
+++ b/data/libarmfp/_metadata/section
@@ -0,0 +1 @@
+System
diff --git a/data/libarmfp/_metadata/version b/data/libarmfp/_metadata/version
new file mode 100644
index 000000000..573541ac9
--- /dev/null
+++ b/data/libarmfp/_metadata/version
@@ -0,0 +1 @@
+0
diff --git a/data/libarmfp/libarmfp.dylib b/data/libarmfp/libarmfp.dylib
new file mode 100755
index 000000000..6e49268a8
--- /dev/null
+++ b/data/libarmfp/libarmfp.dylib
Binary files differ
diff --git a/data/libarmfp/make.sh b/data/libarmfp/make.sh
new file mode 100644
index 000000000..510c1e96c
--- /dev/null
+++ b/data/libarmfp/make.sh
@@ -0,0 +1,2 @@
+pkg: mkdir -p /usr/lib
+pkg: cp -a %/libarmfp.dylib /usr/lib
diff --git a/data/saurik/make.sh b/data/saurik/make.sh
new file mode 100644
index 000000000..c2f48e300
--- /dev/null
+++ b/data/saurik/make.sh
@@ -0,0 +1,2 @@
+pkg: mkdir -p /etc/apt/sources.list.d
+pkg: cp -a %/saurik.list /etc/apt/sources.list.d
diff --git a/over/usr/libexec/cydia/boot/godmode b/over/usr/libexec/cydia/boot/godmode
new file mode 100755
index 000000000..9ff8ec9eb
--- /dev/null
+++ b/over/usr/libexec/cydia/boot/godmode
Binary files differ
diff --git a/data/cydia/install.sh b/over/usr/libexec/cydia/boot/install.sh
index bfac1459d..455a27a38 100755
--- a/data/cydia/install.sh
+++ b/over/usr/libexec/cydia/boot/install.sh
@@ -1,6 +1,7 @@
-#!/bin/bash
+#!/usr/libexec/cydia/boot/bash
shopt -s extglob nullglob
+export PATH=/usr/libexec/cydia/boot
function df_() {
free=$(df -B1 "$1")
@@ -26,11 +27,11 @@ do if [[ -d ${dir} && ! -h ${dir} ]]; then
new=/var/${base}
if [[ -e ${new} ]]; then
- new=$(TMPDIR=/var mktemp -t /var -d cydia.XXXXXX)
+ new=$(mktemp -d cydia.XXXXXX)
fi
- mv -T "${dir}" "${new}"
- ln -s "${new}" "${dir}"
+ godmode mv -T "${dir}" "${new}"
+ godmode ln -s "${new}" "${dir}"
fi
fi; done
diff --git a/tool/godmode.c b/tool/godmode.c
new file mode 100644
index 000000000..363309f95
--- /dev/null
+++ b/tool/godmode.c
@@ -0,0 +1,8 @@
+#include <sys/types.h>
+#include <unistd.h>
+
+int main(int argc, char *argv[]) {
+ setuid(0);
+ setgid(0);
+ execvp(argv[1], argv + 1);
+}
diff --git a/data/cydia/symlink.c b/tool/symlink.c
index 7ba730d8d..7ba730d8d 100644
--- a/data/cydia/symlink.c
+++ b/tool/symlink.c
diff --git a/util/configure.sh b/util/configure.sh
index 0c1cfba6f..1a7efc6b0 100755
--- a/util/configure.sh
+++ b/util/configure.sh
@@ -3,4 +3,8 @@ for ltmain in $(find -name ltmain.sh); do
patch -N "${ltmain}" "$(dirname "$0")/libtool.diff" || true
done
-PKG_ROOT=/home/saurik/iphone/sysroot PKG_CONFIG="$(realpath ../../../util/pkg-config.sh) --define-variable=prefix=/home/saurik/iphone/sysroot/usr" PKG_CONFIG_PATH=/home/saurik/iphone/sysroot/usr/lib/pkgconfig ./configure --prefix=/usr --host=arm-apple-darwin --enable-static=no --enable-shared=yes "$@"
+if [[ -z $PKG_CONF ]]; then
+ PKG_CONF=./configure
+fi
+
+PKG_ROOT=/home/saurik/iphone/sysroot PKG_CONFIG="$(realpath ../../../util/pkg-config.sh) --define-variable=prefix=/home/saurik/iphone/sysroot/usr" PKG_CONFIG_PATH=/home/saurik/iphone/sysroot/usr/lib/pkgconfig $PKG_CONF --prefix=/usr --host=arm-apple-darwin --enable-static=no --enable-shared=yes "$@"