SPECS: php-pecl-archive.spec, php-pecl-ares.spec - use new php ext...
glen
glen at pld-linux.org
Fri Dec 15 00:48:57 CET 2006
Author: glen Date: Thu Dec 14 23:48:57 2006 GMT
Module: SPECS Tag: HEAD
---- Log message:
- use new php extension related macros
---- Files affected:
SPECS:
php-pecl-archive.spec (1.11 -> 1.12) , php-pecl-ares.spec (1.4 -> 1.5)
---- Diffs:
================================================================
Index: SPECS/php-pecl-archive.spec
diff -u SPECS/php-pecl-archive.spec:1.11 SPECS/php-pecl-archive.spec:1.12
--- SPECS/php-pecl-archive.spec:1.11 Fri Nov 3 00:09:09 2006
+++ SPECS/php-pecl-archive.spec Fri Dec 15 00:48:52 2006
@@ -1,8 +1,6 @@
# $Revision$, $Date$
%define _modname archive
%define _status beta
-%define _sysconfdir /etc/php
-%define extensionsdir %(php-config --extension-dir 2>/dev/null)
Summary: %{_modname} - manipulate tar/cpio archives
Summary(pl): %{_modname} - obróbka archiwów tar/cpio
Name: php-pecl-%{_modname}
@@ -15,9 +13,9 @@
URL: http://pecl.php.net/package/archive/
BuildRequires: libarchive-devel
BuildRequires: php-devel >= 3:5.0.0
-BuildRequires: rpmbuild(macros) >= 1.322
+BuildRequires: rpmbuild(macros) >= 1.344
%{?requires_php_extension}
-Requires: %{_sysconfdir}/conf.d
+Requires: php-common >= 4:5.0.4
Obsoletes: php-pear-%{_modname}
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -44,10 +42,10 @@
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_sysconfdir}/conf.d,%{extensionsdir}}
+install -d $RPM_BUILD_ROOT{%{php_sysconfdir}/conf.d,%{php_extensiondir}}
-install %{_modname}-%{version}/modules/%{_modname}.so $RPM_BUILD_ROOT%{extensionsdir}
-cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_modname}.ini
+install %{_modname}-%{version}/modules/%{_modname}.so $RPM_BUILD_ROOT%{php_extensiondir}
+cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{_modname}.ini
; Enable %{_modname} extension module
extension=%{_modname}.so
EOF
@@ -56,20 +54,18 @@
rm -rf $RPM_BUILD_ROOT
%post
-[ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
-[ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
+%php_webserver_restart
%postun
if [ "$1" = 0 ]; then
- [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
- [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
+ %php_webserver_restart
fi
%files
%defattr(644,root,root,755)
%doc %{_modname}-%{version}/{API.txt,CREDITS,tests}
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_modname}.ini
-%attr(755,root,root) %{extensionsdir}/%{_modname}.so
+%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{_modname}.ini
+%attr(755,root,root) %{php_extensiondir}/%{_modname}.so
%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
%changelog
@@ -77,6 +73,9 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.12 2006/12/14 23:48:52 glen
+- use new php extension related macros
+
Revision 1.11 2006/11/02 23:09:09 glen
- BR rpmmacros for fixed %requires_php_extension
================================================================
Index: SPECS/php-pecl-ares.spec
diff -u SPECS/php-pecl-ares.spec:1.4 SPECS/php-pecl-ares.spec:1.5
--- SPECS/php-pecl-ares.spec:1.4 Wed Dec 13 23:15:21 2006
+++ SPECS/php-pecl-ares.spec Fri Dec 15 00:48:52 2006
@@ -1,9 +1,6 @@
# $Revision$, $Date$
%define _modname ares
%define _status beta
-%define _sysconfdir /etc/php
-%define extensionsdir %(php-config --extension-dir 2>/dev/null)
-
Summary: %{_modname} - asynchronous resolver
Summary(pl): %{_modname} - asynchroniczny resolver
Name: php-pecl-%{_modname}
@@ -16,9 +13,9 @@
URL: http://pecl.php.net/package/ares/
BuildRequires: c-ares-devel
BuildRequires: php-devel >= 3:5.0.0
-BuildRequires: rpmbuild(macros) >= 1.322
+BuildRequires: rpmbuild(macros) >= 1.344
%{?requires_php_extension}
-Requires: %{_sysconfdir}/conf.d
+Requires: php-common >= 4:5.0.4
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
@@ -42,14 +39,14 @@
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_sysconfdir}/conf.d
+install -d $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d
%{__make} install \
-C %{_modname}-%{version} \
INSTALL_ROOT=$RPM_BUILD_ROOT \
- EXTENSION_DIR=%{extensionsdir}
+ EXTENSION_DIR=%{php_extensiondir}
-cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_modname}.ini
+cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{_modname}.ini
; Enable %{_modname} extension module
extension=%{_modname}.so
EOF
@@ -58,20 +55,18 @@
rm -rf $RPM_BUILD_ROOT
%post
-[ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
-[ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
+%php_webserver_restart
%postun
if [ "$1" = 0 ]; then
- [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
- [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
+ %php_webserver_restart
fi
%files
%defattr(644,root,root,755)
%doc %{_modname}-%{version}/{CREDITS,EXPERIMENTAL}
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_modname}.ini
-%attr(755,root,root) %{extensionsdir}/%{_modname}.so
+%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{_modname}.ini
+%attr(755,root,root) %{php_extensiondir}/%{_modname}.so
%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
%changelog
@@ -79,6 +74,9 @@
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log$
+Revision 1.5 2006/12/14 23:48:52 glen
+- use new php extension related macros
+
Revision 1.4 2006/12/13 22:15:21 glen
- rel 2 (php 5.2.0)
================================================================
---- CVS-web:
http://cvs.pld-linux.org/SPECS/php-pecl-archive.spec?r1=1.11&r2=1.12&f=u
http://cvs.pld-linux.org/SPECS/php-pecl-ares.spec?r1=1.4&r2=1.5&f=u
More information about the pld-cvs-commit
mailing list