3 %define _sysconfdir /etc/php
4 %define extensionsdir %(php-config --extension-dir 2>/dev/null)
5 Summary: %{_modname} - database abstraction functions
6 Summary(pl): %{_modname} - funkcje abstrakcji baz danych
7 Name: php-pecl-%{_modname}
11 Group: Development/Languages/PHP
12 Source0: http://pecl.php.net/get/%{_modname}-%{version}.tgz
13 # Source0-md5: 82d1091c75e047c4a8f9aea7b279e13b
14 URL: http://pecl.php.net/package/dbx/
15 BuildRequires: php-devel >= 3:5.0.0
16 BuildRequires: rpmbuild(macros) >= 1.322
17 %{?requires_php_extension}
18 Requires: %{_sysconfdir}/conf.d
20 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23 The dbx module is a database abstraction layer. The dbx functions
24 allow you to access all supported databases using a single calling
25 convention. The dbx-functions themselves do not interface directly to
26 the databases, but interface to the modules that are used to support
29 The currently supported databases are MySQL, ODBC, Oracle (oci8), MS
30 SQL Server, PostgreSQL, FrontBase, Sybase-CT and SQLite.
32 In PECL status of this extension is: %{_status}.
35 Modu³ dbx to warstwa abstrakcji baz danych. Funkcje dbx pozwalaj± na
36 dostêp do wspieranych baz danych przy u¿yciu spójnej konwencji.
37 Funkcje dbx jako takie nie s± bezpo¶rednim interfejsem do bazy danych,
38 ale interfejsem do modu³ów do obs³ugi baz danych.
40 Aktualnie wspierane bazy danych to MySQL, ODBC, Oracle (oci8), MS SQL
41 Server, PostgreSQL, FrontBase, Sybase-CT oraz SQLite.
43 To rozszerzenie ma w PECL status: %{_status}.
49 cd %{_modname}-%{version}
55 rm -rf $RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/conf.d,%{extensionsdir}}
58 install %{_modname}-%{version}/modules/%{_modname}.so $RPM_BUILD_ROOT%{extensionsdir}
59 cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_modname}.ini
60 ; Enable %{_modname} extension module
61 extension=%{_modname}.so
65 rm -rf $RPM_BUILD_ROOT
68 [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
69 [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
73 [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
74 [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
78 %defattr(644,root,root,755)
79 %doc %{_modname}-%{version}/CREDITS
80 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_modname}.ini
81 %attr(755,root,root) %{extensionsdir}/%{_modname}.so