If you're getting PHP fatal this error while running your Drupal 7 on a Gentoo server a quick suggestion is check if your PHP has the filter extension enabled as it is required by Drupal 7 Core.
If you don't the only thing you need to do is follow those steps:
$ flagedit dev-lang/php +filter
$ emerge dev-lang/php
After emerge completes, just restart your http server and you're done!