Why should i use another stack? Slackware uses stock apache und php without any patches. So i think it must be a conifguration option. Maybee it helps to compare the configure command, to see differences of another installation? Then i could try to build apache or php with different options.
Apache:
./configure
--enable-layout=Slackware-FHS
--with-mpm=prefork
--with-apr=/usr
--with-apr-util=/usr
--enable-mods-shared=all
--enable-so
--enable-pie
--enable-cgi
--with-pcre
--enable-ssl
--enable-rewrite
--enable-vhost-alias
--enable-proxy
--enable-proxy-http
--enable-proxy-ftp
--enable-proxy-balancer
--enable-cache
--enable-mem-cache
--enable-file-cache
--enable-disk-cache
--disable-speling
--enable-dav
--enable-ldap
--enable-authnz-ldap
--enable-authn-anon
--enable-authn-alias
--build=$ARCH-slackware-linux
PHP:
./configure
--prefix=/usr
--libdir=/usr/lib${LIBDIRSUFFIX}
--with-libdir=lib${LIBDIRSUFFIX}
--sysconfdir=/etc
--disable-safe-mode
--disable-magic-quotes
--enable-zend-multibyte
--enable-mbregex
--enable-tokenizer=shared
--with-config-file-scan-dir=/etc/php
--with-config-file-path=/etc/httpd
--enable-mod_charset
--with-layout=PHP
--enable-sigchild
--enable-xml
--with-libxml-dir=/usr
--enable-simplexml
--enable-spl
--enable-filter
--disable-debug
--with-openssl=shared
--with-pcre-regex=/usr
--with-zlib=shared,/usr
--enable-bcmath=shared
--with-bz2=shared,/usr
--enable-calendar=shared
--enable-ctype=shared
--with-curl=shared
--with-curlwrappers
--with-mcrypt=/usr
--enable-dba=shared
--with-gdbm=/usr
--with-db4=/usr
--enable-dbase=shared
--enable-exif=shared
--enable-ftp=shared
--with-gd=shared
--with-jpeg-dir=/usr
--with-png-dir=/usr
--with-zlib-dir=/usr
--with-xpm-dir=/usr
--with-freetype-dir=/usr
--with-t1lib=/usr
--enable-gd-native-ttf
--enable-gd-jis-conv
--with-gettext=shared,/usr
--with-gmp=shared,/usr
--with-iconv=shared
--with-imap-ssl=/usr
--with-imap=$IMAPLIBDIR
--with-ldap=shared
--enable-mbstring=shared
--enable-hash
--with-mhash=shared,/usr
--with-mysql=shared,/usr
--with-mysqli=shared,/usr/bin/mysql_config
--enable-pdo=shared
--with-pdo-mysql=shared,/usr
--with-pdo-sqlite=shared
--with-pspell=shared,/usr
--with-mm=/usr
--enable-shmop=shared
--with-snmp=shared,/usr
--enable-soap=shared
--enable-sockets
--with-sqlite=shared
--enable-sqlite-utf8
--with-regex=php
--enable-sysvmsg
--enable-sysvsem
--enable-sysvshm
--enable-wddx=shared
--with-xsl=shared,/usr
--enable-zip=shared
--with-tsrm-pthreads
--enable-shared=yes
--enable-static=no
--with-gnu-ld
--with-pic
--build=$ARCH-slackware-linux