Annotation of /trunk/extras/php5/php5-5.2.10-r1.smage2
Parent Directory | Revision Log
Revision 2154 -
(hide annotations)
(download)
Mon Jul 6 18:21:31 2009 UTC (14 years, 10 months ago) by niro
File size: 4848 byte(s)
Mon Jul 6 18:21:31 2009 UTC (14 years, 10 months ago) by niro
File size: 4848 byte(s)
auto added: ver bump to 5.2.10-r1
1 | niro | 2154 | # $Id$ |
2 | |||
3 | PNAME="php5" | ||
4 | PVER="5.2.10" | ||
5 | PBUILD="r1" | ||
6 | |||
7 | PCATEGORIE="dev-lang" | ||
8 | STATE="unstable" | ||
9 | |||
10 | DESCRIPTION="PHP Hypertext Preprocessor, a scripting language especially suited for web development." | ||
11 | HOMEPAGE="http://php.net/" | ||
12 | |||
13 | DEPEND=">= net-www/apache2-2.2.11 | ||
14 | >= sys-libs/ncurses-5.7 | ||
15 | >= sys-libs/readline-6.0 | ||
16 | >= sys-libs/zlib-1.2 | ||
17 | >= app-arch/bzip2-1 | ||
18 | >= dev-libs/libxml2-2.7 | ||
19 | >= dev-libs/libxslt-1.1.24 | ||
20 | >= dev-libs/openssl-0.9.8 | ||
21 | >= dev-libs/libpcre-7.9 | ||
22 | >= dev-libs/gmp-4.3 | ||
23 | >= media-libs/libjpeg-6b | ||
24 | >= media-libs/libpng-1.2 | ||
25 | >= x11-libs/libXpm-3.5 | ||
26 | >= media-libs/gd-2.0 | ||
27 | >= media-libs/freetype-2 | ||
28 | >= media-libs/t1lib-5.1 | ||
29 | >= net-misc/curl-7.19 | ||
30 | >= app-text/aspell-0.60 | ||
31 | >= dev-db/db-4.7 | ||
32 | >= dev-db/sqlite-3.6 | ||
33 | >= dev-db/mysql5-5.1 | ||
34 | >= dev-db/unixodbc-2.2 | ||
35 | >= net-dns/libidn-1.14" | ||
36 | |||
37 | # ToDO: mcrypt, imap, mhash, htmltidy | ||
38 | |||
39 | SDEPEND=">= sys-apps/sed-4 | ||
40 | >= sys-dev/m4-1.4 | ||
41 | >= sys-dev/libtool-1.5 | ||
42 | >= sys-dev/gettext-0.17" | ||
43 | |||
44 | SRCFILE="${PNAME/5/}-${PVER}.tar.bz2" | ||
45 | SRCDIR="${BUILDDIR}/${PNAME/5/}-${PVER}" | ||
46 | |||
47 | SUHOSIN_PVER="0.9.7" | ||
48 | PHP5_EXTENSIONS_DIR="/usr/$(mlibdir)/${PNAME}/extensions" | ||
49 | |||
50 | sminclude mtools | ||
51 | |||
52 | SRC_URI=( | ||
53 | http://de2.php.net/distributions/${SRCFILE} | ||
54 | http://us2.php.net/distributions/${SRCFILE} | ||
55 | mirror://${PNAME}/${SRCFILE} | ||
56 | mirror://${PNAME}/${PNAME}-5.2.4-multilib.patch | ||
57 | mirror://${PNAME}/${PNAME}-5.2.3-httpd-config.patch | ||
58 | mirror://${PNAME}/${PNAME}-5.2.4-build-dir.patch | ||
59 | mirror://${PNAME}/${PNAME}-${PVER}-suhosin-${SUHOSIN_PVER}.patch | ||
60 | mirror://${PNAME}/php5_module.conf | ||
61 | ) | ||
62 | |||
63 | src_prepare() | ||
64 | { | ||
65 | munpack ${SRCFILE} || die | ||
66 | cd ${SRCDIR} | ||
67 | |||
68 | # fixes some issues with db4 | ||
69 | sed -i 's/const char \*errpfx,/const DB_ENV *dbenv, & const/' ext/dba/dba_db4.c || die | ||
70 | |||
71 | # version branding | ||
72 | sed -i "s:^\(EXTRA_VERSION=\).*:\1-magellan-${PBUILD}:" configure.in || die | ||
73 | |||
74 | # fixes multilib search pathes | ||
75 | mpatch ${PNAME}-5.2.4-multilib.patch || die | ||
76 | |||
77 | # do not touch the system httpd.conf | ||
78 | mpatch ${PNAME}-5.2.3-httpd-config.patch || die | ||
79 | |||
80 | # fixes build dir -> /usr/lib/php5/build | ||
81 | mpatch ${PNAME}-5.2.4-build-dir.patch || die | ||
82 | |||
83 | # hardend php core patch | ||
84 | # see: http://www.hardened-php.net/suhosin/index.html | ||
85 | mpatch ${PNAME}-${PVER}-suhosin-${SUHOSIN_PVER}.patch || die | ||
86 | |||
87 | # rebuild configure | ||
88 | autoreconf --force --install || die | ||
89 | |||
90 | # force use of system libtool | ||
91 | mlibtoolize || die | ||
92 | } | ||
93 | |||
94 | src_compile() | ||
95 | { | ||
96 | cd ${SRCDIR} | ||
97 | |||
98 | # --with-libdir needed, doesn't honor --libdir | ||
99 | mconfigure \ | ||
100 | --with-libdir=$(mlibdir) \ | ||
101 | --with-config-file-path=/etc/${PNAME} \ | ||
102 | --with-config-file-scan-dir=/etc/${PNAME}/conf.d \ | ||
103 | --without-pear \ | ||
104 | --with-apxs2 \ | ||
105 | --enable-force-cgi-redirect \ | ||
106 | --enable-fastcgi \ | ||
107 | --enable-discard-path \ | ||
108 | --with-zlib \ | ||
109 | --with-bz2=shared \ | ||
110 | --enable-bcmath=shared \ | ||
111 | --enable-calendar=shared \ | ||
112 | --enable-exif \ | ||
113 | --enable-ftp=shared \ | ||
114 | --with-gettext \ | ||
115 | --enable-mbstring=shared \ | ||
116 | --with-ncurses=shared \ | ||
117 | --with-readline \ | ||
118 | --with-openssl \ | ||
119 | --with-gd=shared,/usr \ | ||
120 | --enable-gd-native-ttf \ | ||
121 | --with-freetype-dir=/usr \ | ||
122 | --with-ttf \ | ||
123 | --with-t1lib=/usr \ | ||
124 | --with-pcre-regex \ | ||
125 | --with-gmp \ | ||
126 | --with-curl \ | ||
127 | --with-curlwrappers \ | ||
128 | --enable-dba=shared \ | ||
129 | --with-db4 \ | ||
130 | --with-mysql=shared \ | ||
131 | --with-mysqli=shared \ | ||
132 | --with-unixODBC=shared,/usr \ | ||
133 | --with-sqlite=shared \ | ||
134 | --enable-pdo=shared \ | ||
135 | --with-pdo-odbc=shared,unixODBC,/usr \ | ||
136 | --with-pdo-mysql=shared,/usr \ | ||
137 | --with-pdo-sqlite=shared,/usr \ | ||
138 | --enable-dbase=shared \ | ||
139 | --enable-dom=shared \ | ||
140 | --with-xmlrpc=shared \ | ||
141 | --enable-xmlreader=shared \ | ||
142 | --enable-xmlwriter=shared \ | ||
143 | --with-xsl=shared,/usr \ | ||
144 | --enable-json=shared \ | ||
145 | --enable-zip=shared \ | ||
146 | --enable-sockets=shared \ | ||
147 | --enable-sysvsem=shared \ | ||
148 | --enable-sysvshm=shared \ | ||
149 | --enable-sysvmsg=shared \ | ||
150 | || die | ||
151 | |||
152 | # ToDo: | ||
153 | # --with-mcrypt=shared \ | ||
154 | # --with-mhash=shared \ | ||
155 | # --with-imap=shared \ | ||
156 | # --with-imap-ssl \ | ||
157 | # --with-tidy=shared \ | ||
158 | |||
159 | mmake || die | ||
160 | } | ||
161 | |||
162 | src_install() | ||
163 | { | ||
164 | cd ${SRCDIR} | ||
165 | mmake INSTALL_ROOT=${BINDIR} EXTENSION_DIR=${PHP5_EXTENSIONS_DIR} install || die | ||
166 | |||
167 | # php config | ||
168 | minstalldir /etc/${PNAME}/conf.d || die | ||
169 | # fix extensions dir location | ||
170 | sed -i "s:^\(extension_dir =\).*:\1 ${PHP5_EXTENSIONS_DIR}:" php.ini-recommended || die | ||
171 | # allow short php open-tags | ||
172 | sed -i "s:^\(short_open_tag =\).*:\1 On:" php.ini-recommended || die | ||
173 | minstallfile php.ini-recommended /etc/${PNAME}/php.ini || die | ||
174 | |||
175 | # fix extension_dir also in php-config | ||
176 | sed -i "s:^\(extension_dir=\).*:\1${PHP5_EXTENSIONS_DIR}:" ${BINDIR}/usr/bin/php-config || die | ||
177 | |||
178 | # install apache module config | ||
179 | minstalldir /etc/apache2/modules.d || die | ||
180 | minstallfile -s php5_module.conf /etc/apache2/modules.d/php5.conf || die | ||
181 | |||
182 | # enable all default extensions | ||
183 | local i | ||
184 | for i in $(ls ${BINDIR}/${PHP5_EXTENSIONS_DIR}/*.so | sort ) | ||
185 | do | ||
186 | echo "extension=$(basename ${i})" \ | ||
187 | > ${BINDIR}/etc/${PNAME}/conf.d/$(basename ${i} .so).ini || die | ||
188 | done | ||
189 | |||
190 | minstalldocs CREDITS CODING_STANDARDS EXTENSIONS LICENSE NEWS README* TODO* || die | ||
191 | } |
Properties
Name | Value |
---|---|
svn:keywords | Id |