forked from pool/python-concurrentloghandler
Accepting request 610078 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/610078 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-concurrentloghandler?expand=0&rev=13
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
--- setup.py
|
||||
+++ setup.py
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -262,13 +262,7 @@ setup(name='ConcurrentLogHandler',
|
||||
"portalocker",
|
||||
],
|
||||
@@ -15,3 +15,14 @@
|
||||
url="http://launchpad.net/python-concurrent-log-handler",
|
||||
license = "http://www.apache.org/licenses/LICENSE-2.0",
|
||||
description=doc.pop(0),
|
||||
--- /dev/null
|
||||
+++ b/run_tests.sh
|
||||
@@ -0,0 +1,8 @@
|
||||
+#!/bin/sh
|
||||
+set -x
|
||||
+
|
||||
+RET=$($1 stresstest.py \
|
||||
+ |& sed -n '/^Running internal diff/,/^\s*--- end of diff ----/p' \
|
||||
+ |wc -l)
|
||||
+rm -f test/*.log*
|
||||
+[ $RET -eq 2 ]
|
||||
|
||||
@@ -1,3 +1,20 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu May 17 13:09:05 UTC 2018 - mcepl@suse.com
|
||||
|
||||
- Fix tests
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu May 17 10:26:32 UTC 2018 - mcepl@suse.com
|
||||
|
||||
- Run spec-cleaner on the SPEC file.
|
||||
- Fix SPEC file to work according to the latest standards
|
||||
- Failed to make tests working.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Aug 24 13:34:37 UTC 2017 - jmatejek@suse.com
|
||||
|
||||
- singlespec auto-conversion
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jul 20 17:05:26 UTC 2016 - antoine.belvire@laposte.net
|
||||
|
||||
@@ -40,3 +57,4 @@ Tue Jun 22 13:10:25 UTC 2010 - hvogel@novell.com
|
||||
|
||||
- Initial Package, Version 0.8.4
|
||||
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-concurrentloghandler
|
||||
#
|
||||
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@@ -17,44 +17,50 @@
|
||||
|
||||
|
||||
%define modname ConcurrentLogHandler
|
||||
|
||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||
Name: python-concurrentloghandler
|
||||
Version: 0.9.1
|
||||
Release: 0
|
||||
Summary: Concurrent logging handler
|
||||
License: Apache-2.0
|
||||
Group: Development/Libraries/Python
|
||||
Url: http://pypi.python.org/pypi/ConcurrentLogHandler
|
||||
Source: https://pypi.python.org/packages/source/C/ConcurrentLogHandler/%{modname}-%{version}.tar.gz
|
||||
Patch0: %modname-0.9.1-testpath.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
BuildRequires: python-devel
|
||||
BuildRequires: python-setuptools
|
||||
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
|
||||
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
||||
%else
|
||||
URL: http://pypi.python.org/pypi/ConcurrentLogHandler
|
||||
Source: https://files.pythonhosted.org/packages/source/C/ConcurrentLogHandler/%{modname}-%{version}.tar.gz
|
||||
Patch0: %{modname}-0.9.1-testpath.patch
|
||||
BuildRequires: %{python_module portalocker}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
BuildRequires: sed
|
||||
BuildArch: noarch
|
||||
%endif
|
||||
%python_subpackages
|
||||
|
||||
%description
|
||||
This module provides an additional log handler for Python's standard logging
|
||||
package (PEP 282). This handler will write log events to log file which is
|
||||
rotated when the log file reaches a certain size. Multiple processes can safely
|
||||
write to the same log file concurrently.
|
||||
This module provides an additional log handler for Python's
|
||||
standard logging package (PEP 282). This handler will write log
|
||||
events to log file which is rotated when the log file reaches
|
||||
a certain size. Multiple processes can safely write to the same
|
||||
log file concurrently.
|
||||
|
||||
%prep
|
||||
%setup -q -n %{modname}-%{version}
|
||||
%patch0
|
||||
%patch0 -p1
|
||||
rm -v src/portalocker.py
|
||||
|
||||
%build
|
||||
export CFLAGS="$RPM_OPT_FLAGS"
|
||||
python setup.py build
|
||||
export CFLAGS="%{optflags}"
|
||||
%python_build
|
||||
|
||||
%install
|
||||
python setup.py install --prefix=%{_prefix} --root=$RPM_BUILD_ROOT --install-data=%_defaultdocdir/%name --record-rpm=INSTALLED_FILES
|
||||
%python_install
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
%files -f INSTALLED_FILES
|
||||
%defattr(-,root,root)
|
||||
%doc README LICENSE
|
||||
%check
|
||||
%{python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} sh run_tests.sh $python }
|
||||
|
||||
%files %{python_files}
|
||||
%license LICENSE
|
||||
%doc README
|
||||
%{python_sitelib}/*
|
||||
|
||||
%changelog
|
||||
|
||||
Reference in New Issue
Block a user