Presentation :
moatool means Mach-O Archive Tool, As its name suggest it, it’s an utility which handle Mach-O archives, format used by Mac OS X.
More precisely, moatool allow you to reduce Mach-O archives by stripping the useless platform code.
Concretely, how it works ?
I invite you to read the article I wrote about Mach-O archives and also the one where I presented moatool.
moatool works on Mac OS X 10.4, 10.5, 10.6.
For Snow Leopard, even if the PPC arch is no longer supported, most of the binaries still have code for 2 archs, x86 and x86_64, so there is still a way to gain some place on your HD (for the paranoiacs of the giga).
moatool is coded in C, and is under the new BSD licence.
Installation :
You can grabe the source or the compiled dynamic library.
For the library I advise you to put it in your $PATH (something like /usr/local/lib) and the header file in /usr/local/include.
If you want to build the library yourself, I advise you to build a dynamic library and not a static one.
To build :
1 2 3 | $ gcc moatool.c -dynamiclib -Wall -arch i386 -arch x86_64 -arch ppc -arch ppc64 -o libmoatool.dylib $ cp moatool.h /usr/local/include/ $ cp libmoatool.dylib /usr/local/lib/ |
Usage :
An example is given with the sources and there is also the post where I presented it.
If you have any remarks, questions, you can contact me : postmaster[at]whine[dot]fr
Download :
English
French