summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Orlitzky <mjo@gentoo.org>2016-01-05 14:10:55 -0500
committerMichael Orlitzky <mjo@gentoo.org>2016-01-05 14:10:55 -0500
commit1ae81f5e49a93e7380cb2a7c9931beb11149874d (patch)
tree68300d197b52a668a6cffc3e29bbf6f19e53416f /app-eselect/eselect-php/files
parentapp-misc/c_rehash: add Prefix keywords (diff)
downloadgentoo-1ae81f5e49a93e7380cb2a7c9931beb11149874d.tar.gz
gentoo-1ae81f5e49a93e7380cb2a7c9931beb11149874d.tar.bz2
gentoo-1ae81f5e49a93e7380cb2a7c9931beb11149874d.zip
app-eselect/eselect-php: new revision with backwards-compatible apache config.
If the user has an unmodified 70_mod_php5.conf, the previous revision will allow that file to be removed. This can break PHP support in Apache before the user notices that he needs to run eselect-php and update his Apache -DPHP5 line. In this revision we supply the latest copy of 70_mod_php5.conf for backwards compatibility. There is now a notice at the top of that file informing users to upgrade their configuration. Package-Manager: portage-2.2.24
Diffstat (limited to 'app-eselect/eselect-php/files')
-rw-r--r--app-eselect/eselect-php/files/70_mod_php5.backcompat.conf28
1 files changed, 28 insertions, 0 deletions
diff --git a/app-eselect/eselect-php/files/70_mod_php5.backcompat.conf b/app-eselect/eselect-php/files/70_mod_php5.backcompat.conf
new file mode 100644
index 000000000000..bd79f78aa6be
--- /dev/null
+++ b/app-eselect/eselect-php/files/70_mod_php5.backcompat.conf
@@ -0,0 +1,28 @@
+###########
+# WARNING #
+###########
+#
+# This file is provided for backwards compatibility only. The Apache
+# PHP configuration is now located in 70_mod_php.conf and requires you
+# to set -DPHP in your Apache conf.d file. Please examine
+# 70_mod_php.conf and update your Apache configuration to use -DPHP
+# instead of -DPHP5. Afterwards you may delete this file.
+#
+<IfDefine PHP5>
+ # Load the module first
+ <IfModule !mod_php5.c>
+ LoadModule php5_module modules/libphp5.so
+ </IfModule>
+
+ # Set it to handle the files
+ # NOTE: Avoiding AddHandler/AddType for security (bug #538822)
+ # NOTE: Please read the related news item!
+ <FilesMatch "\.(php|php5|phtml)$">
+ SetHandler application/x-httpd-php
+ </FilesMatch>
+ <FilesMatch "\.phps$">
+ SetHandler application/x-httpd-php-source
+ </FilesMatch>
+
+ DirectoryIndex index.php index.phtml
+</IfDefine>