Ticket #29852: patch-Portfile

File patch-Portfile, 2.0 KB (added by BjarneDMat, 13 years ago)
Line 
1--- /macports/var/macports/sources/rsync.macports.org/release/ports/php/php5-eaccelerator/Portfile      2011-06-16 20:00:19.000000000 +0200
2+++ portfiles/php/php5-eaccelerator/Portfile    2011-06-16 22:29:56.000000000 +0200
3@@ -1,16 +1,14 @@
4-# $Id: Portfile 79534 2011-06-16 17:56:31Z ryandesign@macports.org $
5+# $Id: Portfile 77002 2011-03-17 16:58:30Z jwa@macports.org $
6 
7 PortSystem        1.0
8-PortGroup         php5extension 1.0
9+PortGroup         php5extension 1.1
10 
11 epoch             1
12 php5extension.setup eaccelerator 0.9.6.1
13-revision          2
14+revision          3
15 categories        php www devel
16 platforms         darwin freebsd openbsd
17 maintainers       nomaintainer
18-conflicts         php5-apc php5-xcache
19-
20 homepage          http://eaccelerator.net/
21 description       php5 extension for PHP acceleration, optimization, and dynamic content caching
22 long_description \
23@@ -21,6 +19,8 @@
24     execution. eAccelerator typically reduces server load and increases the \
25     speed of your PHP code by 1-10 times.
26 
27+conflicts         php5-apc  php5-xcache
28+
29 master_sites      http://bart.eaccelerator.net/source/${version}/
30 
31 checksums         md5     32ccd838e06ef5613c2610c1c65ed228 \
32@@ -30,6 +30,17 @@
33 use_bzip2         yes
34 configure.args    --with-php-config=${prefix}/bin/php-config
35 
36+post-destroot {
37+    reinplace "s|PREFIX|${prefix}|" ${php5extension.iniFile}
38+    reinplace "s|NAME|${name}|"     ${php5extension.iniFile}
39+    set cacheDir    [ exec sed -E -e "/cache_dir/!d" -e "s/.*\"(.*)\".*/\\1/" ${php5extension.iniFile} ]
40+    file mkdir      ${cacheDir}
41+    file attributes ${cacheDir} -permissions 0777
42+    set logDir      [ file dirname [ exec sed -E -e "/log_file/!d" -e "s/.*\"(.*)\".*/\\1/" ${php5extension.iniFile} ] ]
43+    file mkdir      ${logDir}
44+    file attributes ${logDir}   -permissions 0777
45+}
46+
47 variant shared_memory description {Enable shared memory access functions [only enable in trusted environments]} {
48     configure.args-append --with-eaccelerator-shared-memory
49 }