# remirepo spec file for php-Analog, from: # # Fedora spec file for php-Analog # # License: MIT # http://opensource.org/licenses/MIT # # Please preserve changelog entries # %global gh_owner jbroadway %global gh_project analog %global gh_commit 1fcc97fd842f37013587d64aba5f3f1fa6b0d911 %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) #global gh_date 20150213 %global real_name Analog Name: php-Analog Summary: PHP micro logging package Version: 1.0.6 %if 0%{?gh_date} Release: 5.%{gh_date}git%{gh_short}%{?dist} %else Release: %{?dist} %endif License: MIT Group: Development/Libraries URL: https://github.com/jbroadway/analog Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{version}-%{gh_short}.tar.gz Patch0: %{name}-php7.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch # For tests BuildRequires: %{_bindir}/phpunit BuildRequires: php-composer(psr/log) # from composer.json, "require": { # "psr/log": "1.*", # "php": ">=5.3.2" Requires: php(language) >= 5.3.2 Requires: php-composer(psr/log) # From phpcompatinfo report Requires: php-curl Requires: php-date Requires: php-json Requires: php-pcre Requires: php-reflection Requires: php-spl Requires: php-xml # mongo is optional Provides: php-composer(analog/analog) = %{version} %description MicroPHP logging package based on the idea of using closures for configurability and extensibility. It functions as a static class, but you can completely control the writing of log messages through a closure function (aka anonymous functions). Analog also comes with over a dozen pre-written handlers, with examples for each in the examples folder. These include: - Amon - Send logs to the Amon server monitoring tool - Buffer - Buffer messages to send all at once (works with File, Mail, Stderr, and Variable handlers) - File - Append messages to a file - FirePHP - Send messages to FirePHP browser plugin - GELF - Send message to the Graylog2 log management server - Ignore - Do nothing - LevelBuffer - Buffer messages and send only if sufficient error level reached - Mail - Send email notices - Mongo - Save to MongoDB collection, requires php-pecl(mongo) package to be installed - Multi - Send different log levels to different handlers - Post - Send messages over HTTP POST to another machine - Stderr - Send messages to STDERR - Syslog - Send messages to syslog - Variable - Buffer messages to a variable reference. So while it's a micro class, it's highly extensible and very capable out of the box too. %prep %setup -qn %{gh_project}-%{gh_commit} %patch0 -p1 %build # empty build section, nothing required %install rm -rf %{buildroot} # install framework files install -d %{buildroot}%{_datadir}/php cp -a lib/%{real_name} %{buildroot}%{_datadir}/php/ %check : Generate simple PSR-0 autoloader cat < - 1.0.6-1 - update to 1.0.6 - composer dependencies - add patch for PHP-7 (add Ignore, Null is deprecated) * Sat Jun 07 2014 Fedora Release Engineering - 1.0.0-5.git9ab4c9e - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild * Sun Aug 04 2013 Fedora Release Engineering - 1.0.0-4.git9ab4c9e - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild * Sun Feb 10 2013 Johan Cwiklinski - 1.0.0-4.git9ab4c9e - Add patch for locked file (https://github.com/jbroadway/analog/issues/7) - Remove licence file and patch applied upstream - Change github source URL * Sun Dec 30 2012 Johan Cwiklinski - 1.0.0-2.git876d8a3bb - Fix a typo - Run tests, add relevant BR and patch * Sun Dec 30 2012 Johan Cwiklinski - 1.0.0-1.git876d8a3bb - Fix version - remove not needeed php-hash requirement - remove php-mongo requirement (add a line in %%description) - remove unneeded macro - add LICENSE file (upstream bug https://github.com/jbroadway/analog/issues/2) * Mon Dec 24 2012 Johan Cwiklinski - 1.0.0.1-1.git876d8a3bb - Latest snapshot (bug fixes, new handlers) - Fix Requires * Sat Dec 01 2012 Johan Cwiklinski - 1.0.0-1 - Initial packaging