2 # - Unusable in PLD Linux as our PHP is compiled with ZTS, while this extension is not
3 # - Can't find what Free Download means (http://www.zend.com/free_download/list)
4 %define php4_version 4.4
5 %define php5_version 5.2
6 Summary: The Zend Debug Server enables remote debugging of PHP applications
10 License: Free Download
11 Group: Development/Languages/PHP
12 Source0: http://downloads.zend.com/pdt/server-debugger/%{name}-%{version}-linux-glibc21-i386.tar.gz
13 # NoSource0-md5: d2ee7659c0c8721221696cab5e765936
15 Source1: http://downloads.zend.com/pdt/server-debugger/%{name}-%{version}-linux-glibc23-x86_64.tar.gz
16 # NoSource1-md5: 3238904ebd1accd5795a50fb88fc6fff
18 URL: http://www.zend.com/store/software/zend_studio
19 BuildRequires: tar >= 1:1.15.1
20 ExclusiveArch: %{ix86} %{x8664}
21 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23 %define _datadir %{_prefix}/share/Zend
24 %define no_install_post_strip 1
25 %define no_install_post_chrpath 1
26 %define _php4_extensiondir %{_libdir}/php4
27 %define _php5_extensiondir %{_libdir}/php
28 %define _php4_sysconfdir /etc/php4/conf.d
29 %define _php5_sysconfdir /etc/php/conf.d
32 The Zend Debug Server enables remote debugging of PHP applications. It
33 plugs into a PHP server and allows the Zend Development Environment to
34 control the execution of PHP applications on the server.
36 The Debug Server is designed be deployed safely on production servers.
37 It does not affect server performance and features access-list based
38 security for protecting the server from unauthorized access.
40 %package -n php4-%{name}
41 Summary: Zend Debugger for PHP 4.x
42 Group: Development/Languages/PHP
43 Requires: php4(thread-safety) = 0
44 Requires: php4-common < 3:%(awk 'BEGIN{print %{php4_version} + 0.1}')
45 Requires: php4-common >= 3:%{php4_version}
46 Conflicts: ZendStudioServer <= 5.2.0
48 %description -n php4-%{name}
49 The Zend Debug Server enables remote debugging of PHP applications. It
50 plugs into a PHP server and allows the Zend Development Environment to
51 control the execution of PHP applications on the server.
53 The Debug Server is designed be deployed safely on production servers.
54 It does not affect server performance and features access-list based
55 security for protecting the server from unauthorized access.
57 %package -n php-%{name}
58 Summary: Zend Debugger for PHP 5.x
59 Group: Development/Languages/PHP
60 Requires: php-common < 4:%(awk 'BEGIN{print %{php5_version} + 0.1}')
61 Requires: php-common >= 4:%{php5_version}
62 Requires: php5(thread-safety) = 0
63 Conflicts: ZendStudioServer <= 5.2.0
65 %description -n php-%{name}
66 The Zend Debug Server enables remote debugging of PHP applications. It
67 plugs into a PHP server and allows the Zend Development Environment to
68 control the execution of PHP applications on the server.
70 The Debug Server is designed be deployed safely on production servers.
71 It does not affect server performance and features access-list based
72 security for protecting the server from unauthorized access.
77 tar --strip-components=1 -xzf %{SOURCE1}
79 tar --strip-components=1 -xzf %{SOURCE0}
84 zend_debugger.allow_hosts=127.0.0.1
85 zend_debugger.expose_remotely=always
88 cat <<'EOF' > pack4.ini
89 ; %{name} package settings. Overwritten with each upgrade.
90 ; if you need to add options, edit %{name}.ini instead
92 zend_extension=%{_php4_extensiondir}/ZendDebugger.so
95 cat <<'EOF' > pack5.ini
96 ; %{name} package settings. Overwritten with each upgrade.
97 ; if you need to add options, edit %{name}.ini instead
99 zend_extension=%{_php5_extensiondir}/ZendDebugger.so
103 rm -rf $RPM_BUILD_ROOT
104 install -d $RPM_BUILD_ROOT{%{_php4_extensiondir},%{_php5_extensiondir}}
105 install %(echo %{php4_version} | tr . _)_x_comp/ZendDebugger.so $RPM_BUILD_ROOT%{_php4_extensiondir}
106 install %(echo %{php5_version} | tr . _)_x_comp/ZendDebugger.so $RPM_BUILD_ROOT%{_php5_extensiondir}
108 install -d $RPM_BUILD_ROOT{%{_php4_sysconfdir},%{_php5_sysconfdir}}
109 install zend.ini $RPM_BUILD_ROOT%{_php4_sysconfdir}/%{name}.ini
110 install zend.ini $RPM_BUILD_ROOT%{_php5_sysconfdir}/%{name}.ini
111 install pack4.ini $RPM_BUILD_ROOT%{_php4_sysconfdir}/%{name}_pack.ini
112 install pack5.ini $RPM_BUILD_ROOT%{_php5_sysconfdir}/%{name}_pack.ini
115 rm -rf $RPM_BUILD_ROOT
117 %preun -n php4-%{name}
118 if [ "$1" = "0" ]; then
119 %php4_webserver_restart
122 %post -n php4-%{name}
123 %php4_webserver_restart
125 %preun -n php-%{name}
126 if [ "$1" = "0" ]; then
127 %php_webserver_restart
131 %php_webserver_restart
133 %files -n php4-%{name}
134 %defattr(644,root,root,755)
135 %config(noreplace) %verify(not md5 mtime size) %{_php4_sysconfdir}/%{name}.ini
136 %config %verify(not md5 mtime size) %{_php4_sysconfdir}/%{name}_pack.ini
137 %attr(755,root,root) %{_php4_extensiondir}/ZendDebugger.so
139 %files -n php-%{name}
140 %defattr(644,root,root,755)
141 %config(noreplace) %verify(not md5 mtime size) %{_php5_sysconfdir}/%{name}.ini
142 %config %verify(not md5 mtime size) %{_php5_sysconfdir}/%{name}_pack.ini
143 %attr(755,root,root) %{_php5_extensiondir}/ZendDebugger.so