SPECS: php-pecl-PDO_MYSQL.spec, php-pecl-PDO_OCI.spec - use new ph...

glen glen at pld-linux.org
Fri Dec 15 00:38:19 CET 2006


Author: glen                         Date: Thu Dec 14 23:38:19 2006 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- use new php extension related macros

---- Files affected:
SPECS:
   php-pecl-PDO_MYSQL.spec (1.17 -> 1.18) , php-pecl-PDO_OCI.spec (1.11 -> 1.12) 

---- Diffs:

================================================================
Index: SPECS/php-pecl-PDO_MYSQL.spec
diff -u SPECS/php-pecl-PDO_MYSQL.spec:1.17 SPECS/php-pecl-PDO_MYSQL.spec:1.18
--- SPECS/php-pecl-PDO_MYSQL.spec:1.17	Sun Nov 26 16:34:25 2006
+++ SPECS/php-pecl-PDO_MYSQL.spec	Fri Dec 15 00:38:14 2006
@@ -2,8 +2,6 @@
 %define		_modname	PDO_MYSQL
 %define		_smodname	pdo_mysql
 %define		_status		stable
-%define		_sysconfdir	/etc/php
-%define		extensionsdir	%(php-config --extension-dir 2>/dev/null)
 Summary:	%{_modname} - MySQL 3.x/4.0 driver for PDO
 Summary(pl):	%{_modname} - sterownik do bazy MySQL 3.x/4.0 dla PDO
 Name:		php-pecl-%{_modname}
@@ -17,10 +15,10 @@
 BuildRequires:	mysql-devel
 BuildRequires:	php-devel >= 3:5.0.3
 BuildRequires:	php-pecl-PDO-devel
-BuildRequires:	rpmbuild(macros) >= 1.322
+BuildRequires:	rpmbuild(macros) >= 1.344
 %{?requires_php_extension}
 %{?requires_php_pdo_module}
-Requires:	%{_sysconfdir}/conf.d
+Requires:	php-common >= 4:5.0.4
 Requires:	php-pecl-PDO
 Provides:	php(pdo-mysql)
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -47,10 +45,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/%{_smodname}.so $RPM_BUILD_ROOT%{extensionsdir}
-cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_smodname}.ini
+install %{_modname}-%{version}/modules/%{_smodname}.so $RPM_BUILD_ROOT%{php_extensiondir}
+cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{_smodname}.ini
 ; Enable %{_modname} extension module
 extension=%{_smodname}.so
 EOF
@@ -59,20 +57,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
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_smodname}.ini
-%attr(755,root,root) %{extensionsdir}/%{_smodname}.so
+%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{_smodname}.ini
+%attr(755,root,root) %{php_extensiondir}/%{_smodname}.so
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -80,6 +76,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.18  2006/12/14 23:38:14  glen
+- use new php extension related macros
+
 Revision 1.17  2006/11/26 15:34:25  glen
 - rel 2: add Provides: php(%{_modname})
 

================================================================
Index: SPECS/php-pecl-PDO_OCI.spec
diff -u SPECS/php-pecl-PDO_OCI.spec:1.11 SPECS/php-pecl-PDO_OCI.spec:1.12
--- SPECS/php-pecl-PDO_OCI.spec:1.11	Fri Nov  3 00:09:09 2006
+++ SPECS/php-pecl-PDO_OCI.spec	Fri Dec 15 00:38:14 2006
@@ -2,8 +2,6 @@
 %define		_modname	PDO_OCI
 %define		_smodname	pdo_oci
 %define		_status		stable
-%define		_sysconfdir	/etc/php
-%define		extensionsdir	%(php-config --extension-dir 2>/dev/null)
 # NOTE: needs ORACLE_HOME env var to build
 Summary:	%{_modname} - Oracle Call Interface driver for PDO
 Summary(pl):	%{_modname} - sterownik Oracle Call Interface dla PDO
@@ -17,10 +15,11 @@
 URL:		http://pecl.php.net/package/PDO_OCI/
 BuildRequires:	php-devel >= 3:5.0.0
 BuildRequires:	php-pecl-PDO-devel
-BuildRequires:	rpmbuild(macros) >= 1.322
+BuildRequires:	rpmbuild(macros) >= 1.344
 %{?requires_php_extension}
 %{?requires_php_pdo_module}
-Requires:	%{_sysconfdir}/conf.d
+Requires:	php-common >= 4:5.0.4
+Requires:	php-pecl-PDO
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -44,10 +43,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/%{_smodname}.so $RPM_BUILD_ROOT%{extensionsdir}
-cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_smodname}.ini
+install %{_modname}-%{version}/modules/%{_smodname}.so $RPM_BUILD_ROOT%{php_extensiondir}
+cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{_smodname}.ini
 ; Enable %{_modname} extension module
 extension=%{_smodname}.so
 EOF
@@ -56,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
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_modname}.ini
-%attr(755,root,root) %{extensionsdir}/%{_smodname}.so
+%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{_smodname}.ini
+%attr(755,root,root) %{php_extensiondir}/%{_smodname}.so
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -77,6 +74,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.12  2006/12/14 23:38:14  glen
+- use new php extension related macros
+
 Revision 1.11  2006/11/02 23:09:09  glen
 - BR rpmmacros for fixed %requires_php_extension
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/php-pecl-PDO_MYSQL.spec?r1=1.17&r2=1.18&f=u
    http://cvs.pld-linux.org/SPECS/php-pecl-PDO_OCI.spec?r1=1.11&r2=1.12&f=u



More information about the pld-cvs-commit mailing list