From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,e71619b99643375e,start X-Google-Attributes: gidfee84,public From: tringali@news.ed.ray.com (Scott Tringali) Subject: Compressing archives... Date: 1996/01/04 Message-ID: <4cgl9r$s7e@news.res.ray.com>#1/1 X-Deja-AN: 133946975 x-disclaimer: This is the author's opinion and not that of Raytheon Company. x-authentication-warning: The author was not authenticated. content-type: text/plain; charset=us-ascii summary: How can I use -compress with ar? organization: Raytheon Electronic Systems mime-version: 1.0 reply-to: tringali@ultranet.com newsgroups: comp.unix.osf.osf1 We've noticed a 22:1 increase in debug vs. non-debug builds for some of our large software systems here. This of course seriously impacts our disk space. I have been looking into a method of somehow compressing our object files and/or libraries, which seem to take up most of our disk space. Unfortunately, I have to deal with our "home grown" build tool, which makes things a little tougher. After reading through the cc man pages, I thought I found exactly what I was looking for: the -compress option. Sure enough, the .o files (especially with symbol information) are MUCH smaller, but it doesn't seem to be compatible with the ar archiver our build tool uses to maintain libraries. For example: cc -c -compress ar qcu test.a ar: Error: malformed archive (at 2611) I have, however, found a happy medium. I found an ar option that will compress the resulting .a file -- the Z option. This works fine, however, all my .a files are compressed, while .o files are still huge. Before I complain too much, this has already helped a lot (it cuts the debug libraries' size in half, and when some are > 10 megs, that is great) but I'd like to get the .o files as well. Any ideas, anyone? Thanks in advance. -- Scott J. Tringali, tringali@ultranet.com Raytheon Electronic Systems, International Air Traffic Control