The git distribution contains a file /usr/bin/git which should actually be symlinked to many different names in /usr/bin/git, such as /usr/bin/git-add. The current ebuild does not use symlinks (or hardlinks) for that purpose however, but instead actually duplicates /usr/bin/git a several dozens of times. As /usr/bin/git has a size of about half a megabyte, the ebuild wastes a lot of disk space, leading to a total installation size of about 32 megabytes, which is really just crazy. Reproducible: Always Steps to Reproduce: 1. for A in git*; do md5sum -b $A; done | sort | less 2. equery size dev-util/git 3. # wonder why so much space is wasted... ;-)
Ooops - forgot to add the path within step 1 how to reproduce. Please use for A in /usr/bin/git*; do md5sum -b $A;done | sort | less instead!
Here is even a better one which shows content checksum, inode and name: for A in /usr/bin/git*; do echo -n "$(md5sum -b $A | cut -c-32 ) "; ls -i $A ; done | sort |less
Regarding the size: I installed with USE=doc, so without USE=doc the package will certainly be a bit shorter then 32 megabytes, but not by too much.
The problem is waaaaaaaaaay more subtle than that. The ebuild uses the upstream provided Makefile and it efectively installs hardlinks instead of copies. However, your package manager of choice has to break those hardlinks while merging the package. Using symlinks instead of hardlinks should work for that. I'll look into this bug later. Thanks. - ferdy
I added the following 'fix' to git-1.5.0.3.ebuild: ----8<---- --- git-1.5.0.2.ebuild 2007-03-09 19:27:27.000000000 +0100 +++ git-1.5.0.3.ebuild 2007-03-09 19:19:53.000000000 +0100 @@ -74,6 +74,7 @@ -e "s:^\(LDFLAGS = \).*$:\1${LDFLAGS}:" \ -e "s:^\(CC = \).*$:\1$(tc-getCC):" \ -e "s:^\(AR = \).*$:\1$(tc-getAR):" \ + -e 's:ln :ln -s :g' \ Makefile || die "sed failed" exportmakeopts ----8<---- - ferdy
*Much* better now: Total size : 9254.92 KiB Saving 2/3rds of the previous space requirements. Thanks for the fix!
*** Bug 247922 has been marked as a duplicate of this bug. ***