/[packages]/cauldron/php-zookeeper/current/SPECS/php-zookeeper.spec
ViewVC logotype

Annotation of /cauldron/php-zookeeper/current/SPECS/php-zookeeper.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 48356 - (hide annotations) (download)
Mon Feb 7 03:09:22 2011 UTC (13 years, 8 months ago) by spuhler
File size: 1596 byte(s)
removed buildroot definition from .spec

1 spuhler 44590 %define modname zookeeper
2     %define dirname %{modname}
3     %define soname %{modname}.so
4     %define inifile B09_%{modname}.ini
5    
6     Summary: PHP extension for interfacing with Apache ZooKeeper
7     Name: php-%{modname}
8     Version: 0.1.0
9     Release: %mkrel 8
10     Group: Development/PHP
11     License: PHP License
12     URL: http://pecl.php.net/package/zookeeper/
13     Source0: http://pecl.php.net/get/%{modname}-%{version}.tgz
14     BuildRequires: php-devel >= 3:5.2.0
15     BuildRequires: zookeeper-devel >= 3
16    
17     %description
18     This extension provides API for communicating with ZooKeeper service.
19    
20     %prep
21    
22     %setup -q -n %{modname}-%{version}
23     [ "../package*.xml" != "/" ] && mv ../package*.xml .
24    
25     # lib64 fix
26     perl -pi -e "s|/lib\b|/%{_lib}|g" config.m4
27    
28     %build
29     %serverbuild
30    
31     phpize
32     %configure2_5x --with-libdir=%{_lib} \
33     --with-%{modname}=shared,%{_prefix}
34     %make
35     mv modules/*.so .
36    
37     %install
38     rm -rf %{buildroot}
39    
40     install -d %{buildroot}%{_libdir}/php/extensions
41     install -d %{buildroot}%{_sysconfdir}/php.d
42    
43     install -m755 %{soname} %{buildroot}%{_libdir}/php/extensions/
44    
45     cat > %{buildroot}%{_sysconfdir}/php.d/%{inifile} << EOF
46     extension = %{soname}
47     EOF
48    
49     %post
50     if [ -f /var/lock/subsys/httpd ]; then
51     %{_initrddir}/httpd restart >/dev/null || :
52     fi
53    
54     %postun
55     if [ "$1" = "0" ]; then
56     if [ -f /var/lock/subsys/httpd ]; then
57     %{_initrddir}/httpd restart >/dev/null || :
58     fi
59     fi
60    
61     %clean
62     rm -rf %{buildroot}
63    
64     %files
65     %defattr(-,root,root)
66     %doc CREDITS ChangeLog LICENSE README.markdown zookeeper-api.php package*.xml
67     %config(noreplace) %attr(0644,root,root) %{_sysconfdir}/php.d/%{inifile}
68     %attr(0755,root,root) %{_libdir}/php/extensions/%{soname}
69    
70    
71    

  ViewVC Help
Powered by ViewVC 1.1.30