gdbinit / otool-ng

Some improvements to Apple's otool.
100 stars 27 forks source link

Memo #1

Open tjoozey opened 11 years ago

tjoozey commented 11 years ago

How do I install and implement this into a xcode project - Thx

gdbinit commented 11 years ago

You can't. You need to compile using darwinbuild. This post http://reverse.put.as/2012/11/21/otool-ng-a-set-of-small-patches-to-apples-otool/ has the link to other post I wrote about how to do it.

tjoozey commented 11 years ago

can you link me to darwinbuild and how to build it on mountain lion - here is what i see:

|ruby-1.9.3-p194| Tylers-MacBook-Pro in ~/Desktop/code/otool-ng/cctools-829 ± |master ✗| → make =========== make all for libstuff ============= /bin/mkdir -p static_obj /bin/mkdir -p dynamic_obj /bin/mkdir -p profile_obj /bin/mkdir -p shlib_obj /bin/mkdir -p static_kld_obj cc -Os -DLTO_SUPPORT -g -I../../include -Wall -D_MACH_I386_THREAD_STATUS_FPSTATE_LEGACY_FIELDNAMES -D_ARCHITECTURE_I386_FPU_FPSTATE_LEGACY_FIELDNAMES -c \ -MD -dependency-file ./allocate.d \ -o ./allocate.o ../allocate.c md -d -u ./Makedep ./allocate.d make[2]: md: No such file or directory make[2]: * [allocate.o] Error 1 make[1]: * [dynamic] Error 2 make: *\ [all] Error 1

|ruby-1.9.3-p194| Tylers-MacBook-Pro in ~/Desktop/code/otool-ng/cctools-829 ± |master ✗| → sudo make Password: =========== make all for libstuff ============= cc -Os -DLTO_SUPPORT -g -I../../include -Wall -D_MACH_I386_THREAD_STATUS_FPSTATE_LEGACY_FIELDNAMES -D_ARCHITECTURE_I386_FPU_FPSTATE_LEGACY_FIELDNAMES -c \ -MD -dependency-file ./errors.d \ -o ./errors.o ../errors.c md -d -u ./Makedep ./errors.d make[2]: md: No such file or directory make[2]: * [errors.o] Error 1 make[1]: * [dynamic] Error 2 make: *\ [all] Error 1

|ruby-1.9.3-p194| Tylers-MacBook-Pro in ~/Desktop/code/otool-ng/cctools-829 ± |master ✗| → make install =========== make install_tools ============= /bin/mkdir -p //usr/include/mach-o/i386 /bin/mkdir -p //usr/include/mach-o/ppc /bin/mkdir -p //usr/include/mach-o/x86_64 /bin/mkdir -p //usr/include/mach-o/arm mkdir: //usr/include/mach-o/arm: Permission denied make[2]: * [dirs] Error 1 make[1]: * [installhdrs] Error 1 make: *\ [install] Error 2

|ruby-1.9.3-p194| Tylers-MacBook-Pro in ~/Desktop/code/otool-ng/cctools-829 ± |master ✗| → make =========== make all for libstuff ============= cc -Os -DLTO_SUPPORT -g -I../../include -Wall -D_MACH_I386_THREAD_STATUS_FPSTATE_LEGACY_FIELDNAMES -D_ARCHITECTURE_I386_FPU_FPSTATE_LEGACY_FIELDNAMES -c \ -MD -dependency-file ./arch.d \ -o ./arch.o ../arch.c md -d -u ./Makedep ./arch.d make[2]: md: No such file or directory make[2]: * [arch.o] Error 1 make[1]: * [dynamic] Error 2 make: *\ [all] Error 1

|ruby-1.9.3-p194| Tylers-MacBook-Pro in ~/Desktop/code/otool-ng/cctools-829 ± |master ✗| → mkdir Build9G55

|ruby-1.9.3-p194| Tylers-MacBook-Pro in ~/Desktop/code/otool-ng/cctools-829 ± |master ✗| → cd Build9G55

|ruby-1.9.3-p194| Tylers-MacBook-Pro in ~/Desktop/code/otool-ng/cctools-829/Build9G55 ± |master ✗| → darwinbuild -init 9G55

Tyler Johnson Sent with Sparrow (http://www.sparrowmailapp.com/?sig)

On Thursday, November 22, 2012 at 4:15 PM, fG! wrote:

You can't. You need to compile using darwinbuild. This post http://reverse.put.as/2012/11/21/otool-ng-a-set-of-small-patches-to-apples-otool/ has the link to other post I wrote about how to do it.

— Reply to this email directly or view it on GitHub (https://github.com/gdbinit/otool-ng/issues/1#issuecomment-10646165).

gdbinit commented 11 years ago

You need to follow the steps explained in the post. A new image must be created and the darwinbuild initialized there. The build number for Mountain Lion is a 12XXXX. Go to the plists folder linked in the post and use that build #. There's yet no build for 10.8.2 but the one for 10.8 is good to use.