Trying to bootstrap a minimal system using the Os from the begining to keep all the binaries small. However, gcc crashes I beleive on the second stage of bootstrap when it tries to use -O2s in the CFLAGS, which is a bad statement I tracked it down to this line of code in the ebuild export CFLAGS="$(echo "${CFLAGS}" | sed -e 's|-O[0123456789]\?|-O2|g')"; it doesn't account for -Os, so it makes it -O2s, I'm retrying now adding s to the list of characters in the regex to see if it works, but It does work using -O2 on the same computer but I'd like to start with -Os if possible, if not, I can do it later Reproducible: Always Steps to Reproduce: 1.add -Os to CFLAGS in make.conf 2.run bootstrap.sh Actual Results: failed with illegal CFLAGS Expected Results: not fail, but replace the -Os with -O2 as needed
forgot to mention this was gcc-3.3.2-r7.ebuild since I had ~x86 (not smartest Idea) previous ebuilds like gcc-3.3.1-r1.ebuild use: export CFLAGS="${CFLAGS/-O?/-O2}"
rsync and try again please.
that did it when you added the -O[0-9s] in the sed expression thanks