From Bitpost wiki
Upgrading to PHP 7
- edit /etc/portage/make.conf
# APACHE2_MODULES: update -D PHP5 to -D PHP # add php7-0 as target PHP_TARGETS="php5-6 php7-0"
- emerge everything
- use eselect to select it
Upgrading to gentoo profile v17
bitpost ~ # eselect profile list Available profile symlink targets:  default/linux/amd64/13.0 (stable) ...  default/linux/amd64/13.0/no-multilib (stable) ...  default/linux/amd64/17.0 (stable) * ...  default/linux/amd64/17.0/no-multilib (stable) * ...  default/linux/amd64/17.1 (exp) ...
I started down v17 so I better finish up. But let's go with the base profile (12). I used to use no-multilib (to avoid 32-bit support) but it sounds like there's little harm or cost in it.
Steps are described in eselect:
eselect news list eselect news read 36 2017-11-30-new-17-profiles Title New 17.0 profiles in the Gentoo repository (blah blah blah) * Rebuild your entire system emerge -e @world Switching the profile from 13.0 to 17.0 modifies the settings of GCC 6 to generate PIE executables by default; thus, you need to do the rebuilds even if you have already used GCC 6 beforehand. If you do not follow these steps you may get spurious build failures when the linker tries unsuccessfully to combine non-PIE and PIE code.