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

Contents of /cauldron/php-mongo/current/SPECS/php-mongo.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 44393 - (show annotations) (download)
Sat Jan 29 22:36:18 2011 UTC (10 years, 10 months ago) by spuhler
File size: 1524 byte(s)
imported package php-mongo
1 %define modname mongo
2 %define dirname %{modname}
3 %define soname %{modname}.so
4 %define inifile B04_%{modname}.ini
5
6 Summary: Mongo Database Driver
7 Name: php-%{modname}
8 Version: 1.1.3
9 Release: %mkrel 1
10 Group: Development/PHP
11 License: Apache License
12 URL: http://pecl.php.net/package/mongo/
13 Source0: http://pecl.php.net/get/%{modname}-%{version}.tgz
14 Source1: mongo.ini
15 BuildRequires: php-devel >= 3:5.2.0
16 BuildRequires: apache-devel >= 2.2.0
17 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
18
19 %description
20 This package provides an interface for communicating with the Mongo database
21 in PHP.
22
23 %prep
24
25 %setup -q -n %{modname}-%{version}
26 [ "../package*.xml" != "/" ] && mv ../package*.xml .
27
28 cp %{SOURCE1} %{inifile}
29
30 %build
31 %serverbuild
32
33 phpize
34 %configure2_5x --with-libdir=%{_lib}
35 %make
36 mv modules/*.so .
37
38 %install
39 rm -rf %{buildroot}
40
41 install -d %{buildroot}%{_libdir}/php/extensions
42 install -d %{buildroot}%{_sysconfdir}/php.d
43
44 install -m0755 %{soname} %{buildroot}%{_libdir}/php/extensions/
45 install -m0644 %{inifile} %{buildroot}%{_sysconfdir}/php.d/%{inifile}
46
47 %post
48 if [ -f /var/lock/subsys/httpd ]; then
49 %{_initrddir}/httpd restart >/dev/null || :
50 fi
51
52 %postun
53 if [ "$1" = "0" ]; then
54 if [ -f /var/lock/subsys/httpd ]; then
55 %{_initrddir}/httpd restart >/dev/null || :
56 fi
57 fi
58
59 %clean
60 rm -rf %{buildroot}
61
62 %files
63 %defattr(-,root,root)
64 %doc README.md package*.xml
65 %config(noreplace) %attr(0644,root,root) %{_sysconfdir}/php.d/%{inifile}
66 %attr(0755,root,root) %{_libdir}/php/extensions/%{soname}
67
68
69

  ViewVC Help
Powered by ViewVC 1.1.28