Large installation on Mac OS X

The arduino-0007 installer for mac os x has unstripped avr development tools and duplicates of many of the tools in tools/avr/avr/bin. That could be slimmed down by about a factor of four by stripping and eliminating duplicates.

Sounds like a good idea.

So the binaries in tools/avr/avr/bin are just duplicates of the ones in tools/avr/bin but without the "avr-" extension? If so, do you know why does the build process for the avr toolchain create both?

How does one go about stripping the binaries? What does it do?

I'll check the build process tonight. I haven't built from source yet.

How does one go about stripping the binaries? What does it do?

bash$ strip exefile

It removes symbol information (useful for debugging and profiling, but can make executables much larger).

The whole installed directory is only 91Mb on my system, IMO negligible in terms of disk usage.

-j

Yea, 91 MB isn't too bad on todays (dozens of gigabytes) harddrives, but the download (~30 MB) can be annoying for those with a slow internet connection. So if there's an easy way to reduce the size (e.g. stripping the executables or removing duplicates), I think it's probably worthwhile.

Any idea if those binaries are really duplicates?

The binaries in tools/avr/avr/bin are a subset of those in tools/avr/bin; those present are exact duplicates except for the fact that those in tools/avr/bin have "avr-" prefixed to the name.

On the other hand, tools/avr/lib seems almost empty, while tools/avr/avr/lib has the required stuff, like the .o version of the C runtime for the various AVR processors.

tools/avr/include is empty, while tools/avr/avr/include contains the necessary files.

So, not exact duplicates, but some can be eliminated with work. A 23Mb savings can be realized by stripping executables in tools/avr/bin, and another 17Mb can be saved by eliminating duplicates between tools/avr/bin and tools/avr/avr/bin (or, save about 14Mb by just stripping everything in tools/avr/avr/bin).

I don't see true duplication such that you could eliminate a single subdirectory tree because it was duplicated elsewhere.

I haven't tried stripping all the binaries to see what happens - I'm in the middle of a project and don't want to screw up my installation just now. (: I suspect it will all work just fine.

-j

Excellent. Thanks for doing this research. I'll give it a shot and hopefully Arduino 0008 will be a good bit slimmer than Arduino 0007.

Stripping all the binaries works. Executables are found in...

tool/avr/avr/bin/
tools/avr/bin/
tools/avr/libexec/gcc/avr/
tools/avr/libexec/gcc/avr/4.0.2/install-tools/

It is safe to just do a "strip *" in those directories. It is smart enough to not butcher the handful of scripts that are in there.

Cool. Has anyone tried deleting the redundant binaries (in tools/avr/avr/bin)?