App-misc/gentoo compiles with the following flags when the flags specified in make.conf are CFLAGS="-mcpu=i686 -march=i686 -O3 -pipe". The -O2 -g shouldn't be there. gcc -mcpu=i686 -march=i686 -O3 -pipe -Wall -Wmissing-prototypes -g -O2 `gtk-config --cflags` -I/usr/X11R6/include -I../widgets -DGENTOO_PACKAGE='"gentoo"' -DGENTOO_LOCALEDIR='"/home/emil/data/projects/gentoo/locale"' -ansi -pedantic -Wall -Wmissing-prototypes -g -O2 `gtk-config --cflags` -I/usr/X11R6/include -I../widgets -DGENTOO_PACKAGE='"gentoo"' -DGENTOO_LOCALEDIR='"/home/emil/data/projects/gentoo/locale"' -ansi -pedantic -c -o cmd_copy.o cmd_copy.c
Well, it looks like this was a problem with the old gentoo software itself. It looks like the new version of gentoo doesn't have this problem. So, here it is, new ebuild for new version of gentoo :).