]> git.pld-linux.org Git - packages/php-pecl-idn.git/blob - php-pecl-idn.spec
32e2bf75dabf3b64e6ea6079a6086704efcf66c4
[packages/php-pecl-idn.git] / php-pecl-idn.spec
1 %define         _modname        idn
2 %define         _status         beta
3 %define         _sysconfdir     /etc/php
4 %define         extensionsdir   %(php-config --extension-dir 2>/dev/null)
5 Summary:        idn - binding to the GNU libidn
6 Summary(pl):    idn - wi±zanie do GNU libidn
7 Name:           php-pecl-idn
8 Version:        0.1
9 Release:        2
10 License:        PHP 3.0
11 Group:          Development/Languages/PHP
12 Source0:        http://pecl.php.net/get/%{_modname}-%{version}.tgz
13 # Source0-md5:  ef8635ec22348325a76abd2abddca4a1
14 URL:            http://pecl.php.net/package/idn/
15 BuildRequires:  libidn-devel
16 BuildRequires:  php-devel >= 3:5.0.0
17 BuildRequires:  rpmbuild(macros) >= 1.322
18 %{?requires_php_extension}
19 Requires:       %{_sysconfdir}/conf.d
20 Obsoletes:      php-pear-idn
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %description
24 Binding to the GNU libidn for using Internationalized Domain Names.
25
26 In PECL status of this package is: %{_status}.
27
28 %description -l pl
29 Wi±zanie do GNU libidn do u¿ywania umiêdzynarodowionych nazw domen
30 (Internationalized Domain Names).
31
32 To rozszerzenie ma w PECL status: %{_status}.
33
34 %prep
35 %setup -q -c
36
37 %build
38 cd %{_modname}-%{version}
39 phpize
40 %configure
41 %{__make}
42
43 %install
44 rm -rf $RPM_BUILD_ROOT
45 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/conf.d,%{extensionsdir}}
46
47 install %{_modname}-%{version}/modules/%{_modname}.so $RPM_BUILD_ROOT%{extensionsdir}
48 cat <<'EOF' > $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/%{_modname}.ini
49 ; Enable %{_modname} extension module
50 extension=%{_modname}.so
51 EOF
52
53 %clean
54 rm -rf $RPM_BUILD_ROOT
55
56 %post
57 [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
58 [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
59
60 %postun
61 if [ "$1" = 0 ]; then
62         [ ! -f /etc/apache/conf.d/??_mod_php.conf ] || %service -q apache restart
63         [ ! -f /etc/httpd/httpd.conf/??_mod_php.conf ] || %service -q httpd restart
64 fi
65
66 %files
67 %defattr(644,root,root,755)
68 %doc %{_modname}-%{version}/CREDITS
69 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/%{_modname}.ini
70 %attr(755,root,root) %{extensionsdir}/%{_modname}.so
This page took 0.061975 seconds and 3 git commands to generate.