]> git.pld-linux.org Git - packages/php-pecl-dbx.git/blob - php-pecl-dbx.spec
- BR rpmmacros for fixed %requires_php_extension
[packages/php-pecl-dbx.git] / php-pecl-dbx.spec
1 %define         _modname        dbx
2 %define         _status         stable
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}
8 Version:        1.1.0
9 Release:        6
10 License:        PHP 2.02
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
19 Obsoletes:      php-dbx
20 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21
22 %description
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
27 these databases.
28
29 The currently supported databases are MySQL, ODBC, Oracle (oci8), MS
30 SQL Server, PostgreSQL, FrontBase, Sybase-CT and SQLite.
31
32 In PECL status of this extension is: %{_status}.
33
34 %description -l pl
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.
39
40 Aktualnie wspierane bazy danych to MySQL, ODBC, Oracle (oci8), MS SQL
41 Server, PostgreSQL, FrontBase, Sybase-CT oraz SQLite.
42
43 To rozszerzenie ma w PECL status: %{_status}.
44
45 %prep
46 %setup -q -c
47
48 %build
49 cd %{_modname}-%{version}
50 phpize
51 %configure
52 %{__make}
53
54 %install
55 rm -rf $RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/conf.d,%{extensionsdir}}
57
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
62 EOF
63
64 %clean
65 rm -rf $RPM_BUILD_ROOT
66
67 %post
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
70
71 %postun
72 if [ "$1" = 0 ]; then
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
75 fi
76
77 %files
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
This page took 0.119272 seconds and 3 git commands to generate.