[python-concurrentloghandler] bpeck's initial version from python-concurrentloghandler-0.8.4-1.el5.src.rpm

Dan Callaghan dcallagh at fedoraproject.org
Thu Oct 13 23:45:21 UTC 2011


commit b39e83ee08d8bde3d2dccde429bea33d48f10b66
Author: Dan Callaghan <dcallagh at redhat.com>
Date:   Tue Oct 4 12:16:57 2011 +1000

    bpeck's initial version from python-concurrentloghandler-0.8.4-1.el5.src.rpm

 .gitignore                                |    1 +
 ConcurrentLogHandler-0.8.4-testpath.patch |   17 ++++++++
 python-concurrentloghandler.spec          |   58 +++++++++++++++++++++++++++++
 sources                                   |    1 +
 4 files changed, 77 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..afc1f21 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/ConcurrentLogHandler-0.8.4.tar.bz2
diff --git a/ConcurrentLogHandler-0.8.4-testpath.patch b/ConcurrentLogHandler-0.8.4-testpath.patch
new file mode 100644
index 0000000..e786840
--- /dev/null
+++ b/ConcurrentLogHandler-0.8.4-testpath.patch
@@ -0,0 +1,17 @@
+--- setup.py
++++ setup.py
+@@ -220,13 +220,7 @@
+         "portalocker",
+         ],
+       package_dir={ '' : 'src', },
+-      data_files=[
+-        ('tests', ["stresstest.py"]),
+-        ('docs', [
+-            'README',
+-            'LICENSE',
+-            ]),
+-      ],
++      data_files=[ ],
+       url="http://pypi.python.org/pypi/ConcurrentLogHandler",
+       license = "http://www.apache.org/licenses/LICENSE-2.0",
+       description=doc.pop(0),
diff --git a/python-concurrentloghandler.spec b/python-concurrentloghandler.spec
new file mode 100644
index 0000000..3c21f81
--- /dev/null
+++ b/python-concurrentloghandler.spec
@@ -0,0 +1,58 @@
+# sitelib for noarch packages, sitearch for others (remove the unneeded one)
+%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
+%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
+
+%define modname ConcurrentLogHandler
+
+Name:           python-concurrentloghandler
+Version:        0.8.4
+Release:        1%{?dist}
+Summary:        Concurrent logging handler (drop-in replacement for RotatingFileHandler)
+
+Group:          Development/Languages
+License:        Apache Software License
+URL:            http://pypi.python.org/packages/source/C/ConcurrentLogHandler
+Source0:        %{modname}-%{version}.tar.bz2
+Patch0:         %modname-0.8.4-testpath.patch
+BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+
+BuildArch:      noarch
+BuildRequires:  python-devel
+BuildRequires:  python-setuptools-devel >= 0.6c11
+
+%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.
+
+
+%prep
+%setup -q -n %{modname}-%{version}
+%patch0
+
+
+%build
+# Remove CFLAGS=... for noarch packages (unneeded)
+CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
+
+
+%install
+rm -rf $RPM_BUILD_ROOT
+%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT --install-data=%_defaultdocdir/%name
+
+ 
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+
+%files
+%defattr(-,root,root,-)
+%doc README LICENSE
+# For noarch packages: sitelib
+%{python_sitelib}/*
+# For arch-specific packages: sitearch
+%{python_sitearch}/*
+
+
+%changelog
diff --git a/sources b/sources
index e69de29..d9f61d2 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+41678253ba8b535c6c51794d9ba8edf0  ConcurrentLogHandler-0.8.4.tar.bz2


More information about the scm-commits mailing list