First Install xCode
Simple enough, make sure to have it setup environmental variables
Second Build/Install cmake
Assuming the tarball is at ~/Desktop/tutorial type this into terminal (don’t include the $, it only shows a return was made)
Code:
$ cd ~/Desktop/tutorial
$ tar zxvf cmake-2.8.0
$ cd cmake-2.8.0
$ ./configure && make && sudo make install
Second Install libpng
Just mount the dmg and hit the installer.
Third Build/Install xpwn
Assuming the tarball is at ~/Desktop/tutorial
Code:
$ cd ~/Desktop/tutorial
$ tar zxvf posixninja-xpwn-7609d82.tar.gz
$ cd posixninja-xpwn-7609d82
$ mkdir compile
$ cd compile
$ cmake ..
$ make
$ sudo cp ipsw-patch/xpwntool /usr/bin
$ sudo cp ipsw-patch/ipsw /usr/bin
$ sudo cp ipsw-patch/imagetool /usr/bin
$ sudo cp dmg/dmg /usr/bin
$ sudo cp hdutil/hdutil /usr/bin
(you can delete all the other stuff except the comex-star-f96e692.tar.gz
Forth Build Star Jailbreak (incomplete)
I will go up til the point where I fail lol, I will be using iPod2,1_4.0_8A293_Restore.ipsw which is also on my Desktop (~/Desktop/iPod2,1_4.0_8A293_Restore.ipsw)
Extract comex-star-f96e692.tar.gz and put it on the desktop (~/Desktop/comex-star-f96e692)
cd into the source
Code:
$ cd ~/Desktop/comex-star-f96e692
Gather the required files from the ipsw (will take a minute or two)
Those are some of the headers needing to be copied somewhere but the readme is SOOOOOOOOOOOOOOOOOOOO vague
Quote:- To compile:
1. Make sure you have MacPorts installed, and python26, plus fuse if you want to compile dsc.c (which isn't necessary). DONE
2. Copy stuff into bs/, e.g. DONE
bs/iPhone2,1_4.0.1
bs/iPhone2,1_4.0.1/cache
bs/iPhone2,1_4.0.1/kern
bs/iPhone2,1_4.0.1/launchd
where cache is /System/Library/Caches/com.apple.dyld/dyld_shared_cache_armv[67], launchd is /sbin/launchd, and kern is the decrypted kernel. Note that you can get 'kern' on platforms like the iPhone 4 where we don't have keys yet by using /dev/kmem and bs/unload.py, but there's a chance the kernel already overwrote __LINKEDIT with crap.
3. config/config.py iPhone2,1_4.0.1 DONE
4. make FAIL
5. fix the places where you need to copy headers from OS X and I fail at documentation, goto 4 HUH?
6. look at cff/out.pdf
09-04-2010, 02:47 PM (This post was last modified: 09-04-2010 02:48 PM by truehybridx.)
RE: [partial tutorial] Compile Star Jailbreak on OSX
ok i narrowed it down to only two things giving me greif about headers and ill post their makefiles for yall to see and the include portions of their source
Code:
#install makefile
# install.c is in the download. installui.m is bundled.
include ../env.mk
all: install.dylib wad.bin
install.dylib: install.o copier.o
$(GCC_UNIVERSAL) -dynamiclib -o $@ $^ -framework Foundation -framework CoreFoundation libtar.a liblzma.a -framework GraphicsServices
%.o: %.c common.h
$(GCC_UNIVERSAL) -Iheaders -std=gnu99 -c -o $@ $< -Werror
wad.bin: install.dylib Cydia-4.0.1r2-Raw.txz
python wad.py $^
clean:
rm -f install.dylib *.o wad.bin
Code:
#installui Makefile
# install.c is in the download. installui.m is bundled.
include ../env.mk
all: installui.dylib
installui.dylib: installui.o dddata.o ../config/config.cflags common.h
$(GCC) -dynamiclib -Iheaders -std=gnu99 -o installui.dylib installui.o dddata.o -framework Foundation -framework UIKit -framework IOKit -framework CoreGraphics -lz -Werror
%.o: %.[cm] crc32.h common.h ../config/config.cflags
$(GCC) -Iheaders -std=gnu99 -c -o $@ $< -Werror
clean:
rm -f installui.dylib *.o
Honestly it might be easier to patch the pdfs and the wad.bin to whatever domain you want to use than compile from scratch but for educational it would be nice to figure this out
RE: [partial tutorial] Compile Star Jailbreak on OSX
True but those guys are soo incredibly busy that I dont have the heart to bug him... even on github they dont tell you exactly what to do but i did discover..
/var/sdk on your osx installation needs to have the contents of the iphone sdk OR needs to be linked to that folder
ie: link /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.0.sdk to /var/sdk
But there are still a few missing things i havnt figured out so i havnt added this to the tutorial yet
A little closer now lol it almost compiled just a few more errors
Code:
ld: warning: in /var/sdk/usr/lib/dylib1.o, file was built for armv6 which is not the architecture being linked (armv7)
ld: symbol dyld_stub_binding_helper not defined (usually in crt1.o/dylib1.o/bundle1.o)
collect2: ld returned 1 exit status
lipo: can't open input file: /var/folders/x9/x9mQ-KuPG2GoQi+VrrUCrk+++TI/-Tmp-//ccvs1h1N.out (No such file or directory)
make[1]: *** [install.dylib] Error 1
make: *** [all] Error 2
RE: [partial tutorial] Compile Star Jailbreak on OSX
(09-04-2010 02:47 PM)truehybridx Wrote: Honestly it might be easier to patch the pdfs and the wad.bin to whatever domain you want to use than compile from scratch but for educational it would be nice to figure this out
Can you tell me how to patch the pdfs please?
Thanks.
(09-05-2010 01:44 AM)unreaLLord Wrote: You could ask BigBoss on IRC, he hosts a copy of this this already.
RE: [partial tutorial] Compile Star Jailbreak on OSX
ever since my house got broken into a year ago i always had my computers rigged to crash their harddrives if they left my room.......... and i was rearranging my room and forgot about that lol