you can not build dev-lang/php with support for net-libs/libssh2. This should be fixed. Therefor the ssh useflag could be used. See also http://www.php.net/manual/en/ssh2.requirements.php
Install dev-php/pecl-ssh2.