]> git.pld-linux.org Git - packages/php.git/blob - php.spec
- manual added
[packages/php.git] / php.spec
1 Summary:        The PHP HTML-embedded scripting language for use with Apache.
2 Summary(fr):    Le langage de script embarque-HTML PHP pour Apache.
3 Summary(pl):    Jêzyk skryptowy PHP -- u¿ywany wraz z serwerem Apache.
4 Name:           php
5 Version:        4.0b4pl1
6 Release:        1
7 Group:          Libraries
8 Group(fr):      Librairies
9 Group(pl):      Biblioteki
10 License:        GPL
11 Source0:        http://www.php.net/distributions/%{name}-%{version}.tar.gz
12 Source1:        FAQ.php
13 Source2:        php.ini
14 Source3:        zend.gif
15 Source4:        http://www.php.net/distributions/manual.tar.gz
16 Icon:           php4.gif
17 URL:            http://www.php.net/
18 BuildRequires:  apache(EAPI)-devel
19 BuildRequires:  zlib-devel
20 BuildRequires:  mysql-devel >= 3.22.30-2
21 BuildRequires:  kaffe-devel
22 BuildRequires:  libxml-devel >= 1.0.0
23 BuildRequires:  postgresql-devel
24 BuildRequires:  gd-devel
25 Requires:       apache(EAPI) >= 1.3.9
26 Prereq:         /usr/sbin/apxs
27 BuildRoot:      /tmp/%{name}-%{version}-root
28
29 %define         _pkglibdir      %{_libdir}/apache
30
31 %description
32 PHP is an HTML-embedded scripting language.  PHP attempts to make it easy
33 for developers to write dynamically generated web pages.  PHP also offers
34 built-in database integration for several commercial and non-commercial
35 database management systems, so writing a database-enabled web page with
36 PHP is fairly simple.  The most common use of PHP coding is probably as a
37 replacement for CGI scripts.  The mod_php module enables the Apache web
38 server to understand and process the embedded PHP language in web pages.
39 This package contains PHP version %{version}.  If you use applications which
40 specifically rely on PHP/FI (PHP v2 and earlier), you should instead install
41 the PHP/FI module contained in the phpfi package.  If you're just starting
42 with PHP, you should install this package.  You'll also need to install
43 the Apache web server.
44
45 %description -l fr
46 PHP est un langage de script embarque dans le HTM. PHP essaye de rendre
47 simple aux developpeurs d'ecrire des pages web generees dynamiquement.
48 PHP incorpore egalement une integration avec plusieurs systemes de gestion
49 de bases de donnees commerciaux et non-connerciaux, qui rent facile
50 la creation de pages web liees avec des bases de donnees. L'utilisation la
51 plus commune de PHP est probablement en remplacement de scripts CGI. Le
52 module mod_php permet au serveur web apache de comprendre et de traiter le
53 langage PHP integre dans des pages web.
54 Ce package contient PHP version %{version}. Si vous utilisez des
55 applications qui utilisent specifiquement PHP/FI, vous devrez installer le
56 module PHP/FI inclus dans le package mod_php. Si vous debutez avec PHP, vous
57 devriez installer ce package. Vous aurez egalement besoin d'installer le
58 serveur web Apache.
59
60 %description -l pl
61 PHP jest jêzykiem skryptowym, którego polecenia umieszcza siê w plikach
62 HTML. Pakiet ten zawiera modu³ przeznaczony dla serwera HTTP (jak np.
63 Apache), który interpretuje te polecenia.  Umo¿liwia to tworzenie
64 dynamicznie stron WWW. Spora czê¶æ sk³adni PHP zapo¿yczona zosta³a
65 z jêzyków: C, Java i Perl.
66
67 %package mysql
68 Summary:        MySQL database module for PHP4
69 Summary(pl):    Modu³ bazy danych MySQL dla PHP4
70 Group:          Libraries
71 Group(fr):      Librairies
72 Group(pl):      Biblioteki
73 Requires:       %{name} = %{version}
74
75 %description mysql
76 This is a dynamic shared object (DSO) for Apache that will add MySQL
77 database support to PHP4.  If you need back-end support for MySQL,
78 you should install this package in addition to the main %{name} package.
79
80 %description mysql -l pl
81
82 %package pgsql
83 Summary:        PostgreSQL database module for PHP4
84 Summary(pl):    Modu³ bazy danych PostgreSQL dla PHP4
85 Group:          Libraries
86 Group(fr):      Librairies
87 Group(pl):      Biblioteki
88 Requires:       %{name} = %{version}
89
90 %description pgsql
91 This is a dynamic shared object (DSO) for Apache that will add PostgreSQL
92 database support to PHP4.  If you need back-end support for PostgreSQL,
93 you should install this package in addition to the main %{name} package.
94
95 %description pgsql -l pl
96
97 %package gd
98 Summary:        GD extension module for PHP4
99 Summary:        Modu³ GD dla PHP4
100 Group:          Libraries
101 Group(fr):      Librairies
102 Group(pl):      Biblioteki
103 Requires:       %{name} = %{version}
104
105 %description gd
106 This is a dynamic shared object (DSO) for Apache that will add GD
107 support to PHP4. You should install this package in addition to the main
108 %{name} package if you want to create and manipulate images with PHP.
109
110 %description gd -l pl
111
112 %package java
113 Summary:        Java extension module for PHP4
114 Summary(pl):    Modu³ Javy dla PHP4
115 Group:          Libraries
116 Group(fr):      Librairies
117 Group(pl):      Biblioteki
118 Requires:       %{name} = %{version}
119
120 %description java
121 This is a dynamic shared object (DSO) for Apache that will add JAVA
122 support to PHP4. This extension provides a simple and effective means
123 for creating and invoking methods on Java objects from PHP.
124
125 %description java -l pl
126
127 %package xml
128 Summary:        XML extension module for PHP4
129 Summary(pl):    Modu³ XML dla PHP4
130 Group:          Libraries
131 Group(fr):      Librairies
132 Group(pl):      Biblioteki
133 Requires:       %{name} = %{version}
134
135 %description xml
136 This is a dynamic shared object (DSO) for Apache that will add XML
137 support to PHP4. This extension lets you create XML parsers and then
138 define handlers for different XML events. If you want to be able to parse
139 XML documents you should install this package in addition to the main 
140 %{name} package.
141
142 %description xml -l pl
143
144 %package doc
145 Summary:     Online manual for PHP4
146 Summary(pl): Dokumentacja dla PHP4
147 Group:       Networking/Daemons
148
149 %description doc
150 Comprehensive documentation for PHP4, viewable through your web server, too!
151
152 %description doc -l pl
153 Dokumentacja dla pakietu PHP4.  Mo¿na j± równie¿ ogl±daæ poprzez serwer WWW.
154
155 %prep
156 %setup -q 
157
158 %build
159 LDFLAGS=""; export LDFLAGS
160 CFLAGS="$RPM_OPT_FLAGS -DEAPI"; export CFLAGS
161 ./buildconf
162 %configure \
163         --with-apxs=%{_sbindir}/apxs \
164         --with-config-file-path=%{_sysconfdir}/httpd \
165         --with-exec-dir=%{_bindir} \
166         --disable-debug \
167         --enable-magic-quotes \
168         --enable-shared \
169         --enable-track-vars \
170         --enable-safe-mode \
171         --enable-trans-sid \
172         --enable-sysvsem \
173         --enable-sysvshm \
174         --enable-xml=shared \
175         --with-zlib \
176         --with-regex=system \
177         --with-gettext \
178         --with-mysql=shared \
179         --with-gd=shared \
180         --with-dbase \
181         --with-filepro \
182         --with-ftp \
183         --with-hyperwave \
184         --with-java \
185         --with-pgsql=shared,/usr
186
187 #       --with-snmp=shared 
188
189 make
190
191
192 %install
193 rm -rf $RPM_BUILD_ROOT
194 install -d $RPM_BUILD_ROOT{%{_pkglibdir}/php,%{_sysconfdir}/httpd} \
195                 $RPM_BUILD_ROOT/home/httpd/html/{icons,docs,docs/php4-doc}
196
197
198 install .libs/*.so      $RPM_BUILD_ROOT%{_pkglibdir}
199 install modules/*.so    $RPM_BUILD_ROOT%{_pkglibdir}/php
200
201 install %{SOURCE2}              $RPM_BUILD_ROOT%{_sysconfdir}/httpd/php.ini
202 install %{SOURCE3} php4.gif     $RPM_BUILD_ROOT/home/httpd/html/icons
203
204 cd $RPM_BUILD_ROOT/home/httpd/html/docs/php4-doc
205 tar zxf %{SOURCE4}
206 ln -s manual.html index.html
207 cd -
208
209 strip --strip-unneeded  \
210         $RPM_BUILD_ROOT%{_pkglibdir}/*.so \
211         $RPM_BUILD_ROOT%{_pkglibdir}/php/*.so
212
213 install  %{SOURCE1}     .
214 gzip -9nf CODING_STANDARDS CREDITS FAQ* ChangeLog FUNCTION_LIST.txt \
215         MAINTAINERS MODULES_STATUS NEWS TODO*
216
217 %post
218 /usr/sbin/apxs -e -a -n php4 %{_pkglibdir}/libphp4.so 1>&2
219 if [ -f /var/lock/subsys/httpd ]; then
220         /etc/rc.d/init.d/httpd restart 1>&2
221 fi
222
223
224 %preun
225 if [ "$1" = "0" ]; then
226         /usr/sbin/apxs -e -A -n php4 %{_pkglibdir}/libphp4.so 1>&2
227         if [ -f /var/lock/subsys/httpd ]; then
228                 /etc/rc.d/init.d/httpd restart 1>&2
229         fi
230 fi
231
232 %post mysql
233 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
234         echo "activating module 'mysql.so' in /etc/httpd/php.ini" 1>&2
235         perl -pi -e 's|^;extension=mysql.so|extension=mysql.so|g' \
236         %{_sysconfdir}/httpd/php.ini
237 fi
238 if [ -f /var/lock/subsys/httpd ]; then
239         /etc/rc.d/init.d/httpd restart 1>&2
240 fi
241
242 %postun mysql
243 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
244         echo "deactivating module 'mysql.so' in /etc/httpd/php.ini" 1>&2
245         perl -pi -e 's|^extension=mysql.so|;extension=mysql.so|g' \
246         %{_sysconfdir}/httpd/php.ini
247 fi
248 if [ -f /var/lock/subsys/httpd ]; then
249         /etc/rc.d/init.d/httpd restart 1>&2
250 fi
251
252 %post pgsql
253 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
254         echo "activating module 'pgsql.so' in /etc/httpd/php.ini" 1>&2
255         perl -pi -e 's|^;extension=pgsql.so|extension=pgsql.so|g' \
256         %{_sysconfdir}/httpd/php.ini
257 fi
258 if [ -f /var/lock/subsys/httpd ]; then
259         /etc/rc.d/init.d/httpd restart 1>&2
260 fi
261
262 %postun pgsql
263 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
264         echo "deactivating module 'pgsql.so' in /etc/httpd/php.ini" 1>&2
265         perl -pi -e 's|^extension=pgsql.so|;extension=pgsql.so|g' \
266         %{_sysconfdir}/httpd/php.ini
267 fi
268 if [ -f /var/lock/subsys/httpd ]; then
269         /etc/rc.d/init.d/httpd restart 1>&2
270 fi
271
272 %post gd
273 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
274         echo "activating module 'gd.so' in /etc/httpd/php.ini" 1>&2
275         perl -pi -e 's|^;extension=gd.so|extension=gd.so|g' \
276         %{_sysconfdir}/httpd/php.ini
277 fi
278 if [ -f /var/lock/subsys/httpd ]; then
279         /etc/rc.d/init.d/httpd restart 1>&2
280 fi
281
282 %postun gd
283 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
284         echo "deactivating module 'gd.so' in /etc/httpd/php.ini" 1>&2
285         perl -pi -e 's|^extension=gd.so|;extension=gd.so|g' \
286         %{_sysconfdir}/httpd/php.ini
287 fi
288 if [ -f /var/lock/subsys/httpd ]; then
289         /etc/rc.d/init.d/httpd restart 1>&2
290 fi
291
292 %post xml
293 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
294         echo "activating module 'xml.so' in /etc/httpd/php.ini" 1>&2
295         perl -pi -e 's|^;extension=xml.so|extension=xml.so|g' \
296         %{_sysconfdir}/httpd/php.ini
297 fi
298 if [ -f /var/lock/subsys/httpd ]; then
299         /etc/rc.d/init.d/httpd restart 1>&2
300 fi
301
302 %postun xml
303 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
304         echo "deactivating module 'xml.so' in /etc/httpd/php.ini" 1>&2
305         perl -pi -e 's|^extension=xml.so|;extension=xml.so|g' \
306         %{_sysconfdir}/httpd/php.ini
307 fi
308 if [ -f /var/lock/subsys/httpd ]; then
309         /etc/rc.d/init.d/httpd restart 1>&2
310 fi
311
312 %post java
313 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
314         echo "activating module 'libphp_java.so' in /etc/httpd/php.ini" 1>&2
315         perl -pi -e 's|^;extension=libphp_java.so|extension=libphp_java.so|g' \
316         %{_sysconfdir}/httpd/php.ini
317 fi
318 if [ -f /var/lock/subsys/httpd ]; then
319         /etc/rc.d/init.d/httpd restart 1>&2
320 fi
321
322 %postun java
323 if [ -f %{_sysconfdir}/httpd/php.ini ]; then
324         echo "deactivating module 'libphp_java.so' in /etc/httpd/php.ini" 1>&2
325         perl -pi -e 's|^extension=libphp_java.so|;extension=libphp_java.so|g' \
326         %{_sysconfdir}/httpd/php.ini
327 fi
328 if [ -f /var/lock/subsys/httpd ]; then
329         /etc/rc.d/init.d/httpd restart 1>&2
330 fi
331
332 %clean
333 rm -rf $RPM_BUILD_ROOT
334
335 %files
336 %defattr(644,root,root,755)
337 %doc {CODING_STANDARDS,CREDITS,FAQ*,ChangeLog,FUNCTION_LIST.txt}.gz
338 %doc {MAINTAINERS,MODULES_STATUS,NEWS,TODO*}.gz  
339
340 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/httpd/*
341 %dir %{_pkglibdir}/php
342
343 #%attr(755,root,root) %{_libdir}/apache/php/*.so
344
345 /home/httpd/html/icons/*
346
347 %attr(755,root,root) %{_pkglibdir}/libphp4.so
348
349 %files mysql
350 %defattr(644,root,root,755)
351 %attr(755,root,root) %{_pkglibdir}/php/mysql.so
352
353 %files pgsql
354 %defattr(644,root,root,755)
355 %attr(755,root,root) %{_pkglibdir}/php/pgsql.so
356
357 %files gd
358 %defattr(644,root,root,755)
359 %attr(755,root,root) %{_pkglibdir}/php/gd.so
360
361 %files xml
362 %defattr(644,root,root,755)
363 %attr(755,root,root) %{_pkglibdir}/php/xml.so
364
365 %files java
366 %defattr(644,root,root,755)
367 %attr(755,root,root) %{_pkglibdir}/php/libphp_java.so
368
369 %files doc
370 /home/httpd/html/docs/php4-doc
This page took 0.128253 seconds and 4 git commands to generate.