summaryrefslogtreecommitdiffstats
path: root/source/n/php
diff options
context:
space:
mode:
author Patrick J Volkerding <volkerdi@slackware.com>2012-09-26 01:10:42 +0000
committer Eric Hameleers <alien@slackware.com>2018-05-31 22:51:55 +0200
commit9664bee729d487bcc0a0bc35859f8e13d5421c75 (patch)
treeb428a16618e36ed864a8d76ea3435e19a452bf90 /source/n/php
parent75a4a592e5ccda30715f93563d741b83e0dcf39e (diff)
downloadcurrent-9664bee729d487bcc0a0bc35859f8e13d5421c75.tar.gz
current-9664bee729d487bcc0a0bc35859f8e13d5421c75.tar.xz
Slackware 14.0slackware-14.0
Wed Sep 26 01:10:42 UTC 2012 Slackware 14.0 x86_64 stable is released! We're perfectionists here at Slackware, so this release has been a long time a-brewing. But we think you'll agree that it was worth the wait. Slackware 14.0 combines modern components, ease of use, and flexible configuration... our "KISS" philosophy demands it. The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware project by picking up a copy from store.slackware.com. We're taking pre-orders now, and offer a discount if you sign up for a subscription. Thanks to everyone who helped make this happen. The Slackware team, the upstream developers, and (of course) the awesome Slackware user community. Have fun! :-)
Diffstat (limited to 'source/n/php')
-rw-r--r--source/n/php/doinst.sh24
-rwxr-xr-xsource/n/php/fetch-php.sh2
-rw-r--r--source/n/php/php-fpm.conf.diff28
-rwxr-xr-xsource/n/php/php.SlackBuild63
-rw-r--r--source/n/php/php.ini-development.diff19
-rw-r--r--source/n/php/php.session.save_path.diff22
6 files changed, 98 insertions, 60 deletions
diff --git a/source/n/php/doinst.sh b/source/n/php/doinst.sh
index eda8b0de9..2af731e95 100644
--- a/source/n/php/doinst.sh
+++ b/source/n/php/doinst.sh
@@ -3,6 +3,26 @@ if [ ! -r etc/httpd/mod_php.conf ]; then
elif [ "`cat etc/httpd/mod_php.conf 2> /dev/null`" = "" ]; then
cp -a etc/httpd/mod_php.conf.example etc/httpd/mod_php.conf
fi
-if [ ! -r etc/httpd/php.ini ]; then
- cp -a etc/httpd/php.ini-production etc/httpd/php.ini
+
+config() {
+ NEW="$1"
+ OLD="`dirname $NEW`/`basename $NEW .new`"
+ # If there's no config file by that name, mv it over:
+ if [ ! -r $OLD ]; then
+ mv $NEW $OLD
+ elif [ "`cat $OLD | md5sum`" = "`cat $NEW | md5sum`" ]; then # toss the redundant copy
+ rm $NEW
+ fi
+ # Otherwise, we leave the .new copy for the admin to consider...
+}
+# Keep same perms on rc.php-fpm.new:
+if [ -e etc/rc.d/rc.php-fpm ]; then
+ cp -a etc/rc.d/rc.php-fpm etc/rc.d/rc.php-fpm.new.incoming
+ cat etc/rc.d/rc.php-fpm.new > etc/rc.d/rc.php-fpm.new.incoming
+ mv etc/rc.d/rc.php-fpm.new.incoming etc/rc.d/rc.php-fpm.new
fi
+config etc/rc.d/rc.php-fpm.new
+cp -a etc/httpd/php.ini-production etc/httpd/php.ini.new
+config etc/httpd/php.ini.new
+cp -a etc/php-fpm.conf.default etc/php-fpm.conf.new
+config etc/php-fpm.conf.new
diff --git a/source/n/php/fetch-php.sh b/source/n/php/fetch-php.sh
index 5833da49c..6542c8bb8 100755
--- a/source/n/php/fetch-php.sh
+++ b/source/n/php/fetch-php.sh
@@ -1 +1 @@
-lftpget http://us2.php.net/distributions/php-5.3.6.tar.bz2
+lftpget http://us.php.net/distributions/php-5.4.7.tar.bz2
diff --git a/source/n/php/php-fpm.conf.diff b/source/n/php/php-fpm.conf.diff
new file mode 100644
index 000000000..e749185b6
--- /dev/null
+++ b/source/n/php/php-fpm.conf.diff
@@ -0,0 +1,28 @@
+--- ./sapi/fpm/php-fpm.conf.in.orig 2012-05-20 19:47:53.000000000 +0200
++++ ./sapi/fpm/php-fpm.conf.in 2012-05-21 09:16:32.646276661 +0200
+@@ -12,7 +12,7 @@
+ ; Relative path can also be used. They will be prefixed by:
+ ; - the global prefix if it's been set (-p arguement)
+ ; - @prefix@ otherwise
+-;include=etc/fpm.d/*.conf
++;include=etc/php-fpm/*.conf
+
+ ;;;;;;;;;;;;;;;;;;
+ ; Global Options ;
+@@ -22,14 +22,14 @@
+ ; Pid file
+ ; Note: the default prefix is @EXPANDED_LOCALSTATEDIR@
+ ; Default Value: none
+-;pid = run/php-fpm.pid
++pid = run/php-fpm.pid
+
+ ; Error log file
+ ; If it's set to "syslog", log is sent to syslogd instead of being written
+ ; in a local file.
+ ; Note: the default prefix is @EXPANDED_LOCALSTATEDIR@
+ ; Default Value: log/php-fpm.log
+-;error_log = log/php-fpm.log
++error_log = log/php-fpm.log
+
+ ; syslog_facility is used to specify what type of program is logging the
+ ; message. This lets syslogd specify that messages from different facilities
diff --git a/source/n/php/php.SlackBuild b/source/n/php/php.SlackBuild
index 7a1fc1fd6..e475f824e 100755
--- a/source/n/php/php.SlackBuild
+++ b/source/n/php/php.SlackBuild
@@ -3,7 +3,7 @@
# Build and package mod_php on Slackware.
# by: David Cantrell <david@slackware.com>
# Modified for PHP 4-5 by volkerdi@slackware.com
-# Copyright 2007, 2008, 2009, 2010, 2011 Patrick Volkerding, Sebeka, MN, USA
+# Copyright 2007, 2008, 2009, 2010, 2011, 2012 Patrick Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -24,9 +24,9 @@
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-VERSION=5.3.6
-ALPINE=2.00
-BUILD=${BUILD:-6}
+VERSION=5.4.7
+ALPINE=2.02
+BUILD=${BUILD:-1}
# Automatically determine the architecture we're building on:
if [ -z "$ARCH" ]; then
@@ -71,7 +71,7 @@ if [ -r $IMAPLIBDIR/lib${LIBDIRSUFFIX}/c-client.a ]; then
sleep 5
else
( cd $CWD/../alpine ; ./alpine.SlackBuild || exit 1 ) || exit 1
- ( cd $TMP/alpine-${ALPINE}/imap/c-client
+ ( cd $TMP/re-alpine-${ALPINE}/imap/c-client
strip -g c-client.a
mkdir -p $IMAPLIBDIR/lib${LIBDIRSUFFIX}
cp c-client.a $IMAPLIBDIR/lib${LIBDIRSUFFIX}
@@ -126,32 +126,45 @@ find . -name "*.orig" -exec rm {} \;
# Patch ini files:
zcat $CWD/php.ini-development.diff.gz | patch -p1 --verbose || exit 1
zcat $CWD/php.ini-development.diff.gz | patch -p1 --verbose php.ini-production || exit 1
-zcat $CWD/php.session.save_path.diff.gz | patch -p1 --verbose || exit 1
+zcat $CWD/php-fpm.conf.diff.gz | patch -p1 --verbose || exit 1
+
+# Install the build folder into /usr/lib$LIBDIRSUFFIX/php/build
+# and adapt phpize accordingly:
+sed -i "s|build$|php/build|" scripts/Makefile.frag
+sed -i "s|build\"$|php/build\"|" scripts/phpize.in
# Generic "kitchen sink" configure function, with as many things as possible (and
# maybe then some ;-) compiled as shared extensions:
-php_configure() {
EXTENSION_DIR=/usr/lib${LIBDIRSUFFIX}/php/extensions \
CFLAGS="$SLKCFLAGS" \
./configure \
- $* \
--prefix=/usr \
--libdir=/usr/lib${LIBDIRSUFFIX} \
--with-libdir=lib${LIBDIRSUFFIX} \
+ --localstatedir=/var \
--sysconfdir=/etc \
- --disable-safe-mode \
- --disable-magic-quotes \
- --enable-zend-multibyte \
+ --datarootdir=/usr/share \
+ --datadir=/usr/share \
+ --infodir=/usr/info \
+ --mandir=/usr/man \
+ --with-apxs2=/usr/bin/apxs \
+ --enable-fpm \
+ --with-fpm-user=apache \
+ --with-fpm-group=apache \
+ --enable-maintainer-zts \
+ --enable-pcntl \
--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 \
+ --disable-sigchild \
--enable-xml \
--with-libxml-dir=/usr \
--enable-simplexml \
+ --enable-xmlreader=shared \
+ --enable-dom=shared \
--enable-filter \
--disable-debug \
--with-openssl=shared \
@@ -177,7 +190,6 @@ CFLAGS="$SLKCFLAGS" \
--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 \
@@ -194,14 +206,11 @@ CFLAGS="$SLKCFLAGS" \
--with-pdo-sqlite=shared,/usr \
--with-pspell=shared,/usr \
--with-enchant=shared,/usr \
- --with-mm=/usr \
--enable-shmop=shared \
--with-snmp=shared,/usr \
--enable-soap=shared \
--enable-sockets \
- --with-sqlite=shared \
--with-sqlite3=shared \
- --enable-sqlite-utf8 \
--with-regex=php \
--enable-sysvmsg \
--enable-sysvsem \
@@ -210,12 +219,12 @@ CFLAGS="$SLKCFLAGS" \
--with-xsl=shared,/usr \
--enable-zip=shared \
--with-tsrm-pthreads \
+ --enable-intl=shared \
--enable-shared=yes \
--enable-static=no \
--with-gnu-ld \
--with-pic \
--build=$ARCH-slackware-linux
-}
# I am told this option is worse than nothing. :-)
# --enable-safe-mode
@@ -223,23 +232,12 @@ CFLAGS="$SLKCFLAGS" \
# I would recommend *against* and will take no responbility for turning on
# "safe" mode.
-# Make the Apache2 module version of PHP:
-php_configure \
- --with-apxs2=/usr/sbin/apxs
make $NUMJOBS || make || exit 1
make install INSTALL_ROOT=$PKG || exit 1
-# Make the CLI/CGI version of PHP:
-make distclean
-php_configure \
- --enable-pcntl \
- --enable-sigchild
-make $NUMJOBS || make || exit 1
-mkdir -p $PKG/usr/bin
-cat ./sapi/cli/php > $PKG/usr/bin/php
-cat ./sapi/cgi/php-cgi > $PKG/usr/bin/php-cgi
-chmod 755 $PKG/usr/bin/php
-chmod 755 $PKG/usr/bin/php-cgi
+mkdir -p $PKG/etc/{rc.d,php-fpm}
+cp sapi/fpm/init.d.php-fpm $PKG/etc/rc.d/rc.php-fpm.new
+chmod 644 $PKG/etc/rc.d/rc.php-fpm.new
# PHP (used to) install Pear with some strange permissions.
chmod 755 $PKG/usr/bin/pear
@@ -249,6 +247,9 @@ chmod 755 $PKG/usr/bin/pear
rm -rf .channels .depdb .depdblock .filemap .lock .registry
)
+# We do not package static extension libraries:
+rm -f $PKG/usr/lib${LIBDIRSUFFIX}/php/extensions/*.a
+
# Fix $PKG/usr/lib/php perms:
( cd $PKG/usr/lib${LIBDIRSUFFIX}/php
find . \
diff --git a/source/n/php/php.ini-development.diff b/source/n/php/php.ini-development.diff
index 49b441e6b..8c582e4db 100644
--- a/source/n/php/php.ini-development.diff
+++ b/source/n/php/php.ini-development.diff
@@ -1,6 +1,6 @@
---- ./php.ini-development.orig 2011-02-08 18:25:44.000000000 -0600
-+++ ./php.ini-development 2011-04-01 22:42:50.000000000 -0500
-@@ -938,6 +938,44 @@
+--- ./php.ini-development.orig 2012-07-18 01:19:16.000000000 -0500
++++ ./php.ini-development 2012-08-08 20:06:33.512546116 -0500
+@@ -859,6 +859,46 @@
; If you only provide the name of the extension, PHP will look for it in its
; default extension directory.
;
@@ -15,6 +15,7 @@
+extension=ctype.so
+extension=curl.so
+extension=dba.so
++extension=dom.so
+extension=enchant.so
+extension=exif.so
+extension=ftp.so
@@ -22,6 +23,7 @@
+extension=gettext.so
+extension=gmp.so
+extension=iconv.so
++extension=intl.so
+extension=ldap.so
+extension=mbstring.so
+extension=mysql.so
@@ -34,10 +36,10 @@
+extension=shmop.so
+extension=snmp.so
+extension=soap.so
-+extension=sqlite.so
+extension=sqlite3.so
+extension=tokenizer.so
+extension=wddx.so
++extension=xmlreader.so
+extension=xsl.so
+extension=zip.so
+extension=zlib.so
@@ -45,3 +47,12 @@
; Windows Extensions
; Note that ODBC support is built in, so no dll is needed for it.
; Note that many DLL files are located in the extensions/ (PHP 4) ext/ (PHP 5)
+@@ -1391,7 +1431,7 @@
+ ; where MODE is the octal representation of the mode. Note that this
+ ; does not overwrite the process's umask.
+ ; http://php.net/session.save-path
+-;session.save_path = "/tmp"
++session.save_path = "/var/lib/php"
+
+ ; Whether to use cookies.
+ ; http://php.net/session.use-cookies
diff --git a/source/n/php/php.session.save_path.diff b/source/n/php/php.session.save_path.diff
deleted file mode 100644
index 60d6f072e..000000000
--- a/source/n/php/php.session.save_path.diff
+++ /dev/null
@@ -1,22 +0,0 @@
---- ./php.ini-development.orig 2011-04-14 14:26:44.551000001 -0500
-+++ ./php.ini-development 2011-04-14 14:38:48.591000954 -0500
-@@ -1506,7 +1506,7 @@
- ; where MODE is the octal representation of the mode. Note that this
- ; does not overwrite the process's umask.
- ; http://php.net/session.save-path
--;session.save_path = "/tmp"
-+session.save_path = "/var/lib/php"
-
- ; Whether to use cookies.
- ; http://php.net/session.use-cookies
---- ./php.ini-production.orig 2011-04-14 14:26:44.558000001 -0500
-+++ ./php.ini-production 2011-04-14 14:39:09.598999155 -0500
-@@ -1513,7 +1513,7 @@
- ; where MODE is the octal representation of the mode. Note that this
- ; does not overwrite the process's umask.
- ; http://php.net/session.save-path
--;session.save_path = "/tmp"
-+session.save_path = "/var/lib/php"
-
- ; Whether to use cookies.
- ; http://php.net/session.use-cookies