1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
|
%global libname Monolog
Name: php-%{libname}
Version: 1.2.1
Release: 1%{?dist}
Summary: Logging for PHP 5.3
Group: Development/Libraries
License: MIT
URL: https://github.com/Seldaek/monolog
Source0: %{url}/archive/%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
Requires: php-common >= 5.3.0
Requires: php-pear(pear.swiftmailer.org/Swift)
# phpci requires
Requires: php-curl
Requires: php-date
Requires: php-json
Requires: php-libxml
Requires: php-pcre
Requires: php-sockets
Requires: php-spl
Requires: php-filter
%description
%{summary}.
Optional packages:
* php-%{libname}-amqp
Allow sending log messages to an AMQP server (1.0+ required)
* php-%{libname}-mongo
Allow sending log messages to a MongoDB server
* https://github.com/mlehner/gelf-php
Allow sending log messages to a GrayLog2 server
%package amqp
Summary: Monolog AMQP handler
Group: Development/Libraries
Requires: php-%{libname} = %{version}-%{release}
Requires: php-pecl(amqp)
%description amqp
Allow sending log messages to an AMQP server (1.0+ required).
%package mongo
Summary: Monolog MongoDB handler
Group: Development/Libraries
Requires: php-%{libname} = %{version}-%{release}
Requires: php-pecl(mongo)
%description mongo
Allow sending log messages to a MongoDB server.
%prep
%setup -q -n monolog-%{version}
%build
# Empty build section, nothing to build
%install
mkdir -p -m 755 %{buildroot}%{_datadir}/php/%{libname}
cp -pr src/%{libname} %{buildroot}%{_datadir}/php/
%files
%defattr(-,root,root,-)
%doc LICENSE *.mdown doc composer.json
%{_datadir}/php/%{libname}
%exclude %{_datadir}/php/%{libname}/Handler/MongoDBHandler.php
%exclude %{_datadir}/php/%{libname}/Handler/AmqpHandler.php
%files amqp
%defattr(-,root,root,-)
%{_datadir}/php/%{libname}/Handler/AmqpHandler.php
%files mongo
%defattr(-,root,root,-)
%{_datadir}/php/%{libname}/Handler/MongoDBHandler.php
%changelog
* Sun Nov 25 2012 Remi Collet <RPMS@famillecollet.com> 1.2.1-1
- backport 1.2.1 for remi repo
* Sat Nov 17 2012 Shawn Iwinski <shawn.iwinski@gmail.com> 1.2.1-1
- Updated to upstream version 1.2.1
- Changed %%{libname} from monolog to Monolog
- Fixed license
- GitHub archive source
- Added php-pear(pear.swiftmailer.org/Swift), php-curl, and php-sockets requires
- Added optional packages note in %%{description}
- Simplified %%prep
- Added subpackages for AMQP and MongoDB handlers
- Changed RPM_BUILD_ROOT to %%{buildroot}
* Sun Jul 22 2012 Shawn Iwinski <shawn.iwinski@gmail.com> 1.1.0-1
- Initial package
|