Fix destruction order in zend_shutdown (bug #65463, #66036)

If Apache or a similar SAPI receives a signal during PHP processing
it calls zend_shutdown() without calling shutdown_executor().
	#65463: If a module like Gearman or Memcached is loaded,
in the unfixed version it is unloaded by zend_destroy_modules() before the
CG(CLASS_TABLE) is destructed. When CG(CLASS_TABLE) is destructed,
any pointers to methods (specifically around destruction) in the unloaded
module's .so are now dangling and the process segfaults.
	#66036: Any subclasses of an internal class like ArrayObject need
to be destructed in order: subclass first and then the internal class. In the
unfixed version zend_shutdown() clears the CG(CLASS_TABLE) from the head
of the list onwards, so internal classes are destructed first and user-defined
classes last. Internal classes are alloc/deallocated with malloc/free while
user-defined classes with emalloc/efree. If there's shared data between them
then efree() could be called instead of free() leading to a seg-fault.
Fix typo from commit 32314f6b6
Only destruct if EG(active) in zend_shutdown(). (bug #65463, #66036)
fixed DBG_INF macro name
Fix stream_select() issue with OpenSSL buffer

Ensure data from OpenSSL internal buffer has been
transfered to PHP stream buffer before a select()
emulation operation is performed

Addresses bug #65137
https://bugs.php.net/bug.php?id=65137

Conflicts:
	ext/openssl/xp_ssl.c
Merge branch 'PHP-5.4' into PHP-5.5

* PHP-5.4:
  Fix stream_select() issue with OpenSSL buffer

Conflicts:
	ext/openssl/xp_ssl.c
libtool: powerpc*le-linux support by Alan Modra <amodra@bigpond.net.au>

Patch created using the following changes in libtool:
http://git.savannah.gnu.org/cgit/libtool.git/commit/?id=75ffb257
http://git.savannah.gnu.org/cgit/libtool.git/commit/?id=056889b8
http://git.savannah.gnu.org/cgit/libtool.git/commit/?id=bd998a7e
http://git.savannah.gnu.org/cgit/libtool.git/commit/?id=429d40a0
http://git.savannah.gnu.org/cgit/libtool.git/commit/?id=8a8dfaec
config.guess: add ppc64le / ppcle support by Anton Blanchard <anton@samba.org>

Based on http://git.savannah.gnu.org/cgit/config.git/commit/?id=29900d3b
restore FPM compatibility with mod_fastcgi broken since #694 / 67541, fixes bug 67606
fix NEWS for fcgi fix merge
Merge branch 'PHP-5.4' into PHP-5.5

* PHP-5.4:
  fix NEWS for fcgi fix merge
  restore FPM compatibility with mod_fastcgi broken since #694 / 67541, fixes bug 67606
- Updated to version 2014.7 (2014g)
Merge branch 'PHP-5.4' into PHP-5.5
Merge branch 'pull-request/770' into PHP-5.4

* pull-request/770:
  Only destruct if EG(active) in zend_shutdown(). (bug #65463, #66036)
  Fix typo from commit 32314f6b6
  Fix destruction order in zend_shutdown (bug #65463, #66036)
update NEWS
Merge branch 'PHP-5.4' into PHP-5.5

* PHP-5.4:
  update NEWS
  Only destruct if EG(active) in zend_shutdown(). (bug #65463, #66036)
  Fix typo from commit 32314f6b6
  Fix destruction order in zend_shutdown (bug #65463, #66036)
Fix bug #67644 - Memory corruption & crash during ob_start function callback
Merge branch 'PHP-5.4' into PHP-5.5

* PHP-5.4:
  Fix bug #67644 - Memory corruption & crash during ob_start function callback
Revert "Fix bug #67644 - Memory corruption & crash during ob_start function callback"

This reverts commit 53fa6c5b6b5b09059ba54c8912d0c0aef57aa4ff.
The change breaks tests, so not putting it into 5.4.
Merge branch 'PHP-5.4' into PHP-5.5

* PHP-5.4:
  Revert "Fix bug #67644 - Memory corruption & crash during ob_start function callback"